[BUG] Custom serializer with custom ioRegistry isn't MessageSerializer because of shadow
Opened this issue · 0 comments
Describe the bug
- Have you validated that this is not currently reported in
SQL Support and Limitations?
Steps to Reproduce
- Is the JDBC Driver being used in a BI tool?
1. I use 1.1.0 version of driver
2. I use SQL variant (I think it is problem for every language)
3. I connect to Janusgraph server, so I need `ioRegistry` be `JanusGraphIoRegistry`
4. I use gremlin version 3.5.3 in Janusgraph, so I change files in driver, so its compile with this version of gremlin (I also change some import because of it).
5.
openjdk version "1.8.0_342"
OpenJDK Runtime Environment (build 1.8.0_342-8u342-b07-0ubuntu1~20.04-b07)
OpenJDK 64-Bit Server VM (build 25.342-b07, mixed mode)
Link to stackoverflow with example code
Problematic code is locate in GremlinConnectionProperties.java
(used in GremlinQueryExecutor.java
), when driver checks serializer is Object. Because JanusGraphIoRegistry isn't located in shadow, i need import org.apache.tinkerpop.gremlin.driver.MessageSerializer
in my script. But because of it, instanceof
return false
, when we check for MessageSerializer
, beсause MessageSerializer
in driver is located in shadow.org.apache.tinkerpop.gremlin.driver.MessageSerializer
Expected behavior
I want to be able to add custom serializers with custom ioRegistry
Screenshots
Environment
- OS: Ubuntu 20.04
Additional Context
I suggest remove in root build.gradle
line with relocate 'org.apache.tinkerpop', 'shadow.org.apache.tinkerpop'
, so that you can easily add custom serializers