facebook

Importing existing (Maven-based) .ear project into ME 50GA

  1. MyEclipse IDE
  2.  > 
  3. Java EE Development (EJB, JSP, Struts, XDoclet, etc.)
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #256310 Reply

    Hi

    I have an .ear project structure like this:
    The .ear project consists of a web application, a datasource and a hibernate .har deployment:

    Source folders:
    \pom.xml
    \src\main\har\META-INF\hibernate-service.xml
    \src\main\hbm2x\hibernate.cfg.xml
    \src\main\resources\backend-ds.xml
    \src\main\resources\META-INF\jboss-app.xml
    \src\main\resources\resources\myapp.properties

    The application.xml file is being generated by Maven, and it also contains references to a web service webapp project that is included in the .ear, as well as a messagedriven bean and several lib’s that is being shared between the projects inside the .ear.

    All the resources (properties files) are being packaged at root level in the .ear, so that they can be shared between the modules inside the .ear.
    The datasource, the mdb-ejb.jar, web service and hibernate mapping are also all being placed in the .ear root by the maven build process.

    So to my question:
    – How can I configure ME for this kind of setup?

    …as I see it, I would have to make ME use the maven target folder instead of the source folders – which has obvious drawbacks regarding file syncronisation etc. (did I remember to run the build script before deploying, etc).

    #256315 Reply

    …as I see it, I would have to make ME use the maven target folder instead of the source folders – which has obvious drawbacks regarding file syncronisation etc. (did I remember to run the build script before deploying, etc).

    …the fact that this does not work of course…..
    I then get this error:

    J2EEComponentLinkAdditionJob(Time of error: ......
    Attempted to beginRul: R/, does not match outer scop rule: P/my-ear

    I have set the Maven target folder (which contains exactly what I want deployed) as a source folder on build path, as well as checked the “Allow output folder for source folders”

    #264425 Reply

    This worked like a charm in ME 5.1 on Eclipse 3.2.x

Viewing 3 posts - 1 through 3 (of 3 total)
Reply To: Importing existing (Maven-based) .ear project into ME 50GA

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