Package org.lsst.ccs.services
Class InfluxDbClientService
java.lang.Object
org.lsst.ccs.services.InfluxDbClientService
- All Implemented Interfaces:
ServiceLifecycle,AgentService
An AgentService to be used by Agents that need to interact with the Rest
Server on the buses.
Connections can be established by either creating a custom connection to
a known host:port combination or by listening to the buses for available rest services.
- Author:
- The LSST CCS Team
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.influxdb.dto.BatchPointsGet the name of this service.booleanvoidpreInit()voidvoidpreStart()Called from the enclosingSubsystemwhenorg.lsst.ccs.Subsystem#start()has been called.voidsetEnabled(boolean enabled) booleanstartForAgent(AgentInfo agentInfo) This method is invoked after an agent service is created to see if this service is to be started for the tiven Agent.voidwrite(org.influxdb.dto.BatchPoints points) voidwrite(org.influxdb.dto.Point point) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.lsst.ccs.ServiceLifecycle
afterBuild, afterInit, afterStart, preBuild
-
Constructor Details
-
InfluxDbClientService
public InfluxDbClientService()
-
-
Method Details
-
getAgentServiceName
Description copied from interface:AgentServiceGet the name of this service. This name will be used to add the given service to the lookup tree.- Specified by:
getAgentServiceNamein interfaceAgentService- Returns:
- the AgentService name.
-
startForAgent
Description copied from interface:AgentServiceThis method is invoked after an agent service is created to see if this service is to be started for the tiven Agent.- Specified by:
startForAgentin interfaceAgentService- Returns:
- true if the service is to be added to the given agent.
-
setEnabled
-
isEnabled
public boolean isEnabled() -
preStart
public void preStart()Description copied from interface:ServiceLifecycleCalled from the enclosingSubsystemwhenorg.lsst.ccs.Subsystem#start()has been called.The preceding lifecycle step is
HasLifecycle.postInit()The following lifecycle step is
HasLifecycle.start()At the time it is called :-
the
PhaseStateisINITIALIZINGconnection with the messaging layer is effective, the enclosing subsystem has startedStatusHeartBeatpublication- Specified by:
preStartin interfaceServiceLifecycle
-
preInit
public void preInit()- Specified by:
preInitin interfaceServiceLifecycle
-
preShutdown
public void preShutdown()- Specified by:
preShutdownin interfaceServiceLifecycle
-
write
public void write(org.influxdb.dto.Point point) -
write
public void write(org.influxdb.dto.BatchPoints points) -
getGlobalTags
-
createBatchPoints
public org.influxdb.dto.BatchPoints createBatchPoints()
-