Comments (4)
Sorry.
I just solved this problem removing
rm $SPARK_PATH/jars/clickhouse-jdbc-0.1-SNAPSHOT-jar-with-dependencies.jar
and using
cp clickhouse-jdbc-0.1-SNAPSHOT.jar $SPARK_PATH/jars/
and putting these jars to $SPARK_PATH/jars/
https://mvnrepository.com/artifact/org.apache.httpcomponents/httpclient/4.5.2
https://mvnrepository.com/artifact/org.apache.httpcomponents/httpcore/4.4.4
from clickhouse-java.
The problem begin to arise exactly when I put jar to spark jars dir
cp clickhouse-jdbc-0.1-SNAPSHOT-jar-with-dependencies.jar $SPARK_PATH/jars/
After this, even when I just read file in pyspark (commenting all clickhouse code) it gives me
Caused by: com.fasterxml.jackson.databind.JsonMappingException: Incompatible Jackson version: 2.7.3
So it crushes pyspark.
When I remove clickhouse-jdbc-0.1-SNAPSHOT-jar-with-dependencies.jar from $SPARK_PATH/jars/ my program begins to load DataFrame, but of course it cannot dump it to clickhouse.
from clickhouse-java.
Hello.
The problem is that current driver implementation has dependencies. In fact jackson isn't used for actual JDBC interface but for some specific methods, so it doesn't really matter which jackson version is provided.
Ideally drivers must be free of dependencies, but is not the case now and it needs a lot of effort.
You've found out the correct workaround.
You may need to add some other dependencies the same way if Spark doesn't provide ones and if you need the features provided by these dependencies: lz4, guava, joda-time.
from clickhouse-java.
Jackson was replaced by Gson(for better performance), and the latter is an optional dependency(because there's a simple JSON parser in jdbc driver).
from clickhouse-java.
Related Issues (20)
- Wrong values inserted using JDBC PreparedStatement for java.sql.Date[] type HOT 3
- Performance Metrics
- Prevent the execution of clearBatch() when executeBatch throws an exception. HOT 3
- [Tests] Parsing errors in server response HOT 1
- Upgrading 0.4.6 -> 0.5.0 or 0.6.0-patch4 breaks Metabase driver HOT 3
- feature request: Expose "queryId" field from "ClickHouseHttpResponse" to "ClickHouseResponse" HOT 1
- find a bug in clickhouse-jdbc 0.6.0 HOT 2
- [QA] Java: How to use the Native TCP protocol instead of the HTTP protocol? Is it GA-ed yet? HOT 10
- Add resseting memorized roles
- Versioning schema is weird HOT 3
- Github releases sometimes have no description HOT 2
- Cannot write to ostream at offset 692. (CANNOT_WRITE_TO_OSTREAM) HOT 1
- Clickhouse-JDBC does not support default columns in recommended input function
- Create the blog post for External customers
- [client-v2] Explore Migrate of Kafka Connector to use client-v2 HOT 1
- [client-v2] Explore migration of JDBC to the new client
- Migrate Metabase to use client-v2 (don't merge) HOT 3
- [QA] Hive and Clickhouse. How to select and insert data from clickhouse into hive using spark thrift server?
- Implement QueuedByteArrayInputStream
- clickhouse-jdbc driver did not support connection url parameters HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from clickhouse-java.