[ 
https://issues.apache.org/jira/browse/METRON-1289?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16253975#comment-16253975
 ] 

ASF GitHub Bot commented on METRON-1289:
----------------------------------------

Github user justinleet commented on the issue:

    https://github.com/apache/metron/pull/824
  
    ## Patch neither alert and status
    Create a metaalerts and get the GUID for the following steps.
    
    ### Patch in new field
    ```
    /api/v1/update/patch
    
    curl -X PATCH --header 'Content-Type: application/json' --header 'Accept: 
*/*' -d '{
      "guid": "00eae5ba-6137-4601-ae3a-fbf0003e58e6",
      "index": "metaalert_index",
      "patch": [
        {
          "op": "add"
            , "path": "/name"
            , "value": "My new meta alert name"
        }
      ],
      "sensorType": "metaalert"
    }' 'http://node1:8082/api/v1/update/patch'
    ```
    
    ### Retrieve the meta alert and ensure it contains the new 'name' field
    ```
    /api/v1/search/findOne
    
    curl -X POST --header 'Content-Type: application/json' --header 'Accept: 
application/json' -d '{
      "guid": "00eae5ba-6137-4601-ae3a-fbf0003e58e6",
      "index": "metaalert_index",
      "sensorType": "metaalert"
    }' 'http://node1:8082/api/v1/search/findOne'
    ```



> Alert fields are lost when a MetaAlert is created
> -------------------------------------------------
>
>                 Key: METRON-1289
>                 URL: https://issues.apache.org/jira/browse/METRON-1289
>             Project: Metron
>          Issue Type: Bug
>            Reporter: Ryan Merriman
>            Assignee: Ryan Merriman
>
> When a MetaAlert is created, the included results are being updated 
> incorrectly with only the "metaalert" field.  This causes subsequent findOne 
> operations to only return the "metaalert field for that alert.  All fields 
> should continue to be present.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to