Package cn.boboweike.carrot.dashboard
Class CarrotDashboardWebServerConfiguration
- java.lang.Object
-
- cn.boboweike.carrot.dashboard.CarrotDashboardWebServerConfiguration
-
public class CarrotDashboardWebServerConfiguration extends Object
This class allows to configure the CarrotDashboard
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description CarrotDashboardWebServerConfigurationandBasicAuthentication(String username, String password)Adds basic authentication to the dashboard using the provided username and password.CarrotDashboardWebServerConfigurationandPort(int port)Specifies the port on which the CarrotDashboard will runstatic CarrotDashboardWebServerConfigurationusingStandardDashboardConfiguration()This returns the default configuration with the CarrotDashboard running on port 8000
-
-
-
Method Detail
-
usingStandardDashboardConfiguration
public static CarrotDashboardWebServerConfiguration usingStandardDashboardConfiguration()
This returns the default configuration with the CarrotDashboard running on port 8000- Returns:
- the default CarrotDashboard configuration
-
andPort
public CarrotDashboardWebServerConfiguration andPort(int port)
Specifies the port on which the CarrotDashboard will run- Parameters:
port- the port on which the CarrotDashboard will run- Returns:
- the same configuration instance which provides a fluent api
-
andBasicAuthentication
public CarrotDashboardWebServerConfiguration andBasicAuthentication(String username, String password)
Adds basic authentication to the dashboard using the provided username and password. WARNING the password will be stored in clear text and if you are using http, it can be easily intercepted.- Parameters:
username- the login which the CarrotDashboard will askpassword- the password which the CarrotDashboard will ask- Returns:
- the same configuration instance which provides a fluent api
-
-