[ https://issues.apache.org/jira/browse/EAGLE-95?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15128332#comment-15128332 ]
ASF GitHub Bot commented on EAGLE-95: ------------------------------------- Github user RalphSu commented on a diff in the pull request: https://github.com/apache/incubator-eagle/pull/71#discussion_r51575914 --- Diff: eagle-core/eagle-policy/eagle-policy-base/src/main/java/org/apache/eagle/policy/dao/AlertDefinitionDAOImpl.java --- @@ -83,4 +85,27 @@ public AlertDefinitionDAOImpl(EagleServiceConnector connector){ } return map; } + + @Override + public void updatePolicyDetails(AlertDefinitionAPIEntity entity, boolean markdownEnabled, String markdownReason) { + IEagleServiceClient client = new EagleServiceClientImpl(connector); + + List<AlertDefinitionAPIEntity> entityList = new ArrayList<>(); + entity.setMarkdownReason(null != markdownReason ? markdownReason : ""); + entity.setMarkdownEnabled(markdownEnabled); + entityList.add(entity); + + try { + client.create(entityList, Constants.ALERT_DEFINITION_SERVICE_ENDPOINT_NAME); + } catch (IOException | EagleServiceClientException exception) { + LOG.error("Exception in updating markdown for policy in HBase", exception.getMessage()); --- End diff -- Please make sure not only the message is logged, but also the stack, you might want to pass the exception object to LOG here. > DAM HDFS topology fails to start, if there is invalid policy. > ------------------------------------------------------------- > > Key: EAGLE-95 > URL: https://issues.apache.org/jira/browse/EAGLE-95 > Project: Eagle > Issue Type: Bug > Reporter: hemanth dendukuri > Assignee: Senthilkumar > Priority: Critical > > Step 1: Create a invalid policy (from hdfsAuditLogEventStream[(cmd == 'open') > and (str:contains(src,'/tmp/p')==true)] select * insert into outputStream;) > Step 2 : Deploy Dam HDFS topology. > Actual : The HDFS topology could not start because of the invalid policy. > 2015-12-16 23:51:17 b.s.d.executor [INFO] Shutting down executor > AlertEntityDeduplicationExecutor_9:[2 2] 2015-12-16 23:51:17 b.s.util [INFO] > Async loop interrupted! > Expected: Topology should start ignoring the invalid policy. -- This message was sent by Atlassian JIRA (v6.3.4#6332)