facebook

Dependent project not included in EAR file

  1. MyEclipse Archived
  2.  > 
  3. Application Servers and Deployment
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #310099 Reply

    dason
    Member

    I have a group of related projects organized as follows:

    
    EJBproject
        ProjectOne
        WebProject
    

    Within ProjectOne, I have a class called Users. I would like to use this class in WebProject.
    From within MyEclipse, I can get WebProject to see class Users by adding ProjectOne as a required project.
    To include ProjectOne’s Users class in WebProject, I have done the following:
    MyEclipse –> Preferences –> Java Enterprise Project –> (for both EJBproject and WebProject)
    Selected the option to Jar dependent Java projects, checked Jars exported from dependent Java projects, checked user library jars exported from dependent Java projects.
    However, when I deploy EJBproject, either by exporting it as an EAR file or deploying it to an application server, it goes missing and I get a runtime error on missing class Users.
    When I unpack the EAR file, it is not showing ProjectOne’s classes in the lib/ folder of either EJBproject or WebProject.

    The only way I can get this to work is to manually jar up ProjectOne and include it as a library on the build path of WebProject. I would really like this to be something dynamic that the IDE handles.

    Any thoughts?

    I did look through the forums to see if I could find a solution, while I did see some similar issues, nothing quite matched what I’m seeing.

    Thanks,
    Dave

    #310134 Reply

    Dave,
    Can you clarify if you have enabled any project specific settings for your projects? Can you Right click on your web project and from the context menu select properties > MyEclipse > web > deployments. What are the options that are selected there?
    similarly can you go to Project > properties > MyEclipse > EAR and check the options set?

    #310189 Reply

    dason
    Member

    For the web project, here’s what is set under MyEclipse > web > deployments:
    Web Project Deployment Policy:
    Use workbench default settings is checked. The radio button is grayed out and “JAR and place them in the /lib director” is selectred.

    Library Deployment Policies:
    Use workbench default settings is checked
    Everything else is checked under that but grayed out

    For the EJB project:
    How should dependent Java projects be handled during deployment?
    Use workbench settings is checked.
    The Jar dependent Java projects radio button is selected and grayed out.

    Library Deployment Policies:
    Enterprise project deployments should include:
    Use workbench default settings is checked.
    The two other options are grayed out and checked.

    Deployment Descriptor Management Policy:
    Automatically update “application.xml” as needed is selected.

    Do you need anything else?

    Thank you for your help,
    Dave

    #310211 Reply

    Dave,
    I could not replicate your issue with dependent java projects and the deployment settings that you have mentioned.
    Can you list out the steps in detail, right from the project creation, to replicate your issue?
    Also, can you send us the screen shots showing the deployment settings for the web, ear and ejb?

Viewing 4 posts - 1 through 4 (of 4 total)
Reply To: Dependent project not included in EAR file

You must be logged in to post in the forum log in