Package io.stargate.sdk
Class Service
java.lang.Object
io.stargate.sdk.Service
- Direct Known Subclasses:
ServiceHttp
SuperClass for ApiEndpoint.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets endpointGets healthCheckEndpointgetId()Gets idabstract booleanisAlive()Invoke heath endpoint.voidsetEndpoint(String endpoint) Set value for endpointvoidsetHealthCheckEndpoint(String healthCheckEndpoint) Set value for healthCheckEndpointvoidSet value for id
-
Field Details
-
id
Instance id. -
endpoint
Service Endpoint. -
healthCheckEndpoint
Health Check.
-
-
Constructor Details
-
Service
Constructor.- Parameters:
id- identifierendpoint- endpointhealthCheckEndpoint- health-check
-
-
Method Details
-
isAlive
public abstract boolean isAlive()Invoke heath endpoint.- Returns:
- is the service is up.
-
getId
Gets id- Returns:
- value of id
-
setId
Set value for id- Parameters:
id- new value for id
-
getEndpoint
Gets endpoint- Returns:
- value of endpoint
-
setEndpoint
Set value for endpoint- Parameters:
endpoint- new value for endpoint
-
getHealthCheckEndpoint
Gets healthCheckEndpoint- Returns:
- value of healthCheckEndpoint
-
setHealthCheckEndpoint
Set value for healthCheckEndpoint- Parameters:
healthCheckEndpoint- new value for healthCheckEndpoint
-