Class DetectorRequestDTO
- java.lang.Object
-
- org.opennms.netmgt.provision.detector.client.rpc.DetectorRequestDTO
-
- All Implemented Interfaces:
RpcRequest
,DetectRequest
,PreDetectCallback
public class DetectorRequestDTO extends Object implements DetectRequest, RpcRequest
-
-
Field Summary
-
Fields inherited from interface org.opennms.core.rpc.api.RpcRequest
TAG_CLASS_NAME, TAG_DESCRIPTION, TAG_IP_ADDRESS, TAG_NODE_ID, TAG_NODE_LABEL
-
-
Constructor Summary
Constructors Constructor Description DetectorRequestDTO()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addDetectorAttribute(String key, String value)
void
addDetectorAttributes(Map<String,String> attributes)
void
addRuntimeAttribute(String key, String value)
void
addRuntimeAttributes(Map<String,String> attributes)
void
addTracingInfo(String key, String value)
boolean
equals(Object obj)
InetAddress
getAddress()
Map<String,String>
getAttributeMap()
String
getClassName()
List<DetectorAttributeDTO>
getDetectorAttributes()
String
getLocation()
Used to route the request to the appropriate location.Map<String,String>
getRuntimeAttributes()
io.opentracing.Span
getSpan()
String
getSystemId()
Used to route the request to a particular system at the given location.Long
getTimeToLiveMs()
When using JMS, the request will fail if no response was received in this many milliseconds.Map<String,String>
getTracingInfo()
RPC clients expose tracing info as tags there by giving more context to each RPC trace.int
hashCode()
void
preDetect()
void
setAddress(InetAddress address)
void
setClassName(String className)
void
setDetectorAttributes(List<DetectorAttributeDTO> attributes)
void
setLocation(String location)
void
setPreDetectCallback(PreDetectCallback preDetectCallback)
void
setRuntimeAttributes(List<DetectorAttributeDTO> attributes)
void
setSpan(io.opentracing.Span span)
void
setSystemId(String systemId)
void
setTimeToLiveMs(Long timeToLive)
-
-
-
Method Detail
-
getLocation
public String getLocation()
Description copied from interface:RpcRequest
Used to route the request to the appropriate location.- Specified by:
getLocation
in interfaceRpcRequest
-
setLocation
public void setLocation(String location)
-
setSystemId
public void setSystemId(String systemId)
-
getSystemId
public String getSystemId()
Description copied from interface:RpcRequest
Used to route the request to a particular system at the given location.- Specified by:
getSystemId
in interfaceRpcRequest
-
getDetectorAttributes
public List<DetectorAttributeDTO> getDetectorAttributes()
-
setDetectorAttributes
public void setDetectorAttributes(List<DetectorAttributeDTO> attributes)
-
setRuntimeAttributes
public void setRuntimeAttributes(List<DetectorAttributeDTO> attributes)
-
getRuntimeAttributes
public Map<String,String> getRuntimeAttributes()
- Specified by:
getRuntimeAttributes
in interfaceDetectRequest
- Returns:
- additional attributes stored outside of the detector's configuration that may be required when running the detector.
-
getClassName
public String getClassName()
-
setClassName
public void setClassName(String className)
-
getAddress
public InetAddress getAddress()
- Specified by:
getAddress
in interfaceDetectRequest
- Returns:
- the address of the host against with the detector should be invoked.
-
setAddress
public void setAddress(InetAddress address)
-
getTimeToLiveMs
public Long getTimeToLiveMs()
Description copied from interface:RpcRequest
When using JMS, the request will fail if no response was received in this many milliseconds.- Specified by:
getTimeToLiveMs
in interfaceRpcRequest
-
setTimeToLiveMs
public void setTimeToLiveMs(Long timeToLive)
-
getTracingInfo
public Map<String,String> getTracingInfo()
Description copied from interface:RpcRequest
RPC clients expose tracing info as tags there by giving more context to each RPC trace. Implementations should add tags defined above if they are available.- Specified by:
getTracingInfo
in interfaceRpcRequest
-
getSpan
public io.opentracing.Span getSpan()
- Specified by:
getSpan
in interfaceRpcRequest
-
setSpan
public void setSpan(io.opentracing.Span span)
-
setPreDetectCallback
public void setPreDetectCallback(PreDetectCallback preDetectCallback)
-
preDetect
public void preDetect()
- Specified by:
preDetect
in interfacePreDetectCallback
-
-