Package de.espirit.firstspirit.agency
Interface ServerConfigurationAgent
public interface ServerConfigurationAgent
Agent providing access to the server configuration.
- Since:
- 5.2.180704
-
Field Summary
Modifier and TypeFieldDescriptionstatic final SpecialistType<ServerConfigurationAgent>
Agent providing access to the server configuration. -
Method Summary
Modifier and TypeMethodDescriptionIn order to prevent redirections to potentially malicious hosts, a whitelist of allowed host names can be configured for the FirstSpirit server.@NotNull ServerConfiguration
Returns an instance of the current server configuration, including access to theWeb Start Configuration
andQuickstart
s.<PROPERTY_TYPE>
Optional<PROPERTY_TYPE>getServerProperty
(@NotNull ServerProperty<PROPERTY_TYPE> property) Returns the current value of a server property.void
removeServerProperty
(@NotNull ServerProperty<?> property) Removes the current server property value, reverting it to the server default.<PROPERTY_TYPE>
voidsetServerProperty
(@NotNull ServerProperty<PROPERTY_TYPE> property, PROPERTY_TYPE value) Modifies the current value of a server property.
-
Field Details
-
TYPE
Agent providing access to the server configuration. The agent's technical type to be used to request the agent from aSpecialistsBroker
.- Since:
- 5.2.180704
-
-
Method Details
-
getServerProperty
<PROPERTY_TYPE> Optional<PROPERTY_TYPE> getServerProperty(@NotNull @NotNull ServerProperty<PROPERTY_TYPE> property) Returns the current value of a server property.- Type Parameters:
PROPERTY_TYPE
- the generic type of the property which is returned when the value is being read.- Parameters:
property
- the property to return the value for, must not benull
.- Returns:
- the current value or an empty
Optional
if unknown. - Since:
- 5.2.180704
-
setServerProperty
<PROPERTY_TYPE> void setServerProperty(@NotNull @NotNull ServerProperty<PROPERTY_TYPE> property, @NotNull PROPERTY_TYPE value) Modifies the current value of a server property.- Type Parameters:
PROPERTY_TYPE
- the generic type of the property which is set when the value is being written.- Parameters:
property
- the property to modify, must not benull
.value
- the new value, must not benull
.- Since:
- 5.2.180704
-
removeServerProperty
Removes the current server property value, reverting it to the server default.- Parameters:
property
- - the property to remove, must not benull
- Since:
- 5.2.231213
-
getAllowedRedirectHosts
In order to prevent redirections to potentially malicious hosts, a whitelist of allowed host names can be configured for the FirstSpirit server. This has effects on the Jump-Servlet (/jump) and the web authentication.
The allowed host names may contain wildcards for subdomains in the same way and format as in wildcard certificates.- Returns:
- a set of hostnames to which redirects are allowed. May be empty but never
null
. - Since:
- 5.2.180704
-
getServerConfiguration
Returns an instance of the current server configuration, including access to theWeb Start Configuration
andQuickstart
s.For accessing single properties, users are encouraged to use
getServerProperty(ServerProperty)
for a more type safe usage.- Returns:
- the current server configuration, never
null
. - Since:
- 5.2.180704
-