Ignore Problems by maven-enforcer-plugin - hibernate-validator

I am trying to use the maven-enforcer-plugin with the convergence rule. I managed to get rid of all problems except one.
We use gwt in our project and need the hibernate-validator 4.1.0.Final on the client side with scope provided. On the server side we need hibernate-validator 4.2.0.Final because we requrire some of the newer features. The 4.1.0.Final dependency has the classifier sources. This way I am able to have both versions in one pom.
Everything works fine but the enforcer-plugin is not so happy and fails.
Is there any way I can configure the plugin to allow this "problem" ?
Edit:
The enforcer-plugin fails with the following error:
[WARNING] Rule 0: org.apache.maven.plugins.enforcer.DependencyConvergence failed with message:
Failed while enforcing releasability the error(s) are [
Dependency convergence error for org.hibernate:hibernate-validator:4.1.0.Final paths to dependency are...
Regards,
arne

If anybody runs into the same Problem:
I solved it by renaming the artifact-id of the older version to hibernate-validator-gwt and uploading it to our own repository. Works for now.

I had the same problem with a new testcontainers-Version.
I got the following error:
[WARNING] Rule 1: org.apache.maven.plugins.enforcer.DependencyConvergence failed with message:
Failed while enforcing releasability the error(s) are [
Dependency convergence error for net.java.dev.jna:jna:5.2.0 paths to dependency are:
+-myGroupId:myArtifactId:0.1-SNAPSHOT
+-org.testcontainers:jdbc:1.15.0-rc2
+-org.testcontainers:database-commons:1.15.0-rc2
+-org.testcontainers:testcontainers:1.15.0-rc2
+-org.rnorth.visible-assertions:visible-assertions:2.1.2
+-net.java.dev.jna:jna:5.2.0
and
+-myGroupId:myArtifactId:0.1-SNAPSHOT
+-org.testcontainers:jdbc:1.15.0-rc2
+-org.testcontainers:database-commons:1.15.0-rc2
+-org.testcontainers:testcontainers:1.15.0-rc2
+-com.github.docker-java:docker-java-transport-zerodep:3.2.5
+-net.java.dev.jna:jna:5.5.0
I, kind of, ignored this error by adding the dependency which converged not correctly to my dependencyManagement:
<dependency>
<!-- declared to "ignore" error in enforcer-plugin in dependencyConvergence of testcontainer-dependency -->
<groupId>net.java.dev.jna</groupId>
<artifactId>jna</artifactId>
<version>5.5.0</version>
</dependency>
With this declaration, the enforcer-plugin is satisfied. I'm not that sure, if this is a good solution, due to the fact, that I got a new dependency managed, which I rather don't want to manage by myself.
P.S.: Here is the feature Dependency Convergence, we are talking about.
Edit: Probably an update of the used maven-Version may also help to resolve to convergence-problem without managing any additional dependency.

Related

Cause: org.jetbrains.plugins.gradle.tooling.util.ModuleComponentIdentifierImpl

I have connected my Android application with firebase-database by putting this dependency (kapt 'com.google.firebase:firebase-database:16.0.1:15.0.0') but after that I am getting errors like the one mentioned in title also when I synchronized the project I am getting different errors like: Connection time out, Failed to resolved build listener.
Enabling/Disabling offline work and setting proxy in gradle.properties file doesn't work for me.
Also you guys have seen that I used 'kapt' in dependency as it is necessary to use, without it I am getting error "failed to resolve 15.0.0". Removing 15.0.0 doesn't work for me.
Error
Cause:org.jetbrains.plugins.gradle.tooling.util.ModuleComponentIdentifierImpl.getModuleIdentifier()Lorg/gradle/api/artifacts/ModuleIdentifier;ing
I am using Android Studio 3.2 and sadly I can't update this version.
Gradle version: 5.1.1 and
Plugin version: 3.4.0

Karaf: Missing Constraint in bundle

I am trying to wrap dnsjava as a bundle in Karaf. When I try to start the bundle I get a "Missing Constraint" error. I looked in the dnsjava code and found that the only place android is referenced is in a Class.forName. So I am wondering what causes this problem and how can I get around it. I am pretty certain that the class is not referenced in the code anywhere.
Here is the exception:
opendaylight-user#root>bundle:start 288
Error executing command: Error executing command on bundles:
Unable to execute command on bundle 288: The bundle "dnsjava_2.1.8 [288]" could not be resolved. Reason: Missing Constraint: Import-Package: android.os; version="0.0.0"
I believe I found the answer. There is an Import in the MANIFEST.MF that requires android.os.

Appcelerator - include jar in build at compile-time?

Since Appcelerator(/Hyperloop) doesn't use Gradle or Maven to manage dependencies, I need to include them all manually for my project by placing them in the app/platform/android folder. I have done this, however I also need to include google dagger (https://github.com/google/dagger) which requires including dagger-compiler-2.x.jar , which I believe is an annotation processor that generates some type of code during compile-time.
Simply placing this in the app/platform/android folder like any other jar results in this error when the dexer is running during the build:
[ERROR] : Failed to run dexer:
[ERROR] :
[ERROR] : PARSE ERROR:
[ERROR] : MethodHandle not supported
[ERROR] : ...while preparsing cst 016c at offset 00001ceb
[ERROR] : ...while parsing com/google/googlejavaformat/java/JavaInput.class
[ERROR] : 1 error; aborting
I think it has something to do with the part of the dagger instructions which state "you will need to include dagger-compiler-2.x.jar in your build at compile time." Is there somewhere else that I need to place this jar file to get it to be used properly? Or is the use of compile-time annotation processors not something that Appcelerator/Hyperloop supports at this time? Any thoughts or insight would be greatly appreciated.
A good amount has changed since this question was asked. This being said, I believe that currently Hyperloop for Android doesn't handle annotations. And this is how dependency injection systems work, so I believe it's still not currently possible to use that or similar JARs.

Undefined class constant 'FOLLOW_SYMLINKS

after installing symfony 2.6 and when executing an error message is displayed:
FatalErrorException in DirectoryResource.php line 82:
Error: Undefined class constant 'FOLLOW_SYMLINKS'
the error is in the bundle: kriswallsmith
Please help me.
thank you in advance
Which versio of PHP are you running under? 5.2?
This sounds awfully similar to this issue report: https://github.com/caefer/sfImageTransformExtraPlugin/issues/5
The class constant, FOLLOW_SYMLINKS, is part of the RecursiveDirectoryIterator, which according to the PHP.net manual page, was added in 5.3.1 and also 5.2.11. At least version 5.3.9 is usually recommended or required by various frameworks because of various issues in prior versions.
The package is "kriswallsmith/assetic"

Crawler4j - Getting exception java.lang.NoSuchMethodError

I am trying to setup crawler4j via eclipse(juno).
When I run it, I am getting the below exception(even though the program keeps running without logging anything):
"Exception in thread "main" java.lang.NoSuchMethodError:
com.sleepycat.je.EnvironmentConfig.setAllowCreate(Z)Lcom/sleepycat/je/EnvironmentConfig;
at
edu.uci.ics.crawler4j.crawler.CrawlController.(CrawlController.java:90)
at
packCrawler.BasicCrawlController.main(BasicCrawlController.java:81)"
error?. I am also getting the same error. When I clicked on
(CrawlController.java:90)"
I could see that there is no source attached for CrawlController in crawler4j-3.4.jar. So I can't make out whether there is method "setAllowCreate" or not.
There is similar post at : NoSuchMethodError in crawler4j CrawelController class
But it does not exactly say how the problem got fixed. Does anybody have any suggestion?
Thanks very much for your time.
Neha
Look at the new crawler4j github: https://github.com/yasserg/crawler4j
Use the maven dependency system and all of your trouble will be gone!:
<dependency>
<groupId>edu.uci.ics</groupId>
<artifactId>crawler4j</artifactId>
<version>4.2</version>
</dependency>
You will get the latest version (now on github instead of google code)
Using an Dependency Management Tool such as Maven, you will automatically escape all classpath hell...

Resources