public class OutageDaoHibernate extends AbstractDaoHibernate<OnmsOutage,Integer> implements OutageDao
m_criteriaConverter
Constructor and Description |
---|
OutageDaoHibernate()
Constructor for OutageDaoHibernate.
|
Modifier and Type | Method and Description |
---|---|
int |
countOutagesByNode()
Get the number of nodes with outages.
|
Integer |
currentOutageCount()
currentOutageCount
|
OnmsOutage |
currentOutageForService(OnmsMonitoredService service)
Return the current open outage for the service or if the service
is up and has no open outage, return null.
|
Collection<OnmsOutage> |
currentOutages()
currentOutages
|
Collection<OnmsOutage> |
findAll(Integer offset,
Integer limit)
findAll
|
List<HeatMapElement> |
getHeatMapItemsForEntity(String entityNameColumn,
String entityIdColumn,
String restrictionColumn,
String restrictionValue,
String... groupByColumns)
Retrieves heatmap elements for a given combination of database columns.
|
List<OutageSummary> |
getNodeOutageSummaries(int rows)
Get the list of current outages, one per node.
|
Collection<OnmsOutage> |
matchingCurrentOutages(ServiceSelector selector)
Finds all current (unresolved) outages that match the given service selector.
|
Collection<CurrentOutageDetails> |
newestCurrentOutages(List<String> serviceNames)
Finds the latest (unresolved) outages that match the given services.
|
buildHibernateCallback, bulkDelete, clear, countAll, countMatching, countMatching, delete, delete, deleteAll, find, find, findAll, findMatching, findMatching, findObjects, findUnique, flush, get, initDao, initialize, load, lock, merge, queryInt, queryInt, save, saveOrUpdate, update
checkDaoConfig, convertHibernateAccessException, createHibernateTemplate, getHibernateTemplate, getSession, getSession, getSessionFactory, releaseSession, setHibernateTemplate, setSessionFactory
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
countMatching, findMatching
clear, countAll, countMatching, delete, delete, findAll, findMatching, flush, get, initialize, load, lock, save, saveOrUpdate, update
public OutageDaoHibernate()
Constructor for OutageDaoHibernate.
public Integer currentOutageCount()
currentOutageCount
currentOutageCount
in interface OutageDao
Integer
object.public Collection<OnmsOutage> currentOutages()
currentOutages
currentOutages
in interface OutageDao
Collection
object.public OnmsOutage currentOutageForService(OnmsMonitoredService service)
OutageDao
currentOutageForService
in interface OutageDao
public Collection<OnmsOutage> findAll(Integer offset, Integer limit)
findAll
findAll
in interface OutageDao
offset
- a Integer
object.limit
- a Integer
object.Collection
object.public Collection<CurrentOutageDetails> newestCurrentOutages(List<String> serviceNames)
newestCurrentOutages
in interface OutageDao
serviceNames
- a list of servicesCollection
of outagespublic Collection<OnmsOutage> matchingCurrentOutages(ServiceSelector selector)
matchingCurrentOutages
in interface OutageDao
selector
- a service selector (filter + service list)Collection
of outagespublic int countOutagesByNode()
countOutagesByNode
in interface OutageDao
public List<OutageSummary> getNodeOutageSummaries(int rows)
getNodeOutageSummaries
in interface OutageDao
rows
- The maximum number of outages to return.public List<HeatMapElement> getHeatMapItemsForEntity(String entityNameColumn, String entityIdColumn, String restrictionColumn, String restrictionValue, String... groupByColumns)
OutageDao
getHeatMapItemsForEntity
in interface OutageDao
entityNameColumn
- the entity's name columnentityIdColumn
- the entity's id columnrestrictionColumn
- a column used for a restriction of the resultsrestrictionValue
- the value that must match against the restrictionColumngroupByColumns
- columns used for the SQL group-by clauseCopyright © 2020. All rights reserved.