maven missing dependency jta-1.0.1B – Failure to find javax.transaction:jta:jar [Solved]
- Friday, October 14, 2016 By David Peter
I got an error – maven missing dependency for jta-1.0.1b while building a CloudReports project in Netbeans IDE. The error hinted that it has failed to find javax.transaction:jta:jar in the maven repository. Below is the complete error message.
[WARNING] An error occurred during dependency resolution. Failed to retrieve javax.transaction:jta-1.0.1B Caused by: Failure to find javax.transaction:jta:jar:1.0.1B in http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced
Well, here’s how I solved this error.
How to fix Maven missing dependency error – jta-1.0.1b?
If you carefully look at the error message “Failure to find javax.transaction:jta:jar:1.0.1B in http://repo.maven.apache.org/maven2“, it’s clear that maven is not able to download jta-1.0.1b jar from its own repository. It means, the jar might be missing from the repository or there might be a temporary name resolution error. To confirm, go to the maven repository URL (you will get it in the error message) and browse to javax > transaction > jta > 1.0.1B and look out for JTA jar file. If you don’t find one, then that’s the reason for maven’s failure to retrieve the jar file.
To solve this error, you can just download jta-1.0.1B jar and place it manually under the maven repository folder.
Step 1: Download jta-1.0.1B jar file.
Step 2: Unzip and copy the ‘jta-1.0.1B.jar‘ file
Step 3: Type %userprofile% in Run dialog
Step 4: Look out for .m2 folder and if you find one, just double click and navigate to repository > javax > transaction > jta > 1.0.1B folder and paste the jar file copied in step 2.
Step 5: Go back to your Netbeans and build the project again.
That’s it! Maven will skip jta error and will continue to setup other dependencies.