You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@openwhisk.apache.org by GitBox <gi...@apache.org> on 2019/03/15 01:55:15 UTC

[GitHub] [incubator-openwhisk] selfxp opened a new issue #4347: SplunkLogStore failing to return empty Splunk messages

selfxp opened a new issue #4347: SplunkLogStore failing to return empty Splunk messages
URL: https://github.com/apache/incubator-openwhisk/issues/4347
 
 
   There is currently an issue with SplunkLogStore that assumes that all JSON objects received from Splunk API should always contain these fields: `log_timestamp`, `log_stream` and `log_message`. 
   
   We have noticed that this is not the case. Splunk has an internal setting for truncating messages that contain a log line larger in size than a configurable value. By default this value is: `10KB` as per documentation: http://dev.splunk.com/view/SP-CAAAE3A#Gettingdatain-Formatlogdataefficiently .
   Messages that exceed this size won't be indexed and won't be able to be retrieved using the Splunk API. The JSON object for that particular message will simply be returning empty: `{}`. 
   
   In the current implementation of `SplunkLogStore` all messages will fail to display if only one of them is returning empty. 
   
   Executing the following `wsk` command
   ```
   wsk activation logs $activation_id
   ```
   will return the following error message: 
   ```
   error: Unable to get logs for activation '$activation_id': key not found: log_message (code ...)
   ```
   There are some solutions on how to fix this on the Splunk side: Increase the `TRUNCATION` property value or configure some `LINE_BREAKER` strategies, but in case one of these messages has been sent to Splunk, it will be impossible to retrieve any logs for that activation. 
   
   A fix needs to be added to `SplunkLogStore` that makes sure that `NoSuchElementException` is being catched,  and all other log messages are still being returned. 
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services