Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No suitable ClickHouse client(out of 0) found in classpath. #31

Open
tkanos opened this issue May 18, 2023 · 4 comments
Open

No suitable ClickHouse client(out of 0) found in classpath. #31

tkanos opened this issue May 18, 2023 · 4 comments

Comments

@tkanos
Copy link

tkanos commented May 18, 2023

Hello guys,

I'm really trying hard to make it work, but I will need a bit of help if you can.

I'm using the master version of liquibase-clickhouse and the shaded jar
Here is my liquibase.properties :

changeLogFile: /liquibase/changelog/root-changelog.xml
url: jdbc:clickhouse://my_hosted_clickhouse:8123
username: admin_rw
password: *************
classpath: /liquibase/changelog
driver: shaded.liquibase.com.clickhouse.jdbc.ClickHouseDriver
databaseClass: liquibase.ext.clickhouse.database.ClickHouseDatabase
strict: true

And I run liquibase on docker versio 4.15 like in the pom file:

 docker run -it --rm -v $(pwd)/liquibase/changelog:/liquibase/changelog -v$(pwd)/liquibase-clickhouse/target/liquibase-clickhouse-0.7.3-SNAPSHOT-shaded.jar:/liquibase/lib/clickhouse.jar liquibase/liquibase:4.15 --defaults-file=/liquibase/changelog/liquibase.properties --log-level=debug update

But I get the following error :

[2023-05-18 20:02:29] FINE [liquibase.database] Properties:
[2023-05-18 20:02:29] FINE [liquibase.database] Key:'user' Value:'admin_rw'
[2023-05-18 20:02:29] FINE [liquibase.database] Connecting to the URL:'jdbc:clickhouse://*************:8123' using driver:'shaded.liquibase.com.clickhouse.jdbc.ClickHouseDriver'
[2023-05-18 20:02:29] FINE [liquibase.servicelocator] Loaded liquibase.database.DatabaseConnection instance liquibase.database.jvm.JdbcConnection
[2023-05-18 20:02:29] FINE [liquibase.servicelocator] Loaded liquibase.database.DatabaseConnection instance com.datical.liquibase.ext.database.jvm.ProJdbcConnection
[2023-05-18 20:02:29] SEVERE [liquibase.integration] No suitable ClickHouse client(out of 0) found in classpath.
liquibase.exception.CommandExecutionException: liquibase.exception.DatabaseException: liquibase.exception.DatabaseException: liquibase.exception.DatabaseException: java.lang.IllegalStateException: No suitable ClickHouse client(out of 0) found in classpath.
	at liquibase.command.CommandScope.execute(CommandScope.java:179)
	at liquibase.integration.commandline.CommandRunner.call(CommandRunner.java:51)
	at liquibase.integration.commandline.CommandRunner.call(CommandRunner.java:21)
	at picocli.CommandLine.executeUserObject(CommandLine.java:1953)
	at picocli.CommandLine.access$1300(CommandLine.java:145)
	at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2358)
	at picocli.CommandLine$RunLast.handle(CommandLine.java:2352)
	at picocli.CommandLine$RunLast.handle(CommandLine.java:2314)
	at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2179)
	at picocli.CommandLine$RunLast.execute(CommandLine.java:2316)
	at picocli.CommandLine.execute(CommandLine.java:2078)
	at liquibase.integration.commandline.LiquibaseCommandLine.lambda$execute$1(LiquibaseCommandLine.java:353)
	at liquibase.Scope.child(Scope.java:189)
	at liquibase.Scope.child(Scope.java:165)
	at liquibase.integration.commandline.LiquibaseCommandLine.execute(LiquibaseCommandLine.java:318)
	at liquibase.integration.commandline.LiquibaseCommandLine.main(LiquibaseCommandLine.java:84)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.base/java.lang.reflect.Method.invoke(Unknown Source)
	at liquibase.integration.commandline.LiquibaseLauncher.main(LiquibaseLauncher.java:107)
