Module org.refcodes.rest
Package org.refcodes.rest
Interface HttpRegistry<DESC extends HttpServerDescriptor,B extends HttpRegistry<DESC,B>>
- Type Parameters:
DESC- The type of the server discovery descriptor (the object describing your service and locating the service registry).B- In order to implement the builder pattern with a coherent type hierarchy.
- All Superinterfaces:
org.refcodes.mixin.AliasAccessor,org.refcodes.mixin.AliasAccessor.AliasBuilder<B>,org.refcodes.mixin.AliasAccessor.AliasMutator,org.refcodes.mixin.AliasAccessor.AliasProperty,org.refcodes.component.Configurable<HttpRegistryContext<DESC>>,org.refcodes.component.Destroyable,org.refcodes.component.Destroyable.DestroyAutomaton,org.refcodes.web.HostAccessor,org.refcodes.web.HostAccessor.HostBuilder<B>,org.refcodes.web.HostAccessor.HostMutator,org.refcodes.web.HostAccessor.HostProperty,HttpRegistryUrlAccessor,HttpRegistryUrlAccessor.HttpRegistryUrlBuilder<B>,HttpRegistryUrlAccessor.HttpRegistryUrlMutator,HttpRegistryUrlAccessor.HttpRegistryUrlProperty,HttpServerDescriptorAccessor<DESC>,HttpServerDescriptorAccessor.HttpServerDescriptorBuilder<DESC,,B> HttpServerDescriptorAccessor.HttpServerDescriptorMutator<DESC>,HttpServerDescriptorAccessor.HttpServerDescriptorProperty<DESC>,HttpServerDescriptorFactory<DESC>,org.refcodes.component.Initializable,org.refcodes.component.Initializable.InitializeAutomaton,org.refcodes.component.InitializedAccessor,org.refcodes.mixin.InstanceIdAccessor,org.refcodes.mixin.InstanceIdAccessor.InstanceIdBuilder<B>,org.refcodes.mixin.InstanceIdAccessor.InstanceIdMutator,org.refcodes.mixin.InstanceIdAccessor.InstanceIdProperty,org.refcodes.net.IpAddressAccessor,org.refcodes.net.IpAddressAccessor.IpAddressBuilder<B>,org.refcodes.net.IpAddressAccessor.IpAddressMutator,org.refcodes.net.IpAddressAccessor.IpAddressProperty,org.refcodes.component.LifecycleComponent,org.refcodes.component.LifecycleComponent.LifecycleAutomaton,org.refcodes.component.LifecycleStatusAccessor,org.refcodes.component.Pausable,org.refcodes.component.Pausable.PauseAutomaton,PingPathAccessor,PingPathAccessor.PingPathBuilder<B>,PingPathAccessor.PingPathMutator,PingPathAccessor.PingPathProperty,org.refcodes.component.Resumable,org.refcodes.component.Resumable.ResumeAutomaton,org.refcodes.component.RunningAccessor,org.refcodes.component.Startable,org.refcodes.component.Startable.StartAutomaton,org.refcodes.component.Stoppable,org.refcodes.component.Stoppable.StopAutomaton,org.refcodes.security.TrustStoreDescriptorAccessor,org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorBuilder<B>,org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorMutator,org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorProperty,org.refcodes.web.VirtualHostAccessor,org.refcodes.web.VirtualHostAccessor.VirtualHostBuilder<B>,org.refcodes.web.VirtualHostAccessor.VirtualHostMutator,org.refcodes.web.VirtualHostAccessor.VirtualHostProperty
- All Known Subinterfaces:
HttpRegistrySidecar<DESC,,B> RestfulHttpRegistryServer<DESC,B>
- All Known Implementing Classes:
AbstractHttpRegistrySidecar,AbstractRestfulHttpRegistryServerDecorator
public interface HttpRegistry<DESC extends HttpServerDescriptor,B extends HttpRegistry<DESC,B>>
extends org.refcodes.component.Configurable<HttpRegistryContext<DESC>>, HttpServerDescriptorAccessor.HttpServerDescriptorProperty<DESC>, HttpServerDescriptorAccessor.HttpServerDescriptorBuilder<DESC,B>, PingPathAccessor.PingPathProperty, PingPathAccessor.PingPathBuilder<B>, org.refcodes.web.HostAccessor.HostProperty, org.refcodes.web.HostAccessor.HostBuilder<B>, org.refcodes.web.VirtualHostAccessor.VirtualHostProperty, org.refcodes.web.VirtualHostAccessor.VirtualHostBuilder<B>, org.refcodes.net.IpAddressAccessor.IpAddressProperty, org.refcodes.net.IpAddressAccessor.IpAddressBuilder<B>, org.refcodes.mixin.InstanceIdAccessor.InstanceIdProperty, org.refcodes.mixin.InstanceIdAccessor.InstanceIdBuilder<B>, org.refcodes.mixin.AliasAccessor.AliasProperty, org.refcodes.mixin.AliasAccessor.AliasBuilder<B>, org.refcodes.component.LifecycleComponent.LifecycleAutomaton, HttpRegistryUrlAccessor.HttpRegistryUrlProperty, HttpRegistryUrlAccessor.HttpRegistryUrlBuilder<B>, org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorProperty, org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorBuilder<B>, HttpServerDescriptorFactory<DESC>
The
HttpRegistry describes the functionality required in order to
register a service at a service registry and discovery service. This type is
intended to be used by different separate hierarchy branches by providing the
generic type <B>, ensuring a coherent type hierarchy for each branch.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.refcodes.mixin.AliasAccessor
org.refcodes.mixin.AliasAccessor.AliasBuilder<B extends org.refcodes.mixin.AliasAccessor.AliasBuilder<B>>, org.refcodes.mixin.AliasAccessor.AliasMutator, org.refcodes.mixin.AliasAccessor.AliasPropertyNested classes/interfaces inherited from interface org.refcodes.component.Configurable
org.refcodes.component.Configurable.ConfigureAutomaton<CTX>, org.refcodes.component.Configurable.ConfigureBuilder<CTX,B extends org.refcodes.component.Configurable.ConfigureBuilder<CTX, B>> Nested classes/interfaces inherited from interface org.refcodes.component.Destroyable
org.refcodes.component.Destroyable.DestroyAutomatonNested classes/interfaces inherited from interface org.refcodes.web.HostAccessor
org.refcodes.web.HostAccessor.HostBuilder<B extends org.refcodes.web.HostAccessor.HostBuilder<?>>, org.refcodes.web.HostAccessor.HostMutator, org.refcodes.web.HostAccessor.HostPropertyNested classes/interfaces inherited from interface org.refcodes.rest.HttpRegistryUrlAccessor
HttpRegistryUrlAccessor.HttpRegistryUrlBuilder<B extends HttpRegistryUrlAccessor.HttpRegistryUrlBuilder<B>>, HttpRegistryUrlAccessor.HttpRegistryUrlMutator, HttpRegistryUrlAccessor.HttpRegistryUrlPropertyNested classes/interfaces inherited from interface org.refcodes.rest.HttpServerDescriptorAccessor
HttpServerDescriptorAccessor.HttpServerDescriptorBuilder<DESC extends HttpServerDescriptor,B extends HttpServerDescriptorAccessor.HttpServerDescriptorBuilder<DESC, B>>, HttpServerDescriptorAccessor.HttpServerDescriptorMutator<DESC extends HttpServerDescriptor>, HttpServerDescriptorAccessor.HttpServerDescriptorProperty<DESC extends HttpServerDescriptor> Nested classes/interfaces inherited from interface org.refcodes.component.Initializable
org.refcodes.component.Initializable.InitializeAutomaton, org.refcodes.component.Initializable.InitializeBuilder<B extends org.refcodes.component.Initializable.InitializeBuilder<B>>, org.refcodes.component.Initializable.UncheckedInitializableNested classes/interfaces inherited from interface org.refcodes.component.InitializedAccessor
org.refcodes.component.InitializedAccessor.InitializedMutator, org.refcodes.component.InitializedAccessor.InitializedPropertyNested classes/interfaces inherited from interface org.refcodes.mixin.InstanceIdAccessor
org.refcodes.mixin.InstanceIdAccessor.InstanceIdBuilder<B extends org.refcodes.mixin.InstanceIdAccessor.InstanceIdBuilder<B>>, org.refcodes.mixin.InstanceIdAccessor.InstanceIdMutator, org.refcodes.mixin.InstanceIdAccessor.InstanceIdPropertyNested classes/interfaces inherited from interface org.refcodes.net.IpAddressAccessor
org.refcodes.net.IpAddressAccessor.IpAddressBuilder<B extends org.refcodes.net.IpAddressAccessor.IpAddressBuilder<B>>, org.refcodes.net.IpAddressAccessor.IpAddressMutator, org.refcodes.net.IpAddressAccessor.IpAddressPropertyNested classes/interfaces inherited from interface org.refcodes.component.LifecycleComponent
org.refcodes.component.LifecycleComponent.LifecycleAutomaton, org.refcodes.component.LifecycleComponent.UncheckedLifecycleComponentNested classes/interfaces inherited from interface org.refcodes.component.LifecycleStatusAccessor
org.refcodes.component.LifecycleStatusAccessor.LifecycleStatusBuilder<B extends org.refcodes.component.LifecycleStatusAccessor.LifecycleStatusBuilder<B>>, org.refcodes.component.LifecycleStatusAccessor.LifecycleStatusMutator, org.refcodes.component.LifecycleStatusAccessor.LifecycleStatusPropertyNested classes/interfaces inherited from interface org.refcodes.component.Pausable
org.refcodes.component.Pausable.PauseAutomaton, org.refcodes.component.Pausable.PauseBuilder<B extends org.refcodes.component.Pausable.PauseBuilder<B>>, org.refcodes.component.Pausable.UncheckedPausableNested classes/interfaces inherited from interface org.refcodes.rest.PingPathAccessor
PingPathAccessor.PingPathBuilder<B extends PingPathAccessor.PingPathBuilder<?>>, PingPathAccessor.PingPathMutator, PingPathAccessor.PingPathPropertyNested classes/interfaces inherited from interface org.refcodes.component.Resumable
org.refcodes.component.Resumable.ResumeAutomaton, org.refcodes.component.Resumable.ResumeBuilder<B extends org.refcodes.component.Resumable.ResumeBuilder<B>>, org.refcodes.component.Resumable.UncheckedResumableNested classes/interfaces inherited from interface org.refcodes.component.RunningAccessor
org.refcodes.component.RunningAccessor.RunningMutator, org.refcodes.component.RunningAccessor.RunningPropertyNested classes/interfaces inherited from interface org.refcodes.component.Startable
org.refcodes.component.Startable.StartAutomaton, org.refcodes.component.Startable.StartBuilder<B extends org.refcodes.component.Startable.StartBuilder<B>>, org.refcodes.component.Startable.UncheckedStartableNested classes/interfaces inherited from interface org.refcodes.component.Stoppable
org.refcodes.component.Stoppable.StopAutomaton, org.refcodes.component.Stoppable.StopBuilder<B extends org.refcodes.component.Stoppable.StopBuilder<B>>, org.refcodes.component.Stoppable.UncheckedStoppableNested classes/interfaces inherited from interface org.refcodes.security.TrustStoreDescriptorAccessor
org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorBuilder<B extends org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorBuilder<B>>, org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorMutator, org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorPropertyNested classes/interfaces inherited from interface org.refcodes.web.VirtualHostAccessor
org.refcodes.web.VirtualHostAccessor.VirtualHostBuilder<B extends org.refcodes.web.VirtualHostAccessor.VirtualHostBuilder<?>>, org.refcodes.web.VirtualHostAccessor.VirtualHostMutator, org.refcodes.web.VirtualHostAccessor.VirtualHostProperty -
Method Summary
Modifier and TypeMethodDescriptionvoiddestroy()This server is taken (removed) from the registry server.default voidInitializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".default voidinitialize(DESC aServerDescriptor, org.refcodes.web.Url aRegistryUrl) Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".voidinitialize(DESC aServerDescriptor, org.refcodes.web.Url aRegistryUrl, org.refcodes.security.TrustStoreDescriptor aStoreDescriptor) Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".default voidinitialize(String aAlias, String aInstanceId, org.refcodes.data.Scheme aScheme, int aPort, org.refcodes.web.Url aRegistryUrl) Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".default voidinitialize(String aAlias, String aInstanceId, org.refcodes.data.Scheme aScheme, String aHost, String aVirtualHost, int[] aIpAddress, int aPort, String aPingPath, org.refcodes.web.Url aRegistryUrl) Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".default voidinitialize(String aAlias, org.refcodes.data.Scheme aScheme, String aHost, int aPort, org.refcodes.web.Url aRegistryUrl) Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".default voidinitialize(String aAlias, org.refcodes.data.Scheme aScheme, String aHost, String aVirtualHost, int[] aIpAddress, int aPort, String aPingPath, org.refcodes.web.Url aRegistryUrl) Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".default voidinitialize(HttpRegistryContext<DESC> aRegistryContext) Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".voidpause()Some "deactivated" status is communicated to the registry server.voidresume()Some "up-and-running (again)" status is communicated to the registry server.voidstart()Some "up-and-running" status is communicated to the registry server.voidstop()Some "out-of-order" status is communicated to the registry server.default Bdefault BwithCidrNotation(String aCidrNotation) default Bdefault BwithHttpRegistryUrl(org.refcodes.web.Url aUrl) Sets the URL for the URL property locating the service registry registry.default BwithHttpServerDescriptor(DESC aServerDescriptor) Sets theHttpServerDescriptorfor theHttpServerDescriptorproperty.default BwithInstanceId(String aInstanceId) default BwithIpAddress(int[] aIpAddress) default BwithPingPath(String aPingPath) Sets the ping path to use and returns this builder as of the builder pattern.default BwithTrustStoreDescriptor(org.refcodes.security.TrustStoreDescriptor aStoreDescriptor) default BwithVirtualHost(String aVirtualHost) Methods inherited from interface org.refcodes.mixin.AliasAccessor
getAliasMethods inherited from interface org.refcodes.mixin.AliasAccessor.AliasMutator
setAliasMethods inherited from interface org.refcodes.mixin.AliasAccessor.AliasProperty
letAliasMethods inherited from interface org.refcodes.component.Configurable
initializeUncheckedMethods inherited from interface org.refcodes.component.Destroyable.DestroyAutomaton
isDestroyable, isDestroyedMethods inherited from interface org.refcodes.web.HostAccessor
getHostMethods inherited from interface org.refcodes.web.HostAccessor.HostMutator
setHostMethods inherited from interface org.refcodes.web.HostAccessor.HostProperty
letHostMethods inherited from interface org.refcodes.rest.HttpRegistryUrlAccessor
getHttpRegistryUrlMethods inherited from interface org.refcodes.rest.HttpRegistryUrlAccessor.HttpRegistryUrlMutator
setHttpRegistryUrlMethods inherited from interface org.refcodes.rest.HttpRegistryUrlAccessor.HttpRegistryUrlProperty
letHttpRegistryUrlMethods inherited from interface org.refcodes.rest.HttpServerDescriptorAccessor
getHttpServerDescriptorMethods inherited from interface org.refcodes.rest.HttpServerDescriptorAccessor.HttpServerDescriptorMutator
setHttpServerDescriptorMethods inherited from interface org.refcodes.rest.HttpServerDescriptorAccessor.HttpServerDescriptorProperty
letHttpServerDescriptorMethods inherited from interface org.refcodes.rest.HttpServerDescriptorFactory
toHttpServerDescriptor, toHttpServerDescriptor, toHttpServerDescriptor, toHttpServerDescriptor, toHttpServerDescriptorMethods inherited from interface org.refcodes.component.Initializable
initializeUncheckedMethods inherited from interface org.refcodes.component.Initializable.InitializeAutomaton
isInitalizableMethods inherited from interface org.refcodes.component.InitializedAccessor
isInitializedMethods inherited from interface org.refcodes.mixin.InstanceIdAccessor
getInstanceIdMethods inherited from interface org.refcodes.mixin.InstanceIdAccessor.InstanceIdMutator
setInstanceIdMethods inherited from interface org.refcodes.mixin.InstanceIdAccessor.InstanceIdProperty
letInstanceIdMethods inherited from interface org.refcodes.net.IpAddressAccessor
getIpAddress, toCidrNotationMethods inherited from interface org.refcodes.net.IpAddressAccessor.IpAddressMutator
fromCidrNotation, setIpAddressMethods inherited from interface org.refcodes.net.IpAddressAccessor.IpAddressProperty
letIpAddressMethods inherited from interface org.refcodes.component.LifecycleStatusAccessor
getLifecycleStatusMethods inherited from interface org.refcodes.component.Pausable
pauseUncheckedMethods inherited from interface org.refcodes.component.Pausable.PauseAutomaton
isPausable, isPausedMethods inherited from interface org.refcodes.rest.PingPathAccessor
getPingPathMethods inherited from interface org.refcodes.rest.PingPathAccessor.PingPathMutator
setPingPathMethods inherited from interface org.refcodes.rest.PingPathAccessor.PingPathProperty
letPingPathMethods inherited from interface org.refcodes.component.Resumable
resumeUncheckedMethods inherited from interface org.refcodes.component.Resumable.ResumeAutomaton
isResumableMethods inherited from interface org.refcodes.component.RunningAccessor
isRunningMethods inherited from interface org.refcodes.component.Startable
startUncheckedMethods inherited from interface org.refcodes.component.Startable.StartAutomaton
isStartableMethods inherited from interface org.refcodes.component.Stoppable
stopUncheckedMethods inherited from interface org.refcodes.component.Stoppable.StopAutomaton
isStoppable, isStoppedMethods inherited from interface org.refcodes.security.TrustStoreDescriptorAccessor
getTrustStoreDescriptorMethods inherited from interface org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorMutator
setTrustStoreDescriptorMethods inherited from interface org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorProperty
letTrustStoreDescriptorMethods inherited from interface org.refcodes.web.VirtualHostAccessor
getVirtualHostMethods inherited from interface org.refcodes.web.VirtualHostAccessor.VirtualHostMutator
setVirtualHostMethods inherited from interface org.refcodes.web.VirtualHostAccessor.VirtualHostProperty
letVirtualHost
-
Method Details
-
withAlias
- Specified by:
withAliasin interfaceorg.refcodes.mixin.AliasAccessor.AliasBuilder<DESC extends HttpServerDescriptor>
-
withPingPath
Sets the ping path to use and returns this builder as of the builder pattern.- Specified by:
withPingPathin interfacePingPathAccessor.PingPathBuilder<DESC extends HttpServerDescriptor>- Parameters:
aPingPath- The ping path to be stored by the ping path property.- Returns:
- This
PingPathAccessor.PingPathBuilderinstance to continue configuration.
-
withHttpRegistryUrl
Sets the URL for the URL property locating the service registry registry.- Specified by:
withHttpRegistryUrlin interfaceHttpRegistryUrlAccessor.HttpRegistryUrlBuilder<DESC extends HttpServerDescriptor>- Parameters:
aUrl- The service registry registry URL to be stored by the URL property.- Returns:
- The builder for applying multiple build operations.
-
withHttpServerDescriptor
Sets theHttpServerDescriptorfor theHttpServerDescriptorproperty.- Specified by:
withHttpServerDescriptorin interfaceHttpServerDescriptorAccessor.HttpServerDescriptorBuilder<DESC extends HttpServerDescriptor,B extends HttpRegistry<DESC, B>> - Parameters:
aServerDescriptor- TheHttpServerDescriptorto be stored by theHttpServerDescriptorproperty.- Returns:
- The builder for applying multiple build operations.
-
withHost
- Specified by:
withHostin interfaceorg.refcodes.web.HostAccessor.HostBuilder<DESC extends HttpServerDescriptor>
-
withVirtualHost
- Specified by:
withVirtualHostin interfaceorg.refcodes.web.VirtualHostAccessor.VirtualHostBuilder<DESC extends HttpServerDescriptor>
-
withIpAddress
- Specified by:
withIpAddressin interfaceorg.refcodes.net.IpAddressAccessor.IpAddressBuilder<DESC extends HttpServerDescriptor>
-
withCidrNotation
- Specified by:
withCidrNotationin interfaceorg.refcodes.net.IpAddressAccessor.IpAddressBuilder<DESC extends HttpServerDescriptor>
-
withTrustStoreDescriptor
- Specified by:
withTrustStoreDescriptorin interfaceorg.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorBuilder<DESC extends HttpServerDescriptor>
-
withInstanceId
- Specified by:
withInstanceIdin interfaceorg.refcodes.mixin.InstanceIdAccessor.InstanceIdBuilder<DESC extends HttpServerDescriptor>
-
initialize
default void initialize() throws org.refcodes.component.InitializeExceptionInitializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".- Specified by:
initializein interfaceorg.refcodes.component.Initializable- Throws:
org.refcodes.component.InitializeException
-
initialize
default void initialize(HttpRegistryContext<DESC> aRegistryContext) throws org.refcodes.component.InitializeException Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".- Specified by:
initializein interfaceorg.refcodes.component.Configurable<DESC extends HttpServerDescriptor>- Parameters:
aRegistryContext- The context providing the descriptor of the server to be registered and theUrlof the service registry to be used as well as the required truststore.- Throws:
org.refcodes.component.InitializeException- thrown in case initializing a component caused problems. Usually a method similar to "initialize()" throws such an exception.
-
initialize
default void initialize(DESC aServerDescriptor, org.refcodes.web.Url aRegistryUrl) throws org.refcodes.component.InitializeException Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".- Parameters:
aServerDescriptor- The descriptor of the server to be registered.aRegistryUrl- The URL of the service registry to be used.- Throws:
org.refcodes.component.InitializeException- thrown in case initializing a component caused problems. Usually a method similar to "initialize()" throws such an exception.
-
initialize
void initialize(DESC aServerDescriptor, org.refcodes.web.Url aRegistryUrl, org.refcodes.security.TrustStoreDescriptor aStoreDescriptor) throws org.refcodes.component.InitializeException Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".- Parameters:
aServerDescriptor- The descriptor of the server to be registered.aRegistryUrl- The URL of the service registry to be used.aStoreDescriptor- The descriptor describing the truststore for (optionally) opening an HTTPS connection to the registry server.- Throws:
org.refcodes.component.InitializeException- thrown in case initializing a component caused problems. Usually a method similar to "initialize()" throws such an exception.
-
initialize
default void initialize(String aAlias, String aInstanceId, org.refcodes.data.Scheme aScheme, int aPort, org.refcodes.web.Url aRegistryUrl) throws org.refcodes.component.InitializeException Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".- Parameters:
aAlias- The name ("alias") which identifies the server in the registry.aInstanceId- The TID for the instance when being registered at the service registry. If omitted, then the host name is used.aScheme- TheSchemeto which this server is being attached (HTTP or HTTPS).aPort- The port of your service being registered.aRegistryUrl- The registry server where to register.- Throws:
org.refcodes.component.InitializeException- thrown in case initializing a component caused problems. Usually a method similar to "initialize()" throws such an exception.
-
initialize
default void initialize(String aAlias, org.refcodes.data.Scheme aScheme, String aHost, int aPort, org.refcodes.web.Url aRegistryUrl) throws org.refcodes.component.InitializeException Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".- Parameters:
aAlias- The name ("alias") which identifies the server in the registry.aScheme- TheSchemeto which this server is being attached (HTTP or HTTPS).aHost- The host name to be used to address this server. If omitted, then the system's host name should be used.aPort- The port of your service being registered.aRegistryUrl- The registry server where to register.- Throws:
org.refcodes.component.InitializeException- thrown in case initializing a component caused problems. Usually a method similar to "initialize()" throws such an exception.
-
initialize
default void initialize(String aAlias, org.refcodes.data.Scheme aScheme, String aHost, String aVirtualHost, int[] aIpAddress, int aPort, String aPingPath, org.refcodes.web.Url aRegistryUrl) throws org.refcodes.component.InitializeException Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".- Parameters:
aAlias- The name ("alias") which identifies the server in the registry.aScheme- TheSchemeto which this server is being attached (HTTP or HTTPS).aHost- The host name to be used to address this server. If omitted, then the system's host name should be used.aVirtualHost- The virtual host name to be used for resolving.aIpAddress- The IP-Address identifying the host.aPort- The port of your service being registered.aPingPath- The path to use as health-check end-point by this server.aRegistryUrl- The registry server where to register.- Throws:
org.refcodes.component.InitializeException- thrown in case initializing a component caused problems. Usually a method similar to "initialize()" throws such an exception.
-
initialize
default void initialize(String aAlias, String aInstanceId, org.refcodes.data.Scheme aScheme, String aHost, String aVirtualHost, int[] aIpAddress, int aPort, String aPingPath, org.refcodes.web.Url aRegistryUrl) throws org.refcodes.component.InitializeException Initializes theHttpRegistryby registering it at the service registry with a status such as "starting" or "initializing" or "not-ready-yet".- Parameters:
aAlias- The name ("alias") which identifies the server in the registry.aInstanceId- The TID for the instance when being registered at the service registry. If omitted, then the host name is used.aScheme- TheSchemeto which this server is being attached (HTTP or HTTPS).aHost- The host name to be used to address this server. If omitted, then the system's host name should be used.aVirtualHost- The virtual host name to be used for resolving.aIpAddress- The IP-Address identifying the host.aPort- The port of your service being registered.aPingPath- The path to use as health-check end-point by this server.aRegistryUrl- The registry server where to register.- Throws:
org.refcodes.component.InitializeException- thrown in case initializing a component caused problems. Usually a method similar to "initialize()" throws such an exception.
-
start
void start() throws org.refcodes.component.StartExceptionSome "up-and-running" status is communicated to the registry server. May also start a "ping" or "heartbeat" daemon.- Specified by:
startin interfaceorg.refcodes.component.Startable- Throws:
org.refcodes.component.StartException
-
pause
void pause() throws org.refcodes.component.PauseExceptionSome "deactivated" status is communicated to the registry server.- Specified by:
pausein interfaceorg.refcodes.component.Pausable- Throws:
org.refcodes.component.PauseException
-
resume
void resume() throws org.refcodes.component.ResumeExceptionSome "up-and-running (again)" status is communicated to the registry server.- Specified by:
resumein interfaceorg.refcodes.component.Resumable- Throws:
org.refcodes.component.ResumeException
-
stop
void stop() throws org.refcodes.component.StopExceptionSome "out-of-order" status is communicated to the registry server. Also stops a "ping" or "heartbeat" daemon.- Specified by:
stopin interfaceorg.refcodes.component.Stoppable- Throws:
org.refcodes.component.StopException
-
destroy
void destroy()This server is taken (removed) from the registry server. Also stops a "ping" or "heartbeat" daemon. Finally the connection is closed.- Specified by:
destroyin interfaceorg.refcodes.component.Destroyable
-