cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jonathan Ellis <jbel...@gmail.com>
Subject Re: sstabletojson
Date Tue, 12 Jul 2011 21:52:47 GMT
You can upgrade to 0.8.1 to fix this. :)

On Tue, Jul 12, 2011 at 1:03 PM, Stephen Pope <Stephen.Pope@quest.com> wrote:
>  Hey there. I'm trying to convert one of my sstables to json, but it doesn't appear
to be escaping quotes. As a result, I've got a line in my resulting json like this:
>
> "3230303930373139313734303236efbfbf3331313733": [["6d6573736167655f6964", ""<66AA9165386616028BD3FECF893BBAC204347F3BAF@CONFLICT,6.HUSHEDFIRE.COM>"",
634447747524175316]],
>
>  Attempting to convert this json back into an sstable results in:
>
> C:\cassandra\apache-cassandra-0.8.0\bin>json2sstable.bat -K BIM -c TransactionLogs
json.dat out.db
>
> org.codehaus.jackson.JsonParseException: Unexpected character ('<' (code 60)): w
> as expecting comma to separate ARRAY entries
>  at [Source: json.dat; line: 31175, column: 299]
>        at org.codehaus.jackson.JsonParser._constructError(JsonParser.java:929)
>        at org.codehaus.jackson.impl.JsonParserBase._reportError(JsonParserBase.
> java:632)
>        at org.codehaus.jackson.impl.JsonParserBase._reportUnexpectedChar(JsonPa
> rserBase.java:565)
>        at org.codehaus.jackson.impl.Utf8StreamParser.nextToken(Utf8StreamParser
> .java:128)
>        at org.codehaus.jackson.map.deser.UntypedObjectDeserializer.mapArray(Unt
> ypedObjectDeserializer.java:81)
>        at org.codehaus.jackson.map.deser.UntypedObjectDeserializer.deserialize(
> UntypedObjectDeserializer.java:62)
>        at org.codehaus.jackson.map.deser.UntypedObjectDeserializer.mapArray(Unt
> ypedObjectDeserializer.java:82)
>        at org.codehaus.jackson.map.deser.UntypedObjectDeserializer.deserialize(
> UntypedObjectDeserializer.java:62)
>        at org.codehaus.jackson.map.deser.MapDeserializer._readAndBind(MapDeseri
> alizer.java:197)
>        at org.codehaus.jackson.map.deser.MapDeserializer.deserialize(MapDeseria
> lizer.java:145)
>        at org.codehaus.jackson.map.deser.MapDeserializer.deserialize(MapDeseria
> lizer.java:23)
>        at org.codehaus.jackson.map.ObjectMapper._readValue(ObjectMapper.java:12
> 61)
>        at org.codehaus.jackson.map.ObjectMapper.readValue(ObjectMapper.java:517
> )
>        at org.codehaus.jackson.JsonParser.readValueAs(JsonParser.java:897)
>        at org.apache.cassandra.tools.SSTableImport.importUnsorted(SSTableImport
> .java:263)
>        at org.apache.cassandra.tools.SSTableImport.importJson(SSTableImport.jav
> a:252)
>        at org.apache.cassandra.tools.SSTableImport.main(SSTableImport.java:476)
>
>
>  Is there anything I can do with my data to fix this?
>
>  Cheers,
>  Steve
>



-- 
Jonathan Ellis
Project Chair, Apache Cassandra
co-founder of DataStax, the source for professional Cassandra support
http://www.datastax.com

Mime
View raw message