Caused by: liquibase.exception.DatabaseException: liquibase.exception.DatabaseException: liquibase.exception.DatabaseException: java.lang.IllegalStateException: No suitable ClickHouse client(out of 0) found in classpath.
	at liquibase.integration.commandline.CommandLineUtils.createDatabaseObject(CommandLineUtils.java:139)
	at liquibase.integration.commandline.Main.doMigration(Main.java:1485)
	at liquibase.integration.commandline.Main$1.lambda$run$0(Main.java:397)
	at liquibase.Scope.lambda$child$0(Scope.java:180)
	at liquibase.Scope.child(Scope.java:189)
	at liquibase.Scope.child(Scope.java:179)
	at liquibase.Scope.child(Scope.java:158)
	at liquibase.integration.commandline.Main$1.run(Main.java:396)
	at liquibase.integration.commandline.Main$1.run(Main.java:218)
	at liquibase.Scope.child(Scope.java:189)
	at liquibase.Scope.child(Scope.java:165)
	at liquibase.integration.commandline.Main.run(Main.java:218)
	at liquibase.command.AbstractCliWrapperCommandStep.run(AbstractCliWrapperCommandStep.java:33)
	at liquibase.command.CommandScope.execute(CommandScope.java:173)
	... 20 more
Caused by: liquibase.exception.DatabaseException: liquibase.exception.DatabaseException: java.lang.IllegalStateException: No suitable ClickHouse client(out of 0) found in classpath.
	at liquibase.database.DatabaseFactory.openConnection(DatabaseFactory.java:218)
	at liquibase.database.DatabaseFactory.openConnection(DatabaseFactory.java:176)
	at liquibase.database.DatabaseFactory.openDatabase(DatabaseFactory.java:141)
	at liquibase.integration.commandline.CommandLineUtils.createDatabaseObject(CommandLineUtils.java:93)
	... 33 more
Caused by: liquibase.exception.DatabaseException: java.lang.IllegalStateException: No suitable ClickHouse client(out of 0) found in classpath.
	at liquibase.database.ConnectionServiceFactory.create(ConnectionServiceFactory.java:35)
	at liquibase.database.DatabaseFactory.openConnection(DatabaseFactory.java:215)
	... 36 more
Caused by: java.lang.IllegalStateException: No suitable ClickHouse client(out of 0) found in classpath.
	at shaded.liquibase.com.clickhouse.client.ClickHouseClientBuilder.build(ClickHouseClientBuilder.java:103)
	at shaded.liquibase.com.clickhouse.jdbc.internal.ClickHouseConnectionImpl.<init>(ClickHouseConnectionImpl.java:185)
	at shaded.liquibase.com.clickhouse.jdbc.internal.ClickHouseConnectionImpl.<init>(ClickHouseConnectionImpl.java:168)
	at shaded.liquibase.com.clickhouse.jdbc.ClickHouseDriver.connect(ClickHouseDriver.java:145)
	at shaded.liquibase.com.clickhouse.jdbc.ClickHouseDriver.connect(ClickHouseDriver.java:41)
	at liquibase.database.jvm.JdbcConnection.open(JdbcConnection.java:83)
	at com.datical.liquibase.ext.database.jvm.ProJdbcConnection.open(Unknown Source)
	at liquibase.database.ConnectionServiceFactory.create(ConnectionServiceFactory.java:32)
	... 37 more


Unexpected error running Liquibase: No suitable ClickHouse client(out of 0) found in classpath.

liquibase.exception.CommandExecutionException: liquibase.exception.DatabaseException: liquibase.exception.DatabaseException: liquibase.exception.DatabaseException: java.lang.IllegalStateException: No suitable ClickHouse client(out of 0) found in classpath.
	at liquibase.command.CommandScope.execute(CommandScope.java:179)
	at liquibase.integration.commandline.CommandRunner.call(CommandRunner.java:51)
	at liquibase.integration.commandline.CommandRunner.call(CommandRunner.java:21)
	at picocli.CommandLine.executeUserObject(CommandLine.java:1953)
	at picocli.CommandLine.access$1300(CommandLine.java:145)
	at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2358)
	at picocli.CommandLine$RunLast.handle(CommandLine.java:2352)
	at picocli.CommandLine$RunLast.handle(CommandLine.java:2314)
	at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2179)
	at picocli.CommandLine$RunLast.execute(CommandLine.java:2316)
	at picocli.CommandLine.execute(CommandLine.java:2078)
	at liquibase.integration.commandline.LiquibaseCommandLine.lambda$execute$1(LiquibaseCommandLine.java:353)
	at liquibase.Scope.child(Scope.java:189)
	at liquibase.Scope.child(Scope.java:165)
	at liquibase.integration.commandline.LiquibaseCommandLine.execute(LiquibaseCommandLine.java:318)
	at liquibase.integration.commandline.LiquibaseCommandLine.main(LiquibaseCommandLine.java:84)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.base/java.lang.reflect.Method.invoke(Unknown Source)
	at liquibase.integration.commandline.LiquibaseLauncher.main(LiquibaseLauncher.java:107)
