You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by n000b <us...@yahoo.com> on 2009/07/23 18:18:06 UTC

Packaging external jars used within the ejb...

Hi all,

I have ejb that uses some external libraries, I have configured my pom.xml
for that and the jars are found during compile time and the ejb jar is
generated. What I want to do is to package the libs used by the ejb with the
ejb itself i.e. placing those lib under


|_ _ _ META-INF
             +
             |_ _ _ lib
                       +
                       |_ _ _ (the needed jars)

I am using scope as "compile" for those jar (in the dependency tag). But
those jars are not packaged into the ejb. Don't know if it's on any
important, I have a ear project in maven, that contains various ejb(s). I
dont want to put all the libs in the ear directory.

I'd highly appreciate, if anyone could comment on what I am doing wrong in
this case?

Thanks in Advance,
Usman.
-- 
View this message in context: http://www.nabble.com/Packaging-external-jars-used-within-the-ejb...-tp24629335p24629335.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: property files management: best practices?

Posted by "Jeudy, Guillaume" <gj...@teksystems.com>.
Hi,
 
Make a separate module containing your test properties in src/main/resources. Then include this module as a test scope dependency to other modules that need them for tests.
 
Guillaume Jeudy - Sr. Java developer
Java and Open Source Application Development - Montreal Solutions Centre
1801, McGill College Avenue, Suite 1100
Montreal, QC, H3A 2N4
gjeudy@teksystems.com 
W: +1-514-840-6329           F: +1-514-840-6241
 <https://outlook.allegisgroup.com/exchweb/bin/redir.asp?URL=http://www.teksystems.com/> 

________________________________

From: Alexander Vaysberg [mailto:work@vaisberg.de]
Sent: Fri 7/24/2009 9:49 AM
To: Maven Users List
Subject: Re: property files management: best practices?



Hi,

the maven can it make with many possibility,  the first is separete the
test configuration from production configuration. For this has maven
/src/test/resources.

Alexander Vaysberg
florian.cavagnini@ingdirect.fr schrieb:
> Hi
>
> I know that by convention the property files of a java maven project are
> in src/main/resources.
>
> But in my case, I have a pom which have about 50 modules, each module is
> a jar project.
>
> Some property files are common, as connection to database, spring
> configuration files, etc...
>
> I want to have theses common files shared by all my modules, available
> in their classpath to run tests.
>
> What are the best practices concerning this kind of situation?
>
>
> Thanks
>
> Florian
> -----------------------------------------------------------------
> ATTENTION:
> The information in this electronic mail message is private and
> confidential, and only intended for the addressee. Should you
> receive this message by mistake, you are hereby notified that
> any disclosure, reproduction, distribution or use of this
> message is strictly prohibited. Please inform the sender by
> reply transmission and delete the message without copying or
> opening it.
>
> Messages and attachments are scanned for all viruses known.
> If this message contains password-protected attachments, the
> files have NOT been scanned for viruses by the ING mail domain.
> Always scan attachments before opening them.
> -----------------------------------------------------------------
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>  


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org






____________________________________________________________________________________________________
This electronic mail (including any attachments) may contain information that is privileged, confidential, and/or otherwise protected from disclosure to anyone other than its intended recipient(s). Any dissemination or use of this electronic email or its contents (including any attachments) by persons other than the intended recipient(s) is strictly prohibited. If you have received this message in error, please notify us immediately by reply email so that we may correct our internal records. Please then delete the original message (including any attachments) in its entirety. Thank you.


Re: property files management: best practices?

Posted by Alexander Vaysberg <wo...@vaisberg.de>.
Hi,

the maven can it make with many possibility,  the first is separete the 
test configuration from production configuration. For this has maven 
/src/test/resources.

Alexander Vaysberg
florian.cavagnini@ingdirect.fr schrieb:
> Hi
>
> I know that by convention the property files of a java maven project are
> in src/main/resources.
>
> But in my case, I have a pom which have about 50 modules, each module is
> a jar project.
>
> Some property files are common, as connection to database, spring
> configuration files, etc...
>
> I want to have theses common files shared by all my modules, available
> in their classpath to run tests.
>
> What are the best practices concerning this kind of situation?
>
>
> Thanks
>
> Florian
> -----------------------------------------------------------------
> ATTENTION:
> The information in this electronic mail message is private and
> confidential, and only intended for the addressee. Should you
> receive this message by mistake, you are hereby notified that
> any disclosure, reproduction, distribution or use of this
> message is strictly prohibited. Please inform the sender by
> reply transmission and delete the message without copying or
> opening it.
>
> Messages and attachments are scanned for all viruses known.
> If this message contains password-protected attachments, the
> files have NOT been scanned for viruses by the ING mail domain.
> Always scan attachments before opening them.
> -----------------------------------------------------------------
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>   


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


property files management: best practices?

Posted by fl...@ingdirect.fr.
Hi

I know that by convention the property files of a java maven project are
in src/main/resources.

But in my case, I have a pom which have about 50 modules, each module is
a jar project.

Some property files are common, as connection to database, spring
configuration files, etc...

I want to have theses common files shared by all my modules, available
in their classpath to run tests.

What are the best practices concerning this kind of situation?


Thanks

Florian
-----------------------------------------------------------------
ATTENTION:
The information in this electronic mail message is private and
confidential, and only intended for the addressee. Should you
receive this message by mistake, you are hereby notified that
any disclosure, reproduction, distribution or use of this
message is strictly prohibited. Please inform the sender by
reply transmission and delete the message without copying or
opening it.

Messages and attachments are scanned for all viruses known.
If this message contains password-protected attachments, the
files have NOT been scanned for viruses by the ING mail domain.
Always scan attachments before opening them.
-----------------------------------------------------------------



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Packaging external jars used within the ejb...

Posted by Wayne Fay <wa...@gmail.com>.
> I have ejb that uses some external libraries, I have configured my pom.xml
> for that and the jars are found during compile time and the ejb jar is
> generated. What I want to do is to package the libs used by the ejb with the
> ejb itself i.e. placing those lib under

The Assembly plugin is your friend.

Wayne

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Packaging external jars used within the ejb...

Posted by n000b <us...@yahoo.com>.
Bump!


n000b wrote:
> 
> Hi all,
> 
> I have ejb that uses some external libraries, I have configured my pom.xml
> for that and the jars are found during compile time and the ejb jar is
> generated. What I want to do is to package the libs used by the ejb with
> the ejb itself i.e. placing those lib under
> 
> 
> |_ _ _ META-INF
>              +
>              |_ _ _ lib
>                        +
>                        |_ _ _ (the needed jars)
> 
> I am using scope as "compile" for those jar (in the dependency tag). But
> those jars are not packaged into the ejb. Don't know if it's on any
> important, I have a ear project in maven, that contains various ejb(s). I
> dont want to put all the libs in the ear directory.
> 
> I'd highly appreciate, if anyone could comment on what I am doing wrong in
> this case?
> 
> Thanks in Advance,
> Usman.
> 

-- 
View this message in context: http://www.nabble.com/Packaging-external-jars-used-within-the-ejb...-tp24629335p24642044.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org