Comments (12)
Hey,
sorry I had some issues with the notification mail.
I tried your advise to force the version of jackson but without success. I tried various versions and also to force the version of swagger core.
Im not sure how much I should trust the IntelliJs debugging, but when I am at the class and hovering over the classname during debugging, IntelliJ is saying that the class is provided by your kafka schema registry plugin. So the version restriction was not successful.
I did the following in the build.gradle.kts
plugins {
kotlin("jvm") version "1.9.21"
id("com.github.imflog.kafka-schema-registry-gradle-plugin") version "1.12.0"
id("org.openapi.generator") version "7.1.0"
}
buildscript {
configurations.all {
resolutionStrategy.eachDependency {
if (this.requested.group.startsWith("com.fasterxml.jackson")) {
this.useVersion("2.15.3")
}
}
}
}
...
from schema-registry-plugin.
I've rolled back the changes around the fat jar.
Will merge this with the new features that will soon land (proto local reference and rulesets ...).
Hope it will fix your issue and let you upgrade to new versions 🙏
If the issue persist after the new version, do not hesitate to reopen an issue.
from schema-registry-plugin.
Hello,
Given your configuration i don't see the link with the schema registry plugin ?
Is it a shared dependency that is not in the right version that impacts the openapi-plugin ?
from schema-registry-plugin.
Just to confirm that we hit this issue as well when trying to use 1.12.0. As soon as there is a dependency on both of these plugins, the openApiGenerate
task fails with the error above.
Our workaround was to use 1.11.1, though would appreciate any solutions people discover!
from schema-registry-plugin.
Since version 1.12 we use a "fat jar" to simplify the configuration process.
I think the issue here is that the jackson library has a mismatched version that breaks the openapi plugin.
We use the transitive dependency from apache.avro which use the 2.14.2 while openapi plugin is probably 2.15.3.
Could you try to add this to your buildscript configuration and see if it fixes the issue:
configurations.all {
resolutionStrategy.eachDependency {
if (this.requested.group.startsWith("com.fasterxml.jackson")) {
this.useVersion("2.15.3")
}
}
}
This will have the effect of forcing the version of jackson to 2.15.3 (or whatever version openapi expects).
I will probably not fix the version of jackson in this plugin because it would be risky as It's a transitive dependency.
from schema-registry-plugin.
Sorry to hear that @pcharisius :(
Can you try to build a local version of this project with a greater Jackson version and see if it fixes your issue (the README provides some pointers about how to do that) ?
If it does fix your issue, and that it breaks nothing elsewhere we might merge a PR that fixes a greater version.
from schema-registry-plugin.
@pcharisius got any news about this ? Did you manage to try with a local version ?
Else can you publish a reproducible repo where I could try it myself ?
from schema-registry-plugin.
@ImFlog sorry, I could not get it to work. I have published a minimal example that you can try to solve the problem.
You can find it here: https://github.com/pcharisius/minimal_example
from schema-registry-plugin.
Thank you, I will take a look before the end of the week 🙏
from schema-registry-plugin.
I took another shot at trying to understand the issue.
It in fact seems that the version is taken from the Kafka Schema registry dependency (for some reason there are still in 2.14.2). And even though the avro dependency requires 2.15.3, that's the confluent version that takes the precedence.
If I require a 2.15.3 version on the project I have an issue with Jackson and Gradle. I think I should update to Gradle 8 to fix it.
I am thinking about going back to the non fat-jar deploy to allow end-user to manage the dependency version as they like, that would fix the issue while adding just a bit of boring repositories to the buildscript phase.
Sorry for the delay on this but I will keep you posted when I get some time to work on this.
from schema-registry-plugin.
I tried to release a new version today. I fall into a new error when I try the example directory with the new version. It seems that the Kotlin version required by one of the dependency conflicts with the Gradle one.
I only manage to make the plugin work with Gradle 8.X.
I am not sure what commit makes this fail. I will have to try each commit separately and see why It does not work. I don't really understand why the integration tests / build works in CI and locally and not when I use the published version. This makes no sense (maybe I have this error locally only ?).
That will delay a bit the release 🙇
from schema-registry-plugin.
Should be good by using version 2.0.0 and Gradle > 8.
Sorry for the delay 🙇
from schema-registry-plugin.
Related Issues (20)
- Support for attaching @Nullable annotation on nullable fields HOT 2
- SchemaParseException during testSchemasTask HOT 2
- Dependency "com.github.ImFlog.avro:avro:1.11.2" not resolvable HOT 1
- Fat jar all the thing ? HOT 1
- Support Gradle 8.X.X
- DownloadTask should download all referenced schemas HOT 7
- Ability to toggle pretty-print of outputted schema files for Avro/JSON formats HOT 6
- Support for IDL language(`.avdl`) HOT 1
- Update forked avro plugin HOT 1
- Issues registering schema via gradle 8.2.1 HOT 3
- Recursively download schema references
- Configure registry client with a map HOT 2
- Does the "name" argument to "addReference" and "addLocalReference" do anything when using Avro schemas? HOT 2
- Add new Kafka versions to the test matrix in Github Action
- Support for AVDL HOT 1
- Support custom root dir for Protobuf local references
- downloadSchemasTask is always executed even when inputs don't change HOT 2
- Unable to reuse subjects HOT 2
- Test Schema Compatibility in JSON Format using kotlin objects HOT 2
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 schema-registry-plugin.