<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: JSON input not splitting up in single line in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/JSON-input-not-splitting-up-in-single-line/m-p/465847#M80286</link>
    <description>&lt;P&gt;Its intermittent issue. The data is different in each payload. Can it be done while indexing rather than searching. Please guide.&lt;/P&gt;</description>
    <pubDate>Sat, 14 Dec 2019 03:06:35 GMT</pubDate>
    <dc:creator>rishma</dc:creator>
    <dc:date>2019-12-14T03:06:35Z</dc:date>
    <item>
      <title>JSON input not splitting up in single line</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/JSON-input-not-splitting-up-in-single-line/m-p/465845#M80284</link>
      <description>&lt;P&gt;I am using API to fetch the JSON logs and sending JSON output to Splunk. Props.conf is on the search head. &lt;/P&gt;

&lt;P&gt;I am seeing the intermittent issues of not splitting the JSON logs even though I am sending one by one JSON objects via scripting. &lt;/P&gt;

&lt;P&gt;Json payload :&lt;/P&gt;

&lt;P&gt;{"test": "emailid", "remote": "13.17.14.2", "guide": "05773-56-C2-E9", "test1": "testing", "date": "2019-12-13T19:05:03.836+00:00", "sessionID": "abc1"}&lt;BR /&gt;
{"remote": "13.7.4.28", "guide": "05773-56-C2-E9", "test1": "testing", "date": "2019-12-13T19:05:03.836+00:00", "sessionID": "abc1"}&lt;/P&gt;

&lt;P&gt;Props.conf is :&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;INDEXED_EXTRACTIONS = JSON
BREAK_ONLY_BEFORE_DATE=false
BREAK_ONLY_BEFORE=(\{\"|\"\})
MUST_BREAK_AFTER=\"\}
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Please guide. &lt;/P&gt;

&lt;P&gt;I tried including  &lt;CODE&gt;SHOULD_LINEMERGE        = false&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;But it didnt work. &lt;/P&gt;</description>
      <pubDate>Fri, 13 Dec 2019 18:09:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/JSON-input-not-splitting-up-in-single-line/m-p/465845#M80284</guid>
      <dc:creator>rishma</dc:creator>
      <dc:date>2019-12-13T18:09:45Z</dc:date>
    </item>
    <item>
      <title>Re: JSON input not splitting up in single line</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/JSON-input-not-splitting-up-in-single-line/m-p/465846#M80285</link>
      <description>&lt;PRE&gt;&lt;CODE&gt;| makeresults 
| eval _raw= "{\"test\": \"emailid\" , \"remote\": \"13.17.14.2\", \"guide\": \"05773-56-C2-E9\", \"test1\": \"testing\", \"date\": \"2019-12-13T19:05:03.836+00:00\", \"sessionID\": \"abc1\"}" 
| appendpipe 
    [| eval _raw="{\"remote\": \"13.7.4.28\", \"guide\": \"05773-56-C2-E9\", \"test1\": \"testing\", \"date\": \"2019-12-13T19:05:03.836+00:00\", \"sessionID\": \"abc1\"}" ] 
| eval _time=strptime(spath(_raw,"date"),"%Y-%m-%dT%H:%M:%S.%Q%:z")
| spath
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;If it is a search, it can be extracted correctly.&lt;/P&gt;

&lt;P&gt;&lt;A href="https://answers.splunk.com/answers/556279/why-would-indexed-extractionsjson-in-propsconf-be.html"&gt;why-would-indexed-extractionsjson-in-propsconf&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;How about using this as a reference?&lt;/P&gt;</description>
      <pubDate>Fri, 13 Dec 2019 23:25:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/JSON-input-not-splitting-up-in-single-line/m-p/465846#M80285</guid>
      <dc:creator>to4kawa</dc:creator>
      <dc:date>2019-12-13T23:25:15Z</dc:date>
    </item>
    <item>
      <title>Re: JSON input not splitting up in single line</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/JSON-input-not-splitting-up-in-single-line/m-p/465847#M80286</link>
      <description>&lt;P&gt;Its intermittent issue. The data is different in each payload. Can it be done while indexing rather than searching. Please guide.&lt;/P&gt;</description>
      <pubDate>Sat, 14 Dec 2019 03:06:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/JSON-input-not-splitting-up-in-single-line/m-p/465847#M80286</guid>
      <dc:creator>rishma</dc:creator>
      <dc:date>2019-12-14T03:06:35Z</dc:date>
    </item>
    <item>
      <title>Re: JSON input not splitting up in single line</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/JSON-input-not-splitting-up-in-single-line/m-p/465848#M80287</link>
      <description>&lt;P&gt;Sorry, I don’t know how.&lt;/P&gt;</description>
      <pubDate>Sat, 14 Dec 2019 04:06:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/JSON-input-not-splitting-up-in-single-line/m-p/465848#M80287</guid>
      <dc:creator>to4kawa</dc:creator>
      <dc:date>2019-12-14T04:06:01Z</dc:date>
    </item>
    <item>
      <title>Re: JSON input not splitting up in single line</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/JSON-input-not-splitting-up-in-single-line/m-p/465849#M80288</link>
      <description>&lt;P&gt;Never use the &lt;CODE&gt;BREAK_*&lt;/CODE&gt; settings; always do it like this (these are the only breaking settings required):&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;SHOULD_LINEMERGE = false
LINE_BREAKER = \"\}(\s*[\r\n]+\s*)(?:\{\")|(?:\"\})
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 14 Dec 2019 18:18:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/JSON-input-not-splitting-up-in-single-line/m-p/465849#M80288</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2019-12-14T18:18:49Z</dc:date>
    </item>
  </channel>
</rss>

