SaffronAnalyst - net.sf.json.JSONException...JSONObject text must begin with '{'...

Jamie Singer's Avatar

Jamie Singer

09 Feb, 2011 01:31 PM via web

After ingesting XML via REST interface and using Analyst to query data yields...

A JSONObject text must begin with '{' at character 1 of Failed to retrieve resource for ptorest~120|1. Please check the resource ref.

net.sf.json.util.JSONTokener.syntaxError(JSONTokener.java:527)
net.sf.json.JSONObject.fromJSONTokener(JSONObject.java:1112)
net.sf.json.JSONObject.
fromString(JSONObject.java:1337)
net.sf.json.JSONObject.fromObject(JSONObject.java:187)
net.sf.json.JSONObject.fromObject(JSONObject.java:156)
com.saffrontech.analyst.model.Resource.buildResourceFromJSON(Resource.java:762)...

  1. 2 Posted by Jamie Singer on 09 Feb, 2011 01:32 PM

    Jamie Singer's Avatar

    Ingest with persistence (for Ingest.java use: -p true), and the analyst problem goes away.

  2. 3 Posted by Jared Peterson on 09 Feb, 2011 02:24 PM

    Jared Peterson's Avatar

    Jamie,

    Thanks for logging this. As you've figured out the -p flag is required if you're going to be using Analyst (or have a need to re-fetch the resources).

    I think that we need to change the defaults on Ingest.java so that the persistence flag is on by default.

    Thanks,
    Jared

  3. Jamie Singer closed this discussion on 02 Jun, 2011 03:11 PM.

Comments are currently closed for this discussion. You can start a new one.