Stan Smith
12/16/2024, 5:11 PMpreview.
dependencies {
jdbcDriver 'com.microsoft.sqlserver:mssql-jdbc:latest.integration'
...
constraints {
jdbcDriver('com.microsoft.sqlserver:mssql-jdbc') {
version {
reject '12.9.0.jre+' // or '12.9.0.jre11-preview'
}
}
...
}ephemient
12/16/2024, 5:45 PMStan Smith
12/16/2024, 6:02 PMconfigurations {
...
jdbcDriver.resolutionStrategy = {
componentSelection { rules ->
rules.all { ComponentSelection selection ->
if (selection.candidate.version ==~ /.*preview*/) {
selection.reject('preview version')
}
}
}
}
}
However, that generates this error. Not sure how to resolve this.
* What went wrong:
A problem occurred evaluating root project 'test'.
> Cannot set the value of read-only property 'resolutionStrategy' for configuration ':jdbcDriver' of type org.gradle.api.internal.artifacts.configurations.DefaultUnlockedConfiguration.ephemient
12/16/2024, 6:05 PMresolutionStrategy { not resolutionStrategy = {Stan Smith
12/16/2024, 6:07 PM