@Test
public void testFindByService() {

  List<AlertDefinitionEntity> definitions = dao.findByService(clusterId,
      "HDFS");
  assertNotNull(definitions);
  assertEquals(10, definitions.size());
  definitions = dao.findByService(clusterId, "YARN");
  assertNotNull(definitions);
  assertEquals(0, definitions.size());
}