Solved

Extract EAR file into a Eclipse Project

Posted on 2010-11-22
9
3,545 Views
Last Modified: 2012-05-10
HI Expert
I have a ear file that I want to inport into Eclipse and start checking out the Code and run the project on my local machine. Question is is possible to do?

The ear contains
META-INF
name1.jar
name2.jar
name3.war


0
Comment
Question by:abooysen2
  • 4
  • 3
  • 2
9 Comments
 
LVL 17

Expert Comment

by:sweetfa2
ID: 34186798
jar xvf earfile

import from file system into your project
0
 

Author Comment

by:abooysen2
ID: 34187081
must I only import the ear file ?
0
 
LVL 11

Expert Comment

by:Manish
ID: 34190655
In Eclipse,
Import Ear file through
File>Import > Java EE > Ear file.
0
 
LVL 17

Expert Comment

by:sweetfa2
ID: 34191269
the jar command extracts the components of the ear to the file system.  You then import the components.

0
Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

 

Author Comment

by:abooysen2
ID: 34194422
Hi karanw
Sorry for not understanding correctly but when U import the ear file that contains the jar's and war will it line out in a proper project structure?
0
 
LVL 11

Expert Comment

by:Manish
ID: 34194735
I think you will be able to run the project.
After importing you will be able to see the structure.


0
 

Author Comment

by:abooysen2
ID: 34195877
Thanks karanw I have imported the ear file and saw the structure we have 2 jars and on war file and the Ear file that contains the application.xml let me give you a break down of the application.xml file

Now looking at the account-ejb->ImportedClasses folder is are all the packages with it's classes with ext *.class and not *.java.
 Now can I have to get the classes back to ext *.java and make changes and ensure that the ear will be updated.


<application>

    <display-name>DealApp</display-name>

    <description>Application description</description>

    <module id="EjbModule_1290506961748">

        <ejb>deal-ejb.jar</ejb>

    </module>

    

    <module id="EjbModule_1290506961779">

        <ejb>account-ejb.jar</ejb>

    </module>

  

   

    <module id="WebModule_1290506961795">

        <web>

            <web-uri>web-client.war</web-uri>

            <context-root>mmticket</context-root>

        </web>

    </module>

    <security-role>

            <role-name>MMuser</role-name>

    </security-role>

    

    





    

</application>

Open in new window

0
 
LVL 11

Accepted Solution

by:
Manish earned 125 total points
ID: 34196392
You dont have source code of this project?

To convert *class to *java, you need decompiler like jad.
0
 

Author Closing Comment

by:abooysen2
ID: 34203084
Thanks it's working 100%
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now