Maven 2: Spring and JTA dependencies

Posted by Lucio Benfante Sat, 26 Nov 2005 08:06:00 GMT

Few weeks ago I started using Maven 2 for one of my development projects. The project is very simple, but it has dependencies with some external libraries, in particular with Spring:

<dependency>
  <groupId>org.springframework</groupId>
  <artifactId>spring</artifactId>
  <version>1.2.6</version>
  <scope>runtime</scope>
</dependency>

Introducing this dependency I had the following errors:

Downloading: ->
    http://repo1.maven.org/maven2/javax/transaction ->
      /jta/1.0.1B/jta-1.0.1B.jar
[WARNING] Unable to get resource from repository central ->
    (http://repo1.maven.org/maven2)
...
[INFO] Failed to resolve artifact.

required artifacts missing:
 javax.transaction:jta:jar:1.0.1B

This happened because Spring has a transitive dependency with the Sun’s JTA classes, but the JTA jar can’t be inserted in the Maven repository because the Sun’s Binary License.

For solving this dependency you have to download the jta-1_0_1B-classes.zip file from the Sun’s site and install it into your local repository using the following command:

mvn install:install-file \
  -Dfile=./jta-1_0_1B-classes.zip \
  -DgroupId=javax.transaction \
  -DartifactId=jta -Dversion=1.0.1B \
  -Dpackaging=jar

More general information in these Maven’s mini guides:

Posted in  | Tags , , ,  | 80 comments

Comments

  1. Avatar sohallor said 476 days later:

    Thanks, very useful!

  2. Avatar fbregnvig said 557 days later:

    Thanks, very helpful indeed!

  3. Avatar cav said 563 days later:

    Thanks , the problem is solved!

  4. Avatar mike said 622 days later:

    Thank you! Clean & concise, this is exactly what I wanted.

  5. Avatar Sumit said 652 days later:

    Thanks, was just what I needed to know.

  6. Avatar Nick said 657 days later:

    thanks man, you saved me a lot of time

  7. Avatar Henrik said 704 days later:

    U can also point the maven rep to: http://download.java.net/maven/2/javax/transaction/jta/1.0.1B/

  8. Avatar dcasiel@yahoo.com said 758 days later:

    Thanks a lot :) This is the only good explanation of the problem that I saw after long search.

  9. Avatar Retschgi said 759 days later:

    Thank you! You made my day!

  10. Avatar James said 761 days later:

    Exactly the information I needed, thanks!

  11. Avatar Imran M Yousuf said 764 days later:

    Thanks! it is quite helpful

  12. Avatar Olivier said 787 days later:

    Thanks a lot :p

  13. Avatar Nuwi said 800 days later:

    Gracias!!!

  14. Avatar Pierre said 835 days later:

    Thanks! It solved my packaging problem!

  15. Avatar Sunil said 900 days later:

    Thanks dude, this helped

  16. Avatar salvi said 917 days later:

    thanks, this solve my problem

  17. Avatar gerardo said 921 days later:

    gracias, me sirvio mucho , directo y conciso

  18. Avatar Jörn Zaefferer said 958 days later:

    Henriks hint at the java.net repository was a very welcome addition. Just add it to your repositories element:

    <repository>
        <id>java.net</id>
        <name>java.net</name>
        <url>http://download.java.net/maven/2/</url>
    </repository>
    
  19. Avatar simon massey said 997 days later:

    N.B. the above approaches of directly injected into your cache or including a different maven server will make our project unportable to other developer workstations as they will have to hack their settings.xml to get things to work. instead you can do the following:

    configure maven to include hibernate artifacts but not the dependency to jta. particularly if you are going to deploy to a container that will provide the class itself you will have to do nothing else. use the following syntax:

    org.hibernate hibernate-entitymanager ${hibernate.version} javax.transaction jta

    if you are actually going to compile against jta then use the geronimo implimentation of the jta library that does not have a liciensing issue.

    org.apache.geronimo.specs geronimo-jta_1.0.1B_spec 1.1.1

    simply go to mvnrepository.com and search for geronimo-jta to find the correct version of the jta spec to include for your project.

    happy coding.

  20. Avatar simon massey said 997 days later:
    that will teach me not to preview! the pom fragments are as follows:
            <dependency>
                <groupId>org.hibernate</groupId>
                <artifactId>hibernate-entitymanager</artifactId>
                <version>${hibernate.version}</version>
                <exclusions>
                  <exclusion>
                    <groupId>javax.transaction</groupId>
                    <artifactId>jta</artifactId>
                  </exclusion>
                </exclusions>
            </dependency>
    

    and

    <dependency>
        <groupId>org.apache.geronimo.specs</groupId>
        <artifactId>geronimo-jta_1.0.1B_spec</artifactId>
        <version>1.1.1</version>
    </dependency>
    
  21. Avatar chris_five said 1024 days later:

    no luck at mvnrepository.com. jar file can be downloaded here: http://mirrors.ibiblio.org/pub/mirrors/maven2/org/apache/geronimo/specs/geronimo-jta_1.1_spec/1.1.1/

  22. Avatar felipper said 1482 days later:

    Cool! Exactaly what I want.

  23. Avatar kris said 1539 days later:

    this what i am looking for

  24. Avatar Tyler Pedersen said 1544 days later:

    Very well written. Thanks.

  25. Avatar mvnhtr said 1551 days later:

    And this is still a problem over 4 years later! geez.

  26. Avatar Gustaf said 1570 days later:

    Really helpful! Thanks a lot…/G

  27. Avatar Bakhyt said 1587 days later:

    Thanx, helpful! )))

  28. Avatar Dav said 1889 days later:

    Exactly what I needed – and to the point. Thanks.

  29. Avatar coach outlet said 1998 days later:

    When you were born, you’re crying but lookers-on were smiling. When you are passing away, you’re smiling but lookers-on are crying.

  30. Avatar benkt said 2010 days later:

    Thank you!

  31. Avatar Brian Lavender said 2014 days later:

    How do you import the JavaDoc?

  32. Avatar Gucci Outlet said 2020 days later:

    You will find when you seem around the globe that all individual little development inside humane experience, each development inside the legal legislation, each stage in the direction of the particular diminution regarding conflict, each stage in the direction of far better therapy with the tinted contests, or perhaps each mitigation regarding slavery, each meaning development in which there is on earth, continues to be persistently in contrast from the arranged places of worship with the planet. My partner and i point out really purposely the Orlando religious beliefs, since arranged inside the places of worship, continues to be whilst still being could be the main foe regarding meaning development on earth.

  33. Avatar Ture Religion Outlet said 2021 days later:

    You blog is so great for me, and what you said is so wonderful. I would like to visite it next time. Good luck , my friend! Looking forward to see more information from it .

  34. Avatar Ture Religion Outlet said 2021 days later:

    You blog is so great for me, and what you said is so wonderful. I would like to visite it next time. Good luck , my friend! Looking forward to see more information from it .

  35. Avatar Tiffany & CO Outlet said 2022 days later:

    Men and women get killed the other, throughout huge competitions along with guerilla steps, for several ages, nevertheless kill the other in the present, around Ideologies along with Religions which in turn, reported while propositions, look not genuine not phony for you to modern-day logicians—incomprehensible propositions that will search purposeful on the linguistically naive.

  36. Avatar Trick Photography and Special Effects E-Book Review said 2024 days later:

    When work is a pleasure , life is joy ! When work is duty , life is slavery .

  37. Avatar CHI Flat Iron said 2032 days later:

    It is available for your blog page, but some picture was lacking. I can not see it. Is it my personal computer program problem?

  38. Avatar New Jordans said 2033 days later:

    Don’t believe anything at all. Consider items over a level regarding possibilities. What seem to be many ludicrous, set beneath ‘Low Probability’, and also what seem to be many credible, an individual set beneath ‘High Probability’. By no means feel anything at all. As soon as you feel anything at all, an individual quit great deal of thought. The harder items you imagine, the particular a smaller amount emotional action. In the event you feel one thing, and possess an impression about each subject matter, in that case your human brain action prevents totally, which can be medically regarded an indication regarding dying, today inside health-related training. Thus set items over a level or perhaps possibility, rather than feel or perhaps disbelieve anything at all totally.

  39. Avatar Tiffany & CO Outlet said 2033 days later:

    You can find billions which feel the particular Messiah provides appear. When this individual would, next it really is sadly the truth in which his / her daring compromise and also dying experienced simply no result in any respect around the extremely difficulty his / her on its way might have been anticipated to deal with, regarding historical past displays, over and above issue, that individuals Christians are already in the same way hazardous, singly and also en lot, since non-Christians.

  40. Avatar Kobe VI said 2033 days later:

    Can it be honest being suspect of your complete career as a result of handful of negative oatmeal? You can find no less than a couple of crucial distinctions, this indicates if you ask me. Initial, no-one questions in which research is proven to work, whichever wrongly recognized and also deceitful state may well every so often become supplied. Yet whether or not you can find virtually any “miraculous” treatments coming from faith-healing, over and above your bodys very own power to treatment alone, is quite significantly with problem. Second of all, the particular expose’ regarding fraudulence and also problem inside research is manufactured practically specifically simply by research. Nevertheless the coverage regarding fraudulence and also problem inside faith-healing is practically by no means completed simply by some other faith-healers.

  41. Avatar New Jordans said 2042 days later:

    The Bible has been interpreted to justify such evil practices as, for example, slavery, the slaughter of prisoners of war, the sadistic murders of women believed to be witches, capital punishment for hundreds of offenses, polygamy, and cruelty to animals. It has been used to encourage belief in the grossest superstition and to discourage the free teaching of scientific truths. We must never forget that both good and evil flow from the Bible. It is therefore not above criticism.

  42. Avatar Barefoot running shoes said 2047 days later:

    It is better than never. so if you want to do some, ok , take action now !!! Barefoot running shoes could be the wonderful shoes in the hot summer. I also like to wear in them . they are has a good function on it !

  43. Avatar Ed Hardy Outlet said 2050 days later:

    That Type was translated to help you explain this type of satanic habits simply because, just like, captivity, that slaughter in criminals in fight, that sadistic murders in adult females thought to be witches, funding penalty designed for many hundreds of crimes, polygamy, and even rudeness to help you pets or animals. Experts agree it is would once support understanding with the grossest superstition so to decrease that 100 % free schooling in logical facts. Must always remember which will each of those decent and even satanic amount belonging to the Type. Hence, it is not even earlier complaint.

  44. Avatar Nike Air Force Ones Shoes said 2053 days later:

    For ages, a fabulous deadly disagreement is actually waged approximately a small number of fearless persons about reckoned and additionally renegade regarding the only team, and therefore the awesome not aware religious muscle mass fast relating to the other sorts of. This is actually fights approximately Knowledge and additionally Values. All the small number of experience become a huge hit to make sure you justification, to make sure you live up too, to make sure you regularions, to make sure you liberation, to noted, and also peace right on this planet. Numerous experience become a huge hit to make sure you bias, to make sure you terror, to make sure you secret, to make sure you captivity, to mystery, and also anguish hereafter. All the small number of experience talked about “Think” Numerous experience talked about “Believe! “

  45. Avatar Cheap NFL Jerseys said 2053 days later:

    Lost wealth can be replaced by industry, lost knowledge by study, lost health by temperance or medicine, but lost time is gone for ever.

  46. Avatar Hancy said 2066 days later:

    It’s a lucky day!I get one pair of women heels from Heels sale! It’s have beautiful appearance and very comfortable! Here’s your first look at the first Women’s Heels that I have ever seen. I do believe this is the first time our store has released a Women’s Heels in a high top form.

  47. Avatar Cheap Nike Air Max said 2081 days later:

    In keeping with workplace fashions, you might want to think about acquiring advertising and marketing area on a occupation looking out web pages or a second profession centered blog. Those who are seeking work are very likely to desire or want guidance with picking out a brand new wardrobe. Particularly focusing on people who are possible to be your customers, may be a surefire option to make your corporation a being successful.At the same time a lot of skilled vogue consultants have victory managing a neighborhood corporation, chances are you’ll also plan to give thought to working a web-based style consulting business enterprise also. Whereas it could be a bit hard to do, it is usually far more than possible.

  48. Avatar Philippe C said 2083 days later:

    Thanks ! This was very helpful !

  49. Avatar Herve Leger Discount said 2090 days later:

    n 20 wounds , painful .

    recently Buy Herve Leger , Ms

  50. Avatar air max 2012 said 2091 days later:

    The world can be changed by man‘s endeavor, and that this endeavor can lead to something new and better .No man can sever the bonds that unite him to his society simply by averting his eyes . He must ever be receptive and sensitive to the new ; and have sufficient courage and skill to novel facts and to deal with them .

  51. Avatar Jeans Online Outlet said 2108 days later:

    This can make them good candidates for Ethnic Elegance fashion profiles. This could enable you the reader and guests to be a great deal more mindful with the authentic ethnic fashions readily available to you personally. Sometime we will aim within the ethnic fashion variations and many others would be the ethnic concentrating on ethnic trend designers. What seriously excite individuals about ethnic fashions are the shades, fabrics put into use, detailing and stitching, styles and types. Creativeness also plays a big part. Many people are preparing to obtain their very own ethnic goods. On line ethnic style retail outlet happens to be designed to make getting ethnic apparel and ethnic jewellery a pleasurable and easy searching working experience.

  52. Avatar Jordan 1 retro said 2121 days later:

    At twenty years of age , the will reigns; at thirty , the wit ; and at forty , the judgment .

  53. Avatar portable generators said 2125 days later:

    Very enlightening thank you, I think your current audience may perhaps want far more information like this carry on the good effort.portable generators

  54. Avatar portable generators said 2129 days later:

    I am not sure where you are getting your information, but good topic. I needs to spend some time learning much more or understanding more. Stainless Steel Valves had attracted attention of buyers for its dynamic functionalities and strength.

  55. Avatar AKPK said 2158 days later:

    Thanks problem solved

  56. Avatar GuerreroRUBY33 said 2163 days later:

    Do you acknowledge that it’s the best time to receive the mortgage loans, which would realize your dreams.

  57. Avatar HERMINIATownsend said 2230 days later:

    I had got a dream to make my company, but I did not have enough of money to do this. Thank heaven my mate suggested to take the loan. Thus I received the term loan and made real my desire.

  58. Avatar WattsAngela28 said 2311 days later:

    The loan suppose to be useful for people, which would like to ground their own business. In fact, this is not very hard to get a short term loan.

  59. Avatar Hattie34JOSEPH said 2311 days later:

    When you are in a not good position and have no cash to get out from that, you would have to take the mortgage loans. Because that should aid you definitely. I take college loan every time I need and feel great just because of it.

  60. Avatar AMANDAARNOLD said 2338 days later:

    I took my first business loans when I was a teenager and that helped my business a lot. But, I require the credit loan again.

  61. Avatar amal said 2346 days later:

    thaaaaaaaaaaaaaaaanks a lot

  62. Avatar FUENTES34Audrey said 2361 days later:

    When you’re in not good state and have no money to move out from that point, you will have to receive the loans. Because that will help you unquestionably. I take auto loan every time I need and feel myself good because of that.

  63. Avatar WildaWiggins30 said 2402 days later:

    The credit loans suppose to be very useful for guys, which want to ground their own career. By the way, that is very easy to get a short term loan.

  64. Avatar bo huang said 2444 days later:

    thanks a lot!!

  65. Avatar OliveClay said 2501 days later:

    I guess that to get the business loans from creditors you must have a good reason. But, once I’ve received a secured loan, just because I was willing to buy a car.

  66. Avatar Ferguson26Maura said 2504 days later:

    Various people in the world get the credit loans in various creditors, just because that is simple.

  67. Avatar Short28MADGE said 2510 days later:

    We are aware that your A+ relies on perfectly completed papers. I guess that is reasonable to buy college term paper and be sure that all is going well with your academic career.

  68. Avatar MathisYesenia said 2613 days later:

    Humanity evolves fast and at present time you do not need to create your essays and should just buy an essay in the web.

  69. Avatar KimAdele21 said 2614 days later:

    Take into consideration such fact that while getting essay papers to buy at paper writing service, you may face unkind attitude. In case you begin to understand that the company wants to cheat you, do not buy college papers from it.

  70. Avatar CLAUDIAMay said 2617 days later:

    I opine that the writing service aids students to reach their aims. Thence, they should be thankful about it!

  71. Avatar BenitaScott said 2626 days later:

    Open Internet site for more help and order excellent custom essays and improve your student’s life just by obtaining our professional research paper services.

  72. Avatar RosaFletcher said 2628 days later:

    The credit loans suppose to be useful for guys, which would like to organize their organization. In fact, it’s very easy to get a short term loan.

  73. Avatar NATALIAMorrow30 said 2630 days later:

    Do you get what college students seem to be concentrated on? They people are focused on top grades! Nevertheless, to get premium quality papers you must have someone like term paper services to assist you.

  74. Avatar HamiltonPatricia28 said 2666 days later:

    Order Exploratory Essay according to your instructions written by highly qualified writers and derive pleasure from writing process.

  75. Avatar MarcyPATE said 2666 days later:

    You are overloaded and have no clue how to create your History Essay, get it from the most trustful firm and you will never regret.

  76. Avatar tgyuytse said 2682 days later:

    jehkjfhjdnhvittrhgdjh

  77. Avatar Mariusz O. said 2744 days later:

    Thank You a lot!!

  78. Avatar HensleyVicki said 2751 days later:

    Are you still trying to find perfect term paper help? There is no need to proceed with a search, get in touch with GOLDESSAYS company and order essays and you will never regret.

  79. Avatar StantonOFELIA said 2807 days later:

    People deserve very good life time and loans or just student loan will make it much better. Just because people’s freedom is grounded on money.

  80. Avatar sink said 3196 days later:

    Thanks for taking the effort to provide us with the tips from the Post.

    Regads, pratmotor

(leave url/email »)

   Comment Markup Help Preview comment