drill-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Matta <cma...@mapr.com>
Subject Validate your JSON files
Date Mon, 24 Nov 2014 22:07:31 GMT
I’ve been running across errors in Drill when a JSON record is invalid. To
reduce the number of these errors, I wrote this small, simple application
that will open a specified file, check if each line is a valid JSON record,
and error if it’s not:

https://github.com/cjmatta/jsonr

Usage:

[cmatta@ip-172-16-1-173 jsonar]$ ./jsonar -f ../tweets/2014/11/24/21/tweets.json
Checking for valid JSON in ../tweets/2014/11/24/21/tweets.json
CWARNING:root:JSON load error on line 16640 of
../tweets/2014/11/24/21/tweets.json
WARNING:root:JSON load error on line 16641 of
../tweets/2014/11/24/21/tweets.json
WARNING:root:JSON load error on line 16642 of
../tweets/2014/11/24/21/tweets.json
Checking line 17000
Done.

Please check it out, use it, contribute back if there’s something broken or
missing.

Chris Matta
cmatta@mapr.com
215-701-3146
​

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message