Reputation: 731
I'm using a lib_A as the dependency which is using the commons-io 2.11.0 as the dependency to perform IO ops and its marked scope as provided in the lib_A.
My project is a spark application which has HDInsight 5.0 as runtime. This runtime has commons-io version of 2.5.0. In 2.5.0 commons-io version doesn't a method called consume() which was newly added in commons-io 2.11.0v. Due to which I'm getting methodNotFound error.
I tried forcing the particular version as below, but didn't work.
implementation ("commons-io:commons-io"){
version {
strictly '2.11.0'
}
}
I also tried excluding this lib from the lib_A as well from the cradle as below and tried injecting the required version. But still it's trying to read from the runtime itself.
implementation ("com.files:slfs:${property('lfsVersion')}"){
exclude group: "commons-io", module: "commons-io"
}
I wanted to know id this something achievable where I can inform the lib_A to use the injected version and not the runtime provided lib? Any help would be appreciated.
Upvotes: 0
Views: 41