Caused by: liquibase.exception.DatabaseException: liquibase.exception.DatabaseException: liquibase.exception.DatabaseException: java.lang.IllegalStateException: No suitable ClickHouse client(out of 0) found in classpath.
	at liquibase.integration.commandline.CommandLineUtils.createDatabaseObject(CommandLineUtils.java:139)
	at liquibase.integration.commandline.Main.doMigration(Main.java:1485)
	at liquibase.integration.commandline.Main$1.lambda$run$0(Main.java:397)
	at liquibase.Scope.lambda$child$0(Scope.java:180)
	at liquibase.Scope.child(Scope.java:189)
	at liquibase.Scope.child(Scope.java:179)
	at liquibase.Scope.child(Scope.java:158)
	at liquibase.integration.commandline.Main$1.run(Main.java:396)
	at liquibase.integration.commandline.Main$1.run(Main.java:218)
	at liquibase.Scope.child(Scope.java:189)
	at liquibase.Scope.child(Scope.java:165)
	at liquibase.integration.commandline.Main.run(Main.java:218)
	at liquibase.command.AbstractCliWrapperCommandStep.run(AbstractCliWrapperCommandStep.java:33)
	at liquibase.command.CommandScope.execute(CommandScope.java:173)
	... 20 more
Caused by: liquibase.exception.DatabaseException: liquibase.exception.DatabaseException: java.lang.IllegalStateException: No suitable ClickHouse client(out of 0) found in classpath.
	at liquibase.database.DatabaseFactory.openConnection(DatabaseFactory.java:218)
	at liquibase.database.DatabaseFactory.openConnection(DatabaseFactory.java:176)
	at liquibase.database.DatabaseFactory.openDatabase(DatabaseFactory.java:141)
	at liquibase.integration.commandline.CommandLineUtils.createDatabaseObject(CommandLineUtils.java:93)
	... 33 more
Caused by: liquibase.exception.DatabaseException: java.lang.IllegalStateException: No suitable ClickHouse client(out of 0) found in classpath.
	at liquibase.database.ConnectionServiceFactory.create(ConnectionServiceFactory.java:35)
	at liquibase.database.DatabaseFactory.openConnection(DatabaseFactory.java:215)
	... 36 more
Caused by: java.lang.IllegalStateException: No suitable ClickHouse client(out of 0) found in classpath.
	at shaded.liquibase.com.clickhouse.client.ClickHouseClientBuilder.build(ClickHouseClientBuilder.java:103)
	at shaded.liquibase.com.clickhouse.jdbc.internal.ClickHouseConnectionImpl.<init>(ClickHouseConnectionImpl.java:185)
	at shaded.liquibase.com.clickhouse.jdbc.internal.ClickHouseConnectionImpl.<init>(ClickHouseConnectionImpl.java:168)
	at shaded.liquibase.com.clickhouse.jdbc.ClickHouseDriver.connect(ClickHouseDriver.java:145)
	at shaded.liquibase.com.clickhouse.jdbc.ClickHouseDriver.connect(ClickHouseDriver.java:41)
	at liquibase.database.jvm.JdbcConnection.open(JdbcConnection.java:83)
	at com.datical.liquibase.ext.database.jvm.ProJdbcConnection.open(Unknown Source)
	at liquibase.database.ConnectionServiceFactory.create(ConnectionServiceFactory.java:32)
	... 37 more

@alexsivkovu
Copy link

@tkanos hello, did you fix this problem? I have the same

@iTem186
Copy link

iTem186 commented Apr 15, 2024

@tkanos , @alexsivkovu , Hi!
Have the same problem. Any information?

@tkanos
Copy link
Author

tkanos commented Apr 16, 2024

Hello guys,

Nop I have not found a solution. Ultimately I am instead using https://github.com/golang-migrate/migrate .
that works well so far.

@BentsiLeviav
Copy link

Could you please share your pom file?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants