Import file to Janusgraph throws [ Property value [[255]] is of type class java.util.ArrayList is not supported ] error


Tejasri pavuluri <tejas...@...>
 

Trying to export and import using below two scripts.

Export works fine(with no issues).


Export script:

============

                GraphSONMapper m = graph.io(IoCore.graphson()).mapper().embedTypes(false).create();
                GraphWriter writer = graph.io(IoCore.graphson()).writer().mapper(m).create();
                FileOutputStream fos = new FileOutputStream(targetFile);
                writer.writeGraph(fos, graph);
                //graph.io(IoCore.graphson()).readGraph(targetFile);
                graph.tx().commit()



Exported file content:

==================

{"id":61624,"label":"vertex","inE":{"drop":[{"id":"4ckck-yl9c-3r4l-1bjs","outV":1613856,"properties":{"type":"drop"}}],"contains":[{"id":"1m32-6eo-2m1h-1bjs","outV":8304,"properties":{"type":"contains"}},{"id":"6syf-2gmw-2m1h-1bjs","outV":114872,"properties":{"type":"contains"}},{"id":"7pqs-3lpc-2m1h-1bjs","outV":168096,"properties":{"type":"contains"}},{"id":"9ijg-47vk-2m1h-1bjs","outV":196832,"properties":{"type":"contains"}},{"id":"aham-4nlc-2m1h-1bjs","outV":217200,"properties":{"type":"contains"}},{"id":"d4hw-623k-2m1h-1bjs","outV":282656,"properties":{"type":"contains"}},{"id":"f8d8-6xuo-2m1h-1bjs","outV":323808,"properties":{"type":"contains"}},{"id":"ivim-8fhs-2m1h-1bjs","outV":393328,"properties":{"type":"contains"}},{"id":"im1o-8iqo-2m1h-1bjs","outV":397536,"properties":{"type":"contains"}},{"id":"jxft-9qvc-2m1h-1bjs","outV":454728,"properties":{"type":"contains"}},{"id":"ms5y-b8og-2m1h-1bjs","outV":524464,"properties":{"type":"contains"}},{"id":"ndi4-b8ps-2m1h-1bjs","outV":524512,"properties":{"type":"contains"}},{"id":"qxwc-ck4g-2m1h-1bjs","outV":585952,"properties":{"type":"contains"}},{"id":"yhb3-hng8-2m1h-1bjs","outV":823544,"properties":{"type":"contains"}},{"id":"18isf-m4mw-2m1h-1bjs","outV":1032440,"properties":{"type":"contains"}},{"id":"1dx5r-oet4-2m1h-1bjs","outV":1138936,"properties":{"type":"contains"}},{"id":"1exwf-ooag-2m1h-1bjs","outV":1151224,"properties":{"type":"contains"}}]},"outE":{"add":[{"id":"44653-1bjs-3qc5-yl9c","inV":1613856,"properties":{"type":"add"}}],"contains":[{"id":"69zr-1bjs-2m1h-1emg","inV":65608,"properties":{"type":"contains"}},{"id":"d79z-1bjs-2m1h-4nm8","inV":217232,"properties":{"type":"contains"}},{"id":"8w0n-1bjs-2m1h-6oe0","inV":311544,"properties":{"type":"contains"}},{"id":"9xjr-1bjs-2m1h-7jzs","inV":352504,"properties":{"type":"contains"}},{"id":"hwd3-1bjs-2m1h-7wl4","inV":368824,"properties":{"type":"contains"}},{"id":"bxg7-1bjs-2m1h-8veg","inV":413944,"properties":{"type":"contains"}},{"id":"l2jb-1bjs-2m1h-amlc","inV":495840,"properties":{"type":"contains"}},{"id":"o00n-1bjs-2m1h-az34","inV":512032,"properties":{"type":"contains"}},{"id":"oemv-1bjs-2m1h-b5io","inV":520368,"properties":{"type":"contains"}},{"id":"n8rb-1bjs-2m1h-b5k0","inV":520416,"properties":{"type":"contains"}},{"id":"pwrb-1bjs-2m1h-b8lk","inV":524360,"properties":{"type":"contains"}},{"id":"pvyv-1bjs-2m1h-c10g","inV":561184,"properties":{"type":"contains"}},{"id":"f02f-1bjs-2m1h-dvjs","inV":647416,"properties":{"type":"contains"}},{"id":"ftp3-1bjs-2m1h-ft2w","inV":737528,"properties":{"type":"contains"}},{"id":"jc47-1bjs-2m1h-ifw8","inV":860408,"properties":{"type":"contains"}},{"id":"pfrr-1bjs-2m1h-nsoo","inV":1110264,"properties":{"type":"contains"}}]},"properties":{"gridMaxEdgeFreq":[{"id":"1st3-1bjs-2had","value":196.125}],"createdAt":[{"id":"1t7b-1bjs-27t1","value":"Wed May 13 22:10:26 EDT 2020 (1589422226318) "}],"lastModifiedAt":[{"id":"1tzr-1bjs-28lh","value":"Wed May 13 22:10:26 EDT 2020 (1589422226318) "}],"gridMinEdgeFreq":[{"id":"1tlj-1bjs-2i2t","value":191.325}],"contentionId":[{"id":"1udz-1bjs-2iv9","value":"3/1"}],"gridMaxSlices":[{"id":"1us7-1bjs-2jnp","value":768}],"gridBitSet":[{"id":"1v6f-1bjs-2kg5","value":[-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1]}],"name":[{"id":"1vkn-1bjs-sl","value":"splpp:wdm:L100-DOCKER-NE71:3/1"}],"gridSliceSize":[{"id":"1vyv-1bjs-2l8l","value":0.00625}],"nodeType":[{"id":"1wd3-1bjs-2dh","value":"SPLPP"}],"tid":[{"id":"1wrb-1bjs-745","value":"L100-DOCKER-NE71"}],"layer":[{"id":"1x5j-1bjs-8p1","value":"wdm"}]}}
{"id":2797728,"label":"vertex","outE":{"contains":[{"id":"47cb8-1nyqo-2m1h-126zk","inV":1781984,"properties":{"type":"contains"}}]},"properties":{"lastModifiedAt":[{"id":"46adw-1nyqo-28lh","value":"Wed May 13 22:10:40 EDT 2020 (1589422240842) "}],"bandwidth":[{"id":"46as4-1nyqo-2nlx","value":"available"}],"nodeType":[{"id":"46bkk-1nyqo-2dh","value":"OCHPTP"}],"type":[{"id":"46b6c-1nyqo-5j9","value":"och"}],"version":[{"id":"46bys-1nyqo-2cjp","value":"2.5.2"}],"tid":[{"id":"46cd0-1nyqo-745","value":"L100-DOCKER-NE73"}],"layer":[{"id":"46cr8-1nyqo-8p1","value":"wdm"}],"createdAt":[{"id":"46d5g-1nyqo-27t1","value":"Wed May 13 22:10:40 EDT 2020 (1589422240842) "}],"vendor":[{"id":"46djo-1nyqo-2ghx","value":"Fujitsu Limited"}],"name":[{"id":"46dxw-1nyqo-sl","value":"ochptp:wdm:L100-DOCKER-NE73:och:och-1/0/0/C2:Rx"}],"client":[{"id":"46ec4-1nyqo-2oed","value":false}],"shelfType":[{"id":"46eqc-1nyqo-2vid","value":"BDL1-3R11"}],"state":[{"id":"46f4k-1nyqo-2p6t","value":"pending"}],"cardtype":[{"id":"46fis-1nyqo-2pz9","value":"BDL1-3R11"}],"neType":[{"id":"46gb8-1nyqo-2br9","value":"1FINITY-L100"}],"aid":[{"id":"46fx0-1nyqo-2qrp","value":"och-1/0/0/C2"}],"faultCount":[{"id":"46gpg-1nyqo-2rk5","value":0}],"direction":[{"id":"46h3o-1nyqo-2scl","value":"Rx"}]}}


Import script

================

               GraphSONMapper m = graph.io(IoCore.graphson()).mapper().embedTypes(false).create();
                GraphReader reader = graph.io(
IoCore.graphson()).reader().mapper(m).create();
                FileInputStream fis = new FileInputStream(targetFile);
                reader.readGraph(fis, graph);
                graph.tx().commit()


I see below error.

===================


Problem while opening GraphDB

java.lang.IllegalArgumentException: Property value [[255]] is of type class java.util.ArrayList is not supported

        at org.apache.tinkerpop.gremlin.structure.Property$Exceptions.dataTypeOfPropertyValueNotSupported(Property.java:163)

        at org.apache.tinkerpop.gremlin.structure.Property$Exceptions.dataTypeOfPropertyValueNotSupported(Property.java:159)



Can you please let us know if you have any thoughts on supporting arrayLists? (as marked above)