Package org.refcodes.rest.ext.eureka
Class EurekaRestServerDecorator
- java.lang.Object
-
- org.refcodes.rest.AbstractHttpRestServerDecorator<B>
-
- org.refcodes.rest.AbstractHttpRegistryRestServerDecorator<EurekaServerDescriptor,EurekaRestServer>
-
- org.refcodes.rest.ext.eureka.EurekaRestServerDecorator
-
- All Implemented Interfaces:
org.refcodes.component.Closable
,org.refcodes.component.Closable.CloseBuilder<EurekaServerDescriptor>
,org.refcodes.component.Configurable<EurekaServerDescriptor>
,org.refcodes.component.ConnectionComponent<EurekaServerDescriptor>
,org.refcodes.component.ConnectionComponent.ConnectionComponentBuilder<EurekaServerDescriptor,EurekaRestServer>
,org.refcodes.component.ConnectionOpenable<EurekaServerDescriptor>
,org.refcodes.component.ConnectionOpenable.ConnectionOpenBuilder<EurekaServerDescriptor,EurekaRestServer>
,org.refcodes.component.ConnectionStatusAccessor
,org.refcodes.component.Destroyable
,org.refcodes.component.Destroyable.DestroyAutomaton
,org.refcodes.component.Initializable
,org.refcodes.component.Initializable.InitializeAutomaton
,org.refcodes.component.InitializedAccessor
,org.refcodes.component.LifeCycleComponent
,org.refcodes.component.LifeCycleComponent.LifeCycleAutomaton
,org.refcodes.component.LifeCycleStatusAccessor
,org.refcodes.component.LinkComponent
,org.refcodes.component.Openable
,org.refcodes.component.Pausable
,org.refcodes.component.Pausable.PauseAutomaton
,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.io.MaxConnectionsAccessor
,org.refcodes.io.MaxConnectionsAccessor.MaxConnectionsBuilder<EurekaServerDescriptor>
,org.refcodes.io.MaxConnectionsAccessor.MaxConnectionsMutator
,org.refcodes.io.MaxConnectionsAccessor.MaxConnectionsProperty
,org.refcodes.mixin.AliasAccessor
,org.refcodes.mixin.AliasAccessor.AliasBuilder<EurekaServerDescriptor>
,org.refcodes.mixin.AliasAccessor.AliasMutator
,org.refcodes.mixin.AliasAccessor.AliasProperty
,org.refcodes.mixin.InstanceIdAccessor
,org.refcodes.mixin.InstanceIdAccessor.InstanceIdBuilder<EurekaServerDescriptor>
,org.refcodes.mixin.InstanceIdAccessor.InstanceIdMutator
,org.refcodes.mixin.InstanceIdAccessor.InstanceIdProperty
,org.refcodes.mixin.PortAccessor
,org.refcodes.mixin.PortAccessor.PortBuilder<EurekaServerDescriptor>
,org.refcodes.mixin.PortAccessor.PortMutator
,org.refcodes.mixin.PortAccessor.PortProperty
,org.refcodes.net.BaseLocatorAccessor
,org.refcodes.net.BaseLocatorAccessor.BaseLocatorBuilder<EurekaServerDescriptor>
,org.refcodes.net.BaseLocatorAccessor.BaseLocatorMutator
,org.refcodes.net.BaseLocatorAccessor.BaseLocatorProperty
,org.refcodes.net.BasicAuthObservable<EurekaServerDescriptor>
,org.refcodes.net.HostAccessor
,org.refcodes.net.HostAccessor.HostBuilder<EurekaServerDescriptor>
,org.refcodes.net.HostAccessor.HostMutator
,org.refcodes.net.HostAccessor.HostProperty
,org.refcodes.net.HttpsConnectionRequestObservable<EurekaServerDescriptor>
,org.refcodes.net.IpAddressAccessor
,org.refcodes.net.IpAddressAccessor.IpAddressBuilder<EurekaServerDescriptor>
,org.refcodes.net.IpAddressAccessor.IpAddressMutator
,org.refcodes.net.IpAddressAccessor.IpAddressProperty
,org.refcodes.net.MediaTypeFactoryLookup
,org.refcodes.net.MediaTypeFactoryLookup.MutableMediaTypeFactoryLookup
,org.refcodes.net.RealmAccessor
,org.refcodes.net.RealmAccessor.RealmBuilder<EurekaServerDescriptor>
,org.refcodes.net.RealmAccessor.RealmMutator
,org.refcodes.net.RealmAccessor.RealmProperty
,org.refcodes.net.SchemeAccessor
,org.refcodes.net.SchemeAccessor.SchemeBuilder<EurekaServerDescriptor>
,org.refcodes.net.SchemeAccessor.SchemeMutator
,org.refcodes.net.SchemeAccessor.SchemeProperty
,org.refcodes.net.VirtualHostAccessor
,org.refcodes.net.VirtualHostAccessor.VirtualHostBuilder<EurekaServerDescriptor>
,org.refcodes.net.VirtualHostAccessor.VirtualHostMutator
,org.refcodes.net.VirtualHostAccessor.VirtualHostProperty
,org.refcodes.observer.Observable<EurekaServerDescriptor>
,org.refcodes.observer.Observers<EurekaServerDescriptor,EurekaRestServer>
,EurekaDataCenterTypeAccessor
,EurekaDataCenterTypeAccessor.EurekaDataCenterTypeBuilder<EurekaServerDescriptor>
,EurekaDataCenterTypeAccessor.EurekaDataCenterTypeMutator
,EurekaDataCenterTypeAccessor.EurekaDataCenterTypeProperty
,EurekaRegistry<EurekaServerDescriptor>
,EurekaRestServer
,EurekaServerDescriptorFactory
,org.refcodes.rest.HomePathAccessor
,org.refcodes.rest.HomePathAccessor.HomePathBuilder<EurekaServerDescriptor>
,org.refcodes.rest.HomePathAccessor.HomePathMutator
,org.refcodes.rest.HomePathAccessor.HomePathProperty
,org.refcodes.rest.HomeRequestObserver
,org.refcodes.rest.HomeRequestObserverAccessor
,org.refcodes.rest.HomeRequestObserverAccessor.HomeRequestObserverBuilder<EurekaServerDescriptor>
,org.refcodes.rest.HttpExceptionHandlerAccessor
,org.refcodes.rest.HttpExceptionHandlerAccessor.HttpExceptionHandlerBuilder<EurekaServerDescriptor>
,org.refcodes.rest.HttpExceptionHandlerAccessor.HttpExceptionHandlerMutator
,org.refcodes.rest.HttpExceptionHandlerAccessor.HttpExceptionHandlerProperty
,org.refcodes.rest.HttpExceptionHandlingAccessor
,org.refcodes.rest.HttpExceptionHandlingAccessor.HttpExceptionHandlingBuilder<EurekaServerDescriptor>
,org.refcodes.rest.HttpExceptionHandlingAccessor.HttpExceptionHandlingMutator
,org.refcodes.rest.HttpExceptionHandlingAccessor.HttpExceptionHandlingProperty
,org.refcodes.rest.HttpRegistry<EurekaServerDescriptor,EurekaRestServer>
,org.refcodes.rest.HttpRegistryRestServer<EurekaServerDescriptor,EurekaRestServer>
,org.refcodes.rest.HttpRegistryUrlAccessor
,org.refcodes.rest.HttpRegistryUrlAccessor.HttpRegistryUrlBuilder<EurekaServerDescriptor>
,org.refcodes.rest.HttpRegistryUrlAccessor.HttpRegistryUrlMutator
,org.refcodes.rest.HttpRegistryUrlAccessor.HttpRegistryUrlProperty
,org.refcodes.rest.HttpRestServer
,org.refcodes.rest.HttpServerDescriptorAccessor<EurekaServerDescriptor>
,org.refcodes.rest.HttpServerDescriptorAccessor.HttpServerDescriptorBuilder<EurekaServerDescriptor,EurekaRestServer>
,org.refcodes.rest.HttpServerDescriptorAccessor.HttpServerDescriptorMutator<EurekaServerDescriptor>
,org.refcodes.rest.HttpServerDescriptorAccessor.HttpServerDescriptorProperty<EurekaServerDescriptor>
,org.refcodes.rest.HttpServerDescriptorFactory<EurekaServerDescriptor>
,org.refcodes.rest.PingPathAccessor
,org.refcodes.rest.PingPathAccessor.PingPathBuilder<EurekaServerDescriptor>
,org.refcodes.rest.PingPathAccessor.PingPathMutator
,org.refcodes.rest.PingPathAccessor.PingPathProperty
,org.refcodes.rest.PingRequestObserver
,org.refcodes.rest.PingRequestObserverAccessor
,org.refcodes.rest.PingRequestObserverAccessor.PingRequestObserverBuilder<EurekaServerDescriptor>
,org.refcodes.rest.RestServer
,org.refcodes.rest.StatusPathAccessor
,org.refcodes.rest.StatusPathAccessor.StatusPathBuilder<EurekaServerDescriptor>
,org.refcodes.rest.StatusPathAccessor.StatusPathMutator
,org.refcodes.rest.StatusPathAccessor.StatusPathProperty
,org.refcodes.rest.StatusRequestObserver
,org.refcodes.rest.StatusRequestObserverAccessor
,org.refcodes.rest.StatusRequestObserverAccessor.StatusRequestObserverBuilder<EurekaServerDescriptor>
,org.refcodes.runtime.RequestCorrelation<EurekaServerDescriptor>
,org.refcodes.runtime.SessionCorrelation<EurekaServerDescriptor>
,org.refcodes.security.KeyStoreDescriptorAccessor
,org.refcodes.security.KeyStoreDescriptorAccessor.KeyStoreDescriptorBuilder<EurekaServerDescriptor>
,org.refcodes.security.KeyStoreDescriptorAccessor.KeyStoreDescriptorMutator
,org.refcodes.security.KeyStoreDescriptorAccessor.KeyStoreDescriptorProperty
,org.refcodes.security.TrustStoreDescriptorAccessor
,org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorBuilder<EurekaServerDescriptor>
,org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorMutator
,org.refcodes.security.TrustStoreDescriptorAccessor.TrustStoreDescriptorProperty
- Direct Known Subclasses:
EurekaRestServerImpl
public class EurekaRestServerDecorator extends org.refcodes.rest.AbstractHttpRegistryRestServerDecorator<EurekaServerDescriptor,EurekaRestServer> implements EurekaRestServer
TheEurekaRestServerDecorator
implements theEurekaRestServer
interface and decorates a givenHttpRestServer
with functionality such registering and unregistering from or to an Eureka discovery service. Follow the documentation of theEurekaRestServer
in order to initiate the states such asEurekaServiceStatus.UP
,EurekaServiceStatus.DOWN
orEurekaServiceStatus.OUT_OF_SERVICE
and unregistering.
-
-
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.AliasProperty
-
Nested classes/interfaces inherited from interface org.refcodes.net.BaseLocatorAccessor
org.refcodes.net.BaseLocatorAccessor.BaseLocatorBuilder<B extends org.refcodes.net.BaseLocatorAccessor.BaseLocatorBuilder<B>>, org.refcodes.net.BaseLocatorAccessor.BaseLocatorMutator, org.refcodes.net.BaseLocatorAccessor.BaseLocatorProperty
-
Nested classes/interfaces inherited from interface org.refcodes.component.Closable
org.refcodes.component.Closable.CloseAutomaton, org.refcodes.component.Closable.CloseBuilder<B extends org.refcodes.component.Closable.CloseBuilder<B>>
-
Nested classes/interfaces inherited from interface org.refcodes.component.Configurable
org.refcodes.component.Configurable.ConfigureAutomaton<CTX extends java.lang.Object>, org.refcodes.component.Configurable.ConfigureBuilder<CTX extends java.lang.Object,B extends org.refcodes.component.Configurable.ConfigureBuilder<CTX,B>>
-
Nested classes/interfaces inherited from interface org.refcodes.component.ConnectionComponent
org.refcodes.component.ConnectionComponent.ConnectionAutomaton<CON extends java.lang.Object>, org.refcodes.component.ConnectionComponent.ConnectionComponentBuilder<CON extends java.lang.Object,B extends org.refcodes.component.ConnectionComponent.ConnectionComponentBuilder<CON,B>>
-
Nested classes/interfaces inherited from interface org.refcodes.component.ConnectionOpenable
org.refcodes.component.ConnectionOpenable.ConnectionOpenAutomaton<CON extends java.lang.Object>, org.refcodes.component.ConnectionOpenable.ConnectionOpenBuilder<CON extends java.lang.Object,B extends org.refcodes.component.ConnectionOpenable.ConnectionOpenBuilder<CON,B>>
-
Nested classes/interfaces inherited from interface org.refcodes.component.ConnectionStatusAccessor
org.refcodes.component.ConnectionStatusAccessor.ConnectionStatusMutator, org.refcodes.component.ConnectionStatusAccessor.ConnectionStatusProperty
-
Nested classes/interfaces inherited from interface org.refcodes.component.Destroyable
org.refcodes.component.Destroyable.DestroyAutomaton
-
Nested classes/interfaces inherited from interface org.refcodes.rest.ext.eureka.EurekaDataCenterTypeAccessor
EurekaDataCenterTypeAccessor.EurekaDataCenterTypeBuilder<B extends EurekaDataCenterTypeAccessor.EurekaDataCenterTypeBuilder<?>>, EurekaDataCenterTypeAccessor.EurekaDataCenterTypeMutator, EurekaDataCenterTypeAccessor.EurekaDataCenterTypeProperty
-
Nested classes/interfaces inherited from interface org.refcodes.rest.HomePathAccessor
org.refcodes.rest.HomePathAccessor.HomePathBuilder<B extends org.refcodes.rest.HomePathAccessor.HomePathBuilder<?>>, org.refcodes.rest.HomePathAccessor.HomePathMutator, org.refcodes.rest.HomePathAccessor.HomePathProperty
-
Nested classes/interfaces inherited from interface org.refcodes.rest.HomeRequestObserverAccessor
org.refcodes.rest.HomeRequestObserverAccessor.HomeRequestObserverBuilder<B extends org.refcodes.rest.HomeRequestObserverAccessor.HomeRequestObserverBuilder<B>>, org.refcodes.rest.HomeRequestObserverAccessor.HomeRequestObserverMutator, org.refcodes.rest.HomeRequestObserverAccessor.HomeRequestObserverProperty
-
Nested classes/interfaces inherited from interface org.refcodes.net.HostAccessor
org.refcodes.net.HostAccessor.HostBuilder<B extends org.refcodes.net.HostAccessor.HostBuilder<?>>, org.refcodes.net.HostAccessor.HostMutator, org.refcodes.net.HostAccessor.HostProperty
-
Nested classes/interfaces inherited from interface org.refcodes.rest.HttpExceptionHandlerAccessor
org.refcodes.rest.HttpExceptionHandlerAccessor.HttpExceptionHandlerBuilder<B extends org.refcodes.rest.HttpExceptionHandlerAccessor.HttpExceptionHandlerBuilder<B>>, org.refcodes.rest.HttpExceptionHandlerAccessor.HttpExceptionHandlerMutator, org.refcodes.rest.HttpExceptionHandlerAccessor.HttpExceptionHandlerProperty
-
Nested classes/interfaces inherited from interface org.refcodes.rest.HttpExceptionHandlingAccessor
org.refcodes.rest.HttpExceptionHandlingAccessor.HttpExceptionHandlingBuilder<B extends org.refcodes.rest.HttpExceptionHandlingAccessor.HttpExceptionHandlingBuilder<B>>, org.refcodes.rest.HttpExceptionHandlingAccessor.HttpExceptionHandlingMutator, org.refcodes.rest.HttpExceptionHandlingAccessor.HttpExceptionHandlingProperty
-
Nested classes/interfaces inherited from interface org.refcodes.rest.HttpRegistryUrlAccessor
org.refcodes.rest.HttpRegistryUrlAccessor.HttpRegistryUrlBuilder<B extends org.refcodes.rest.HttpRegistryUrlAccessor.HttpRegistryUrlBuilder<B>>, org.refcodes.rest.HttpRegistryUrlAccessor.HttpRegistryUrlMutator, org.refcodes.rest.HttpRegistryUrlAccessor.HttpRegistryUrlProperty
-
Nested classes/interfaces inherited from interface org.refcodes.rest.HttpServerDescriptorAccessor
org.refcodes.rest.HttpServerDescriptorAccessor.HttpServerDescriptorBuilder<DESC extends org.refcodes.rest.HttpServerDescriptor,B extends org.refcodes.rest.HttpServerDescriptorAccessor.HttpServerDescriptorBuilder<DESC,B>>, org.refcodes.rest.HttpServerDescriptorAccessor.HttpServerDescriptorMutator<DESC extends org.refcodes.rest.HttpServerDescriptor>, org.refcodes.rest.HttpServerDescriptorAccessor.HttpServerDescriptorProperty<DESC extends org.refcodes.rest.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.UncheckedInitializable
-
Nested classes/interfaces inherited from interface org.refcodes.component.InitializedAccessor
org.refcodes.component.InitializedAccessor.InitializedMutator, org.refcodes.component.InitializedAccessor.InitializedProperty
-
Nested 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.InstanceIdProperty
-
Nested 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.IpAddressProperty
-
Nested classes/interfaces inherited from interface org.refcodes.security.KeyStoreDescriptorAccessor
org.refcodes.security.KeyStoreDescriptorAccessor.KeyStoreDescriptorBuilder<B extends org.refcodes.security.KeyStoreDescriptorAccessor.KeyStoreDescriptorBuilder<B>>, org.refcodes.security.KeyStoreDescriptorAccessor.KeyStoreDescriptorMutator, org.refcodes.security.KeyStoreDescriptorAccessor.KeyStoreDescriptorProperty
-
Nested classes/interfaces inherited from interface org.refcodes.component.LifeCycleComponent
org.refcodes.component.LifeCycleComponent.LifeCycleAutomaton, org.refcodes.component.LifeCycleComponent.UncheckedLifeCycleComponent
-
Nested 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.LifeCycleStatusProperty
-
Nested classes/interfaces inherited from interface org.refcodes.component.LinkComponent
org.refcodes.component.LinkComponent.LinkAutomaton, org.refcodes.component.LinkComponent.LinkComponentBuilder<B extends org.refcodes.component.LinkComponent.LinkComponentBuilder<B>>
-
Nested classes/interfaces inherited from interface org.refcodes.io.MaxConnectionsAccessor
org.refcodes.io.MaxConnectionsAccessor.MaxConnectionsBuilder<B extends org.refcodes.io.MaxConnectionsAccessor.MaxConnectionsBuilder<B>>, org.refcodes.io.MaxConnectionsAccessor.MaxConnectionsMutator, org.refcodes.io.MaxConnectionsAccessor.MaxConnectionsProperty
-
Nested classes/interfaces inherited from interface org.refcodes.net.MediaTypeFactoryLookup
org.refcodes.net.MediaTypeFactoryLookup.MutableMediaTypeFactoryLookup
-
Nested classes/interfaces inherited from interface org.refcodes.component.Openable
org.refcodes.component.Openable.OpenAutomaton, org.refcodes.component.Openable.OpenBuilder<B extends org.refcodes.component.Openable.OpenBuilder<B>>
-
Nested 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.UncheckedPausable
-
Nested classes/interfaces inherited from interface org.refcodes.rest.PingPathAccessor
org.refcodes.rest.PingPathAccessor.PingPathBuilder<B extends org.refcodes.rest.PingPathAccessor.PingPathBuilder<?>>, org.refcodes.rest.PingPathAccessor.PingPathMutator, org.refcodes.rest.PingPathAccessor.PingPathProperty
-
Nested classes/interfaces inherited from interface org.refcodes.rest.PingRequestObserverAccessor
org.refcodes.rest.PingRequestObserverAccessor.PingRequestObserverBuilder<B extends org.refcodes.rest.PingRequestObserverAccessor.PingRequestObserverBuilder<B>>, org.refcodes.rest.PingRequestObserverAccessor.PingRequestObserverMutator, org.refcodes.rest.PingRequestObserverAccessor.PingRequestObserverProperty
-
Nested classes/interfaces inherited from interface org.refcodes.mixin.PortAccessor
org.refcodes.mixin.PortAccessor.PortBuilder<B extends org.refcodes.mixin.PortAccessor.PortBuilder<B>>, org.refcodes.mixin.PortAccessor.PortMutator, org.refcodes.mixin.PortAccessor.PortProperty
-
Nested classes/interfaces inherited from interface org.refcodes.net.RealmAccessor
org.refcodes.net.RealmAccessor.RealmBuilder<B extends org.refcodes.net.RealmAccessor.RealmBuilder<B>>, org.refcodes.net.RealmAccessor.RealmMutator, org.refcodes.net.RealmAccessor.RealmProperty
-
Nested 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.UncheckedResumable
-
Nested classes/interfaces inherited from interface org.refcodes.component.RunningAccessor
org.refcodes.component.RunningAccessor.RunningMutator, org.refcodes.component.RunningAccessor.RunningProperty
-
Nested classes/interfaces inherited from interface org.refcodes.net.SchemeAccessor
org.refcodes.net.SchemeAccessor.SchemeBuilder<B extends org.refcodes.net.SchemeAccessor.SchemeBuilder<B>>, org.refcodes.net.SchemeAccessor.SchemeMutator, org.refcodes.net.SchemeAccessor.SchemeProperty
-
Nested 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.UncheckedStartable
-
Nested classes/interfaces inherited from interface org.refcodes.rest.StatusPathAccessor
org.refcodes.rest.StatusPathAccessor.StatusPathBuilder<B extends org.refcodes.rest.StatusPathAccessor.StatusPathBuilder<?>>, org.refcodes.rest.StatusPathAccessor.StatusPathMutator, org.refcodes.rest.StatusPathAccessor.StatusPathProperty
-
Nested classes/interfaces inherited from interface org.refcodes.rest.StatusRequestObserverAccessor
org.refcodes.rest.StatusRequestObserverAccessor.StatusRequestObserverBuilder<B extends org.refcodes.rest.StatusRequestObserverAccessor.StatusRequestObserverBuilder<B>>, org.refcodes.rest.StatusRequestObserverAccessor.StatusRequestObserverMutator, org.refcodes.rest.StatusRequestObserverAccessor.StatusRequestObserverProperty
-
Nested 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.UncheckedStoppable
-
Nested 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.TrustStoreDescriptorProperty
-
Nested classes/interfaces inherited from interface org.refcodes.net.VirtualHostAccessor
org.refcodes.net.VirtualHostAccessor.VirtualHostBuilder<B extends org.refcodes.net.VirtualHostAccessor.VirtualHostBuilder<?>>, org.refcodes.net.VirtualHostAccessor.VirtualHostMutator, org.refcodes.net.VirtualHostAccessor.VirtualHostProperty
-
-
Field Summary
-
Fields inherited from class org.refcodes.rest.AbstractHttpRegistryRestServerDecorator
_lifeCycleAutomaton, _pingRequestObserver
-
Fields inherited from interface org.refcodes.rest.ext.eureka.EurekaRegistry
EUREKA_BASE_PATH
-
-
Constructor Summary
Constructors Constructor Description EurekaRestServerDecorator(org.refcodes.rest.HttpRestServer aServer)
Decorates the givenHttpRestServer
with discovery functionality.EurekaRestServerDecorator(org.refcodes.rest.HttpRestServer aServer, java.util.concurrent.ExecutorService aExecutorService)
Decorates the givenHttpRestServer
with discovery functionality.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
destroy()
protected void
doDeregister()
Unregisters the given service at Eureka.protected void
doRegister(EurekaServiceStatus aServiceStatus)
Registers the given service at Eureka.protected void
doStatusUpdate(EurekaServiceStatus aServiceStatus)
Does a Eureka status update for the given service.org.refcodes.component.ConnectionStatus
getConnectionStatus()
EurekaDataCenterType
getEurekaDataCenterType()
Retrieves the Eureka data center type from the Eureka data center type property.java.lang.String
getHomePath()
org.refcodes.rest.RestRequestObserver
getHomeRequestObserver()
org.refcodes.rest.HttpExceptionHandler
getHttpExceptionHandler()
org.refcodes.rest.HttpExceptionHandling
getHttpExceptionHandling()
java.lang.String
getStatusPath()
org.refcodes.rest.RestRequestObserver
getStatusRequestObserver()
void
initialize(EurekaServerDescriptor aServerDescriptor, org.refcodes.rest.RestRequestObserver aPingObserver, org.refcodes.rest.RestRequestObserver aStatusObserver, org.refcodes.rest.RestRequestObserver aHomeObserver, org.refcodes.net.Url aRegistryUrl, org.refcodes.security.TrustStoreDescriptor aStoreDescriptor)
Initializes theHttpRegistryRestServer
by registering it at the service registry.boolean
isObserversActive()
void
onHomeRequest(org.refcodes.rest.RestRequestObserver aRequestObserver)
void
onStatusRequest(org.refcodes.rest.RestRequestObserver aRequestObserver)
void
pause()
void
resume()
void
setEurekaDataCenterType(EurekaDataCenterType aDataCenterType)
Sets the Eureka data center type for the Eureka data center type property.void
setHomePath(java.lang.String aHomePath)
void
setHttpExceptionHandler(org.refcodes.rest.HttpExceptionHandler aHttpErrorHandler)
void
setHttpExceptionHandling(org.refcodes.rest.HttpExceptionHandling aHttpErrorHandling)
void
setObserversActive(boolean isActive)
void
setStatusPath(java.lang.String aStatusPath)
void
start()
void
stop()
protected org.refcodes.rest.RestRequestObserver
toHomeObserver(org.refcodes.rest.RestRequestObserver aHomeRequestObserver)
Resolves the property from the provided value and this instance and sets the property in case the provided value is not null.protected org.refcodes.net.Url
toHttpRegistryUrl(org.refcodes.net.Url aRegistryUrl)
Resolves the property from the provided value and this instance and sets the property in case the provided value is not null.EurekaServerDescriptor
toHttpServerDescriptor(java.lang.String aAlias, java.lang.String aInstanceId, org.refcodes.data.Scheme aScheme, java.lang.String aHost, java.lang.String aVirtualHost, int[] aIpAddress, int aPort, java.lang.String aPingPath, java.lang.String aStatusPath, java.lang.String aHomePath, EurekaDataCenterType aDataCenterType)
Prepares theHttpServerDescriptor
by creating it from this instance's state and the provided arguments.protected org.refcodes.rest.RestRequestObserver
toStatusObserver(org.refcodes.rest.RestRequestObserver aStatusRequestObserver)
Resolves the property from the provided value and this instance and sets the property in case the provided value is not null.EurekaRestServer
withHttpExceptionHandler(org.refcodes.rest.HttpExceptionHandler aHttpErrorHandler)
EurekaRestServer
withHttpExceptionHandling(org.refcodes.rest.HttpExceptionHandling aHttpErrorHandling)
-
Methods inherited from class org.refcodes.rest.AbstractHttpRegistryRestServerDecorator
getAlias, getHost, getHttpRegistryUrl, getHttpServerDescriptor, getInstanceId, getIpAddress, getLifeCycleStatus, getPingPath, getPingRequestObserver, getTrustStoreDescriptor, getVirtualHost, initialize, isDestroyable, isDestroyed, isInitalizable, isInitialized, isPausable, isPaused, isResumable, isRunning, isStartable, isStoppable, isStopped, onPingRequest, setAlias, setHost, setHttpRegistryUrl, setHttpServerDescriptor, setInstanceId, setIpAddress, setPingPath, setTrustStoreDescriptor, setVirtualHost, toAlias, toHost, toHttpServerDescriptor, toInstanceId, toIpAddress, toPingObserver, toPingPath, toPort, toScheme, toTrustStoreDescriptor, toVirtualHost
-
Methods inherited from class org.refcodes.rest.AbstractHttpRestServerDecorator
addMediaTypeFactory, close, closeIn, closeQuietly, closeUnchecked, disableRequestCorrelation, disableSessionCorrelation, enableRequestCorrelation, enableSessionCorrelation, getBaseLocator, getFactoryMediaTypes, getKeyStoreDescriptor, getMaxConnections, getPort, getRealm, getScheme, hasMediaTypeFactory, hasObserverSubscription, hasRequestCorrelation, hasSessionCorrelation, observers, onBasicAuthRequest, onConnectionRequest, onDelete, onGet, onPost, onPut, onRequest, onRequest, onRequest, open, open, open, open, openUnchecked, setBaseLocator, setKeyStoreDescriptor, setMaxConnections, setPort, setProtocol, setRealm, setRequestCorrelation, setScheme, setSessionCorrelation, subscribeObserver, toMediaTypeFactory, toProtocol, unsubscribeObserver, withBaseLocator, withClose, withCloseIn, withCloseQuietly, withCloseUnchecked, withDisableRequestCorrelation, withDisableSessionCorrelation, withEnableRequestCorrelation, withEnableSessionCorrelation, withOpen, withOpenUnchecked, withRealm, withRequestCorrelation, withSessionCorrelation
-
Methods inherited from interface org.refcodes.net.BaseLocatorAccessor.BaseLocatorMutator
setBaseLocator
-
Methods inherited from interface org.refcodes.component.Closable
close, closeIn, closeQuietly, closeUnchecked
-
Methods inherited from interface org.refcodes.component.ConnectionOpenable.ConnectionOpenBuilder
withOpenUnchecked
-
Methods inherited from interface org.refcodes.component.Destroyable.DestroyAutomaton
isDestroyable, isDestroyed
-
Methods inherited from interface org.refcodes.rest.ext.eureka.EurekaRegistry
initialize, initialize, initialize, withEurekaDataCenterType, withHomePath, withStatusPath
-
Methods inherited from interface org.refcodes.rest.ext.eureka.EurekaRestServer
initialize, initialize, initialize, initialize, withHomeRequestObserver, withStatusRequestObserver
-
Methods inherited from interface org.refcodes.rest.ext.eureka.EurekaServerDescriptorFactory
toHttpServerDescriptor, toHttpServerDescriptor
-
Methods inherited from interface org.refcodes.rest.HttpExceptionHandlerAccessor.HttpExceptionHandlerBuilder
withOnHttpException
-
Methods inherited from interface org.refcodes.rest.HttpExceptionHandlerAccessor.HttpExceptionHandlerMutator
onHttpException
-
Methods inherited from interface org.refcodes.rest.HttpRegistry
initialize, initialize, initialize, initialize, initialize, initialize, withAlias, withCidrNotation, withHost, withHttpRegistryUrl, withHttpServerDescriptor, withInstanceId, withIpAddress, withPingPath, withTrustStoreDescriptor, withVirtualHost
-
Methods inherited from interface org.refcodes.rest.HttpRegistryRestServer
initialize, withPingRequestObserver, withPort, withProtocol, withScheme
-
Methods inherited from interface org.refcodes.rest.HttpRegistryUrlAccessor.HttpRegistryUrlMutator
setHttpRegistryUrl
-
Methods inherited from interface org.refcodes.rest.HttpRestServer
open, open, open, open, open, open, open, open, open, open, open, open, open, withBaseLocator, withClose, withCloseIn, withCloseQuietly, withDisableRequestCorrelation, withDisableSessionCorrelation, withEnableRequestCorrelation, withEnableSessionCorrelation, withKeyStoreDescriptor, withMaxConnections, withOpen, withOpen, withRealm, withRequestCorrelation, withSessionCorrelation
-
Methods inherited from interface org.refcodes.net.HttpsConnectionRequestObservable
onConnectionRequest
-
Methods inherited from interface org.refcodes.rest.HttpServerDescriptorAccessor
getHttpServerDescriptor
-
Methods inherited from interface org.refcodes.rest.HttpServerDescriptorAccessor.HttpServerDescriptorMutator
setHttpServerDescriptor
-
Methods inherited from interface org.refcodes.rest.HttpServerDescriptorFactory
toHttpServerDescriptor, toHttpServerDescriptor, toHttpServerDescriptor, toHttpServerDescriptor
-
Methods inherited from interface org.refcodes.component.Initializable.InitializeAutomaton
isInitalizable
-
Methods inherited from interface org.refcodes.mixin.InstanceIdAccessor.InstanceIdMutator
setInstanceId
-
Methods inherited from interface org.refcodes.net.IpAddressAccessor.IpAddressMutator
fromCidrNotation, setIpAddress
-
Methods inherited from interface org.refcodes.security.KeyStoreDescriptorAccessor
getKeyStoreDescriptor
-
Methods inherited from interface org.refcodes.security.KeyStoreDescriptorAccessor.KeyStoreDescriptorMutator
setKeyStoreDescriptor
-
Methods inherited from interface org.refcodes.io.MaxConnectionsAccessor.MaxConnectionsMutator
setMaxConnections
-
Methods inherited from interface org.refcodes.net.MediaTypeFactoryLookup
getFactoryMediaTypes, hasMediaTypeFactory, toMediaTypeFactory
-
Methods inherited from interface org.refcodes.net.MediaTypeFactoryLookup.MutableMediaTypeFactoryLookup
addMediaTypeFactory
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.refcodes.observer.Observable
hasObserverSubscription, subscribeObserver, unsubscribeObserver
-
Methods inherited from interface org.refcodes.observer.Observers
disableObservers, enableObservers, observers
-
Methods inherited from interface org.refcodes.component.Pausable.PauseAutomaton
isPausable, isPaused
-
Methods inherited from interface org.refcodes.rest.PingRequestObserverAccessor
getPingRequestObserver
-
Methods inherited from interface org.refcodes.runtime.RequestCorrelation
disableRequestCorrelation, enableRequestCorrelation, hasRequestCorrelation, setRequestCorrelation
-
Methods inherited from interface org.refcodes.rest.RestServer
onDelete, onGet, onPost, onPut, onRequest, onRequest, onRequest, withDisableObservers, withEnableObservers, withObserversActive
-
Methods inherited from interface org.refcodes.net.SchemeAccessor.SchemeMutator
setProtocol, setScheme
-
Methods inherited from interface org.refcodes.runtime.SessionCorrelation
disableSessionCorrelation, enableSessionCorrelation, hasSessionCorrelation, setSessionCorrelation
-
Methods inherited from interface org.refcodes.component.Stoppable.StopAutomaton
isStoppable, isStopped
-
Methods inherited from interface org.refcodes.security.TrustStoreDescriptorAccessor
getTrustStoreDescriptor
-
-
-
-
Constructor Detail
-
EurekaRestServerDecorator
public EurekaRestServerDecorator(org.refcodes.rest.HttpRestServer aServer)
Decorates the givenHttpRestServer
with discovery functionality. UseAbstractHttpRegistryRestServerDecorator.initialize()
,start()
,pause()
,resume()
,stop()
anddestroy()
for publishing status updates to Eureka. UseHttpRestServer.open(org.refcodes.net.HttpServerContext)
or similar to activate your server.- Parameters:
aServer
- TheHttpRestServer
to be decorated.
-
EurekaRestServerDecorator
public EurekaRestServerDecorator(org.refcodes.rest.HttpRestServer aServer, java.util.concurrent.ExecutorService aExecutorService)
Decorates the givenHttpRestServer
with discovery functionality. UseAbstractHttpRegistryRestServerDecorator.initialize()
,start()
,pause()
,resume()
,stop()
anddestroy()
for publishing status updates to Eureka. UseHttpRestServer.open(org.refcodes.net.HttpServerContext)
or similar to activate your server.- Parameters:
aServer
- TheHttpRestServer
to be decorated.aExecutorService
- An executor service to be used when creatingThread
s.
-
-
Method Detail
-
initialize
public void initialize(EurekaServerDescriptor aServerDescriptor, org.refcodes.rest.RestRequestObserver aPingObserver, org.refcodes.rest.RestRequestObserver aStatusObserver, org.refcodes.rest.RestRequestObserver aHomeObserver, org.refcodes.net.Url aRegistryUrl, org.refcodes.security.TrustStoreDescriptor aStoreDescriptor) throws org.refcodes.component.InitializeException
Initializes theHttpRegistryRestServer
by registering it at the service registry.- Specified by:
initialize
in interfaceEurekaRestServer
- Parameters:
aServerDescriptor
- The descriptor describing the server.aPingObserver
- The health-check request observer hook.aStatusObserver
- The status-page request observer hook.aHomeObserver
- The home-page request observer hook.aRegistryUrl
- The registry server where to register.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.
-
start
public void start() throws org.refcodes.component.StartException
- Specified by:
start
in interfaceorg.refcodes.rest.HttpRegistry<EurekaServerDescriptor,EurekaRestServer>
- Specified by:
start
in interfaceorg.refcodes.rest.HttpRegistryRestServer<EurekaServerDescriptor,EurekaRestServer>
- Specified by:
start
in interfaceorg.refcodes.component.Startable
- Overrides:
start
in classorg.refcodes.rest.AbstractHttpRegistryRestServerDecorator<EurekaServerDescriptor,EurekaRestServer>
- Throws:
org.refcodes.component.StartException
-
pause
public void pause() throws org.refcodes.component.PauseException
- Specified by:
pause
in interfaceorg.refcodes.rest.HttpRegistry<EurekaServerDescriptor,EurekaRestServer>
- Specified by:
pause
in interfaceorg.refcodes.rest.HttpRegistryRestServer<EurekaServerDescriptor,EurekaRestServer>
- Specified by:
pause
in interfaceorg.refcodes.component.Pausable
- Overrides:
pause
in classorg.refcodes.rest.AbstractHttpRegistryRestServerDecorator<EurekaServerDescriptor,EurekaRestServer>
- Throws:
org.refcodes.component.PauseException
-
resume
public void resume() throws org.refcodes.component.ResumeException
- Specified by:
resume
in interfaceorg.refcodes.rest.HttpRegistry<EurekaServerDescriptor,EurekaRestServer>
- Specified by:
resume
in interfaceorg.refcodes.rest.HttpRegistryRestServer<EurekaServerDescriptor,EurekaRestServer>
- Specified by:
resume
in interfaceorg.refcodes.component.Resumable
- Overrides:
resume
in classorg.refcodes.rest.AbstractHttpRegistryRestServerDecorator<EurekaServerDescriptor,EurekaRestServer>
- Throws:
org.refcodes.component.ResumeException
-
stop
public void stop() throws org.refcodes.component.StopException
- Specified by:
stop
in interfaceorg.refcodes.rest.HttpRegistry<EurekaServerDescriptor,EurekaRestServer>
- Specified by:
stop
in interfaceorg.refcodes.rest.HttpRegistryRestServer<EurekaServerDescriptor,EurekaRestServer>
- Specified by:
stop
in interfaceorg.refcodes.component.Stoppable
- Overrides:
stop
in classorg.refcodes.rest.AbstractHttpRegistryRestServerDecorator<EurekaServerDescriptor,EurekaRestServer>
- Throws:
org.refcodes.component.StopException
-
destroy
public void destroy()
- Specified by:
destroy
in interfaceorg.refcodes.component.Destroyable
- Specified by:
destroy
in interfaceorg.refcodes.rest.HttpRegistry<EurekaServerDescriptor,EurekaRestServer>
- Specified by:
destroy
in interfaceorg.refcodes.rest.HttpRegistryRestServer<EurekaServerDescriptor,EurekaRestServer>
- Overrides:
destroy
in classorg.refcodes.rest.AbstractHttpRegistryRestServerDecorator<EurekaServerDescriptor,EurekaRestServer>
-
getHomePath
public java.lang.String getHomePath()
- Specified by:
getHomePath
in interfaceorg.refcodes.rest.HomePathAccessor
-
setHomePath
public void setHomePath(java.lang.String aHomePath)
- Specified by:
setHomePath
in interfaceorg.refcodes.rest.HomePathAccessor.HomePathMutator
-
getStatusPath
public java.lang.String getStatusPath()
- Specified by:
getStatusPath
in interfaceorg.refcodes.rest.StatusPathAccessor
-
setStatusPath
public void setStatusPath(java.lang.String aStatusPath)
- Specified by:
setStatusPath
in interfaceorg.refcodes.rest.StatusPathAccessor.StatusPathMutator
-
getConnectionStatus
public org.refcodes.component.ConnectionStatus getConnectionStatus()
- Specified by:
getConnectionStatus
in interfaceorg.refcodes.component.ConnectionStatusAccessor
-
setObserversActive
public void setObserversActive(boolean isActive)
- Specified by:
setObserversActive
in interfaceorg.refcodes.observer.Observers<EurekaServerDescriptor,EurekaRestServer>
-
isObserversActive
public boolean isObserversActive()
- Specified by:
isObserversActive
in interfaceorg.refcodes.observer.Observers<EurekaServerDescriptor,EurekaRestServer>
-
withHttpExceptionHandler
public EurekaRestServer withHttpExceptionHandler(org.refcodes.rest.HttpExceptionHandler aHttpErrorHandler)
- Specified by:
withHttpExceptionHandler
in interfaceorg.refcodes.rest.HttpExceptionHandlerAccessor.HttpExceptionHandlerBuilder<EurekaServerDescriptor>
- Specified by:
withHttpExceptionHandler
in interfaceorg.refcodes.rest.HttpRestServer
-
setHttpExceptionHandler
public void setHttpExceptionHandler(org.refcodes.rest.HttpExceptionHandler aHttpErrorHandler)
- Specified by:
setHttpExceptionHandler
in interfaceorg.refcodes.rest.HttpExceptionHandlerAccessor.HttpExceptionHandlerMutator
-
getHttpExceptionHandler
public org.refcodes.rest.HttpExceptionHandler getHttpExceptionHandler()
- Specified by:
getHttpExceptionHandler
in interfaceorg.refcodes.rest.HttpExceptionHandlerAccessor
-
withHttpExceptionHandling
public EurekaRestServer withHttpExceptionHandling(org.refcodes.rest.HttpExceptionHandling aHttpErrorHandling)
- Specified by:
withHttpExceptionHandling
in interfaceorg.refcodes.rest.HttpExceptionHandlingAccessor.HttpExceptionHandlingBuilder<EurekaServerDescriptor>
- Specified by:
withHttpExceptionHandling
in interfaceorg.refcodes.rest.HttpRestServer
-
setHttpExceptionHandling
public void setHttpExceptionHandling(org.refcodes.rest.HttpExceptionHandling aHttpErrorHandling)
- Specified by:
setHttpExceptionHandling
in interfaceorg.refcodes.rest.HttpExceptionHandlingAccessor.HttpExceptionHandlingMutator
-
getHttpExceptionHandling
public org.refcodes.rest.HttpExceptionHandling getHttpExceptionHandling()
- Specified by:
getHttpExceptionHandling
in interfaceorg.refcodes.rest.HttpExceptionHandlingAccessor
-
getEurekaDataCenterType
public EurekaDataCenterType getEurekaDataCenterType()
Retrieves the Eureka data center type from the Eureka data center type property.- Specified by:
getEurekaDataCenterType
in interfaceEurekaDataCenterTypeAccessor
- Returns:
- The Eureka data center type stored by the Eureka data center type property.
-
setEurekaDataCenterType
public void setEurekaDataCenterType(EurekaDataCenterType aDataCenterType)
Sets the Eureka data center type for the Eureka data center type property.- Specified by:
setEurekaDataCenterType
in interfaceEurekaDataCenterTypeAccessor.EurekaDataCenterTypeMutator
- Parameters:
aDataCenterType
- The Eureka data center type to be stored by the Eureka data center type property.
-
onHomeRequest
public void onHomeRequest(org.refcodes.rest.RestRequestObserver aRequestObserver)
- Specified by:
onHomeRequest
in interfaceorg.refcodes.rest.HomeRequestObserver
-
getHomeRequestObserver
public org.refcodes.rest.RestRequestObserver getHomeRequestObserver()
- Specified by:
getHomeRequestObserver
in interfaceorg.refcodes.rest.HomeRequestObserverAccessor
-
onStatusRequest
public void onStatusRequest(org.refcodes.rest.RestRequestObserver aRequestObserver)
- Specified by:
onStatusRequest
in interfaceorg.refcodes.rest.StatusRequestObserver
-
getStatusRequestObserver
public org.refcodes.rest.RestRequestObserver getStatusRequestObserver()
- Specified by:
getStatusRequestObserver
in interfaceorg.refcodes.rest.StatusRequestObserverAccessor
-
toHttpServerDescriptor
public EurekaServerDescriptor toHttpServerDescriptor(java.lang.String aAlias, java.lang.String aInstanceId, org.refcodes.data.Scheme aScheme, java.lang.String aHost, java.lang.String aVirtualHost, int[] aIpAddress, int aPort, java.lang.String aPingPath, java.lang.String aStatusPath, java.lang.String aHomePath, EurekaDataCenterType aDataCenterType)
Prepares theHttpServerDescriptor
by creating it from this instance's state and the provided arguments. The provided arguments can modify theinstance's state. TheHttpServerDescriptor
as finally used is returned. You may modify this context and use it after modification to initialize the server viaHttpRegistry.initialize(HttpServerDescriptor, Url)
orHttpRegistry.initialize(HttpServerDescriptor, Url, TrustStoreDescriptor)
.- Specified by:
toHttpServerDescriptor
in interfaceEurekaServerDescriptorFactory
- Parameters:
aAlias
- The name ("alias") which identifies the server in the registry.aInstanceId
- The ID for the instance when being registered at the service registry. If omitted, then the host name is used.aScheme
- TheScheme
to 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. Make sure, you do notaPingPath
- The path to use as health-check end-point by this server.aStatusPath
- The path to use as status-page end-point by this server.aHomePath
- The path to use as home-page end-point by this server.aDataCenterType
- The data center type to be used.- Returns:
- The
HttpServerDescriptor
as would be used when initializing this instance viaHttpRegistry.initialize()
-
doRegister
protected void doRegister(EurekaServiceStatus aServiceStatus) throws org.refcodes.net.HttpStatusException, org.refcodes.component.OpenException
Registers the given service at Eureka.- Parameters:
aServiceStatus
- TheEurekaServiceStatus
to be set.- Throws:
org.refcodes.net.HttpStatusException
- Thrown in case a HTTP response was of an erroneous status.torg.refcodes.component.OpenException
- Thrown in case opening or accessing an open line (connection, junction, link) caused problems.
-
doStatusUpdate
protected void doStatusUpdate(EurekaServiceStatus aServiceStatus) throws org.refcodes.component.OpenException, java.net.UnknownHostException, org.refcodes.net.HttpStatusException
Does a Eureka status update for the given service.- Parameters:
aServiceStatus
- TheEurekaServiceStatus
to be set.- Throws:
org.refcodes.net.HttpStatusException
- Thrown in case a HTTP response was of an erroneous status.torg.refcodes.component.OpenException
- Thrown in case opening or accessing an open line (connection, junction, link) caused problems.java.net.UnknownHostException
- Thrown in case the targeted host is unknown.
-
doDeregister
protected void doDeregister() throws org.refcodes.component.OpenException, org.refcodes.net.HttpStatusException
Unregisters the given service at Eureka.- Throws:
org.refcodes.net.HttpStatusException
- Thrown in case a HTTP response was of an erroneous status.torg.refcodes.component.OpenException
- Thrown in case opening or accessing an open line (connection, junction, link) caused problems.
-
toHttpRegistryUrl
protected org.refcodes.net.Url toHttpRegistryUrl(org.refcodes.net.Url aRegistryUrl)
Resolves the property from the provided value and this instance and sets the property in case the provided value is not null.- Overrides:
toHttpRegistryUrl
in classorg.refcodes.rest.AbstractHttpRegistryRestServerDecorator<EurekaServerDescriptor,EurekaRestServer>
- Parameters:
aRegistryUrl
- The value to be used when not null.- Returns:
- The value when not null, else the value of the provided property.
-
toHomeObserver
protected org.refcodes.rest.RestRequestObserver toHomeObserver(org.refcodes.rest.RestRequestObserver aHomeRequestObserver)
Resolves the property from the provided value and this instance and sets the property in case the provided value is not null.- Parameters:
aHomeRequestObserver
- The value to be used when not null.- Returns:
- The value when not null, else the value of the provided property.
-
toStatusObserver
protected org.refcodes.rest.RestRequestObserver toStatusObserver(org.refcodes.rest.RestRequestObserver aStatusRequestObserver)
Resolves the property from the provided value and this instance and sets the property in case the provided value is not null.- Parameters:
aStatusRequestObserver
- The value to be used when not null.- Returns:
- The value when not null, else the value of the provided property.
-
-