Package org.opennms.netmgt.poller
Class QueryManagerDaoImpl
- java.lang.Object
-
- org.opennms.netmgt.poller.QueryManagerDaoImpl
-
- All Implemented Interfaces:
QueryManager
public class QueryManagerDaoImpl extends Object implements QueryManager
QueryManagerDaoImpl class.
- Author:
- brozow
-
-
Constructor Summary
Constructors Constructor Description QueryManagerDaoImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcloseOutagesForInterface(Date closeDate, int eventId, int nodeId, String ipAddr)closeOutagesForInterfacevoidcloseOutagesForNode(Date closeDate, int eventId, int nodeId)closeOutagesForNodevoidcloseOutagesForService(Date closeDate, int eventId, int nodeId, String ipAddr, String serviceName)closeOutagesForServicevoidcloseOutagesForUnmanagedServices()StringgetNodeLabel(int nodeId)getNodeLabelStringgetNodeLocation(int nodeId)List<String[]>getNodeServices(int nodeId)IntegeropenOutagePendingLostEventId(int nodeId, String ipAddr, String svcName, Date lostTime)Creates a new outage for the given service without setting the lost event id.IntegerresolveOutagePendingRegainEventId(int nodeId, String ipAddr, String svcName, Date regainedTime)Marks the outage for the given service as resolved with the given time and returns the id of this outage.voidupdateLastGoodOrFail(int nodeId, InetAddress ipAddr, String serviceName, PollStatus status)voidupdateOpenOutageWithEventId(int outageId, int lostEventId)Set or updates the lost event id on the specified outage.voidupdateResolvedOutageWithEventId(int outageId, int regainedEventId)Set or updates the regained event id on the specified outage.voidupdateServiceStatus(int nodeId, String ipAddr, String serviceName, String status)
-
-
-
Method Detail
-
getNodeLabel
public String getNodeLabel(int nodeId)
getNodeLabel
- Specified by:
getNodeLabelin interfaceQueryManager- Parameters:
nodeId- a int.- Returns:
- a
Stringobject.
-
getNodeLocation
public String getNodeLocation(int nodeId)
- Specified by:
getNodeLocationin interfaceQueryManager
-
openOutagePendingLostEventId
public Integer openOutagePendingLostEventId(int nodeId, String ipAddr, String svcName, Date lostTime)
Creates a new outage for the given service without setting the lost event id.- Specified by:
openOutagePendingLostEventIdin interfaceQueryManager
-
updateOpenOutageWithEventId
public void updateOpenOutageWithEventId(int outageId, int lostEventId)Set or updates the lost event id on the specified outage.- Specified by:
updateOpenOutageWithEventIdin interfaceQueryManager
-
resolveOutagePendingRegainEventId
public Integer resolveOutagePendingRegainEventId(int nodeId, String ipAddr, String svcName, Date regainedTime)
Marks the outage for the given service as resolved with the given time and returns the id of this outage. If no outages are currently open, then no action is take and the function returns null.- Specified by:
resolveOutagePendingRegainEventIdin interfaceQueryManager
-
updateResolvedOutageWithEventId
public void updateResolvedOutageWithEventId(int outageId, int regainedEventId)Set or updates the regained event id on the specified outage.- Specified by:
updateResolvedOutageWithEventIdin interfaceQueryManager
-
getNodeServices
public List<String[]> getNodeServices(int nodeId)
- Specified by:
getNodeServicesin interfaceQueryManager- Returns:
-
closeOutagesForUnmanagedServices
public void closeOutagesForUnmanagedServices()
- Specified by:
closeOutagesForUnmanagedServicesin interfaceQueryManager
-
closeOutagesForNode
public void closeOutagesForNode(Date closeDate, int eventId, int nodeId)
closeOutagesForNode
- Specified by:
closeOutagesForNodein interfaceQueryManager- Parameters:
closeDate- aDateobject.eventId- a int.nodeId- a int.
-
closeOutagesForInterface
public void closeOutagesForInterface(Date closeDate, int eventId, int nodeId, String ipAddr)
closeOutagesForInterface
- Specified by:
closeOutagesForInterfacein interfaceQueryManager- Parameters:
closeDate- aDateobject.eventId- a int.nodeId- a int.ipAddr- aStringobject.
-
closeOutagesForService
public void closeOutagesForService(Date closeDate, int eventId, int nodeId, String ipAddr, String serviceName)
closeOutagesForService
- Specified by:
closeOutagesForServicein interfaceQueryManager- Parameters:
closeDate- aDateobject.eventId- a int.nodeId- a int.ipAddr- aStringobject.serviceName- aStringobject.
-
updateServiceStatus
public void updateServiceStatus(int nodeId, String ipAddr, String serviceName, String status)- Specified by:
updateServiceStatusin interfaceQueryManager
-
updateLastGoodOrFail
public void updateLastGoodOrFail(int nodeId, InetAddress ipAddr, String serviceName, PollStatus status)- Specified by:
updateLastGoodOrFailin interfaceQueryManager
-
-