You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by elaroche <ed...@steria.fr> on 2008/01/24 10:56:20 UTC

jboss data-source not included in jboss-app.xml

Hi everyone,

I'm trying to generate a ear containing a jboss-app.xml file which would
declare the datasource to use.

actually what I have is:
		<plugin>
			<artifactId>maven-ear-plugin</artifactId>
			<configuration>
				<defaultJavaBundleDir>/lib/</defaultJavaBundleDir>
				<jboss>
					<version>4.2</version>
					<data-sources>
						<data-source>mydatasource-ds.xml</data-source>
					</data-sources>
				</jboss>			
			</configuration>
		</plugin>

but the generated jboss-app.xml is :
 <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE jboss-app PUBLIC
	"-//JBoss//DTD J2EE Application 1.4//EN"
	"http://www.jboss.org/j2ee/dtd/jboss-app_4_2.dtd">
<jboss-app/>

The datasource referency is not included :confused:


I've been really looking everywhere without any success !!! any Idea ?
-- 
View this message in context: http://www.nabble.com/jboss-data-source-not-included-in-jboss-app.xml-tp15061842s177p15061842.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: jboss data-source not included in jboss-app.xml

Posted by elaroche <ed...@steria.fr>.
thanks mate, later is better than never :handshake:

Ernesto Salgado wrote:
> 
> This response arrives a bit late :wistle:, i know ... but here is the
> solution.
> 
> The problem is that the latest release of maven-ear-plugin at the moment
> is 2.3.1, and this version don't implement this feature yet!!!
> 
> data-sources tag is considered since version 2.3.2, and actually
> maven-ear-plugin is in 2.3.2-SNAPSHOT version.
> 
> You can download the source code of the plugin from Apache's SVN, package
> and install the SNAPSHOT version on your local repository.
> 
> Best regards.
> 
> 

-- 
View this message in context: http://www.nabble.com/jboss-data-source-not-included-in-jboss-app.xml-tp15061842s177p16347854.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: jboss data-source not included in jboss-app.xml

Posted by Ernesto Salgado <yn...@gmail.com>.
This response arrives a bit late :wistle:, i know ... but here is the
solution.

The problem is that the latest release of maven-ear-plugin at the moment is
2.3.1, and this version don't implement this feature yet!!!

data-sources tag is considered since version 2.3.2, and actually
maven-ear-plugin is in 2.3.2-SNAPSHOT version.

You can download the source code of the plugin from Apache's SVN, package
and install the SNAPSHOT version on your local repository.

Best regards.

-- 
View this message in context: http://www.nabble.com/jboss-data-source-not-included-in-jboss-app.xml-tp15061842s177p16329962.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: jboss data-source not included in jboss-app.xml

Posted by elaroche <ed...@steria.fr>.
damn it !! that's a good idea, I should've thought about that myself !!!
thanks mate.


Wayne Fay wrote:
> 
> Sorry for the misdirection -- I'm a bit surprised that the ear plugin
> supports this functionality. Shows how much I've used Maven + JBoss...
> ;-)
> 
> You may need to poke around in the code for maven-ear-plugin and see
> exactly how it is creating the jboss-app.xml file etc.
> 
> Wayne
> 
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/jboss-data-source-not-included-in-jboss-app.xml-tp15061842s177p15129838.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: jboss data-source not included in jboss-app.xml

Posted by Wayne Fay <wa...@gmail.com>.
Sorry for the misdirection -- I'm a bit surprised that the ear plugin
supports this functionality. Shows how much I've used Maven + JBoss...
;-)

You may need to poke around in the code for maven-ear-plugin and see
exactly how it is creating the jboss-app.xml file etc.

Wayne

On 1/25/08, elaroche <ed...@steria.fr> wrote:
>
> the ear plugin is supposed to do that, just have a look at that :
> http://maven.apache.org/plugins/maven-ear-plugin/examples/generating-jboss-app.html
> and in
> http://maven.apache.org/plugins/maven-ear-plugin/usage.html
> where it says :
>
> data-sources: specify the desired data source(s) to add into the
> jboss-app.xml, usage is as follows:
> <configuration>
>  <jboss>
>    [...]
>    <data-sources>
>      <data-source>main-ds.xml</data-source>
>      <data-source>config/secondary-ds.xml</data-source>
>      [...]
>    </data-sources>
>  </jboss>
> </configuration>
>
>
> but it doesn't seam to work
>
>
> Wayne Fay wrote:
> >
> > There may be a JBoss plugin for M2 that would create the xml file for
> > you. This is certainly not a feature of the ear plugin.
> >
> > If you can't find an existing plugin, you could always write your own,
> > or create the jboss-app.xml file manually.
> >
> > Wayne
> >
> >
>
> --
> View this message in context: http://www.nabble.com/jboss-data-source-not-included-in-jboss-app.xml-tp15061842s177p15083435.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
>
>

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


Re: jboss data-source not included in jboss-app.xml

Posted by elaroche <ed...@steria.fr>.
the ear plugin is supposed to do that, just have a look at that :
http://maven.apache.org/plugins/maven-ear-plugin/examples/generating-jboss-app.html
and in 
http://maven.apache.org/plugins/maven-ear-plugin/usage.html
where it says :

data-sources: specify the desired data source(s) to add into the
jboss-app.xml, usage is as follows:
<configuration>
  <jboss>
    [...]
    <data-sources>
      <data-source>main-ds.xml</data-source>
      <data-source>config/secondary-ds.xml</data-source>
      [...]
    </data-sources>
  </jboss>
</configuration>


but it doesn't seam to work


Wayne Fay wrote:
> 
> There may be a JBoss plugin for M2 that would create the xml file for
> you. This is certainly not a feature of the ear plugin.
> 
> If you can't find an existing plugin, you could always write your own,
> or create the jboss-app.xml file manually.
> 
> Wayne
> 
> 

-- 
View this message in context: http://www.nabble.com/jboss-data-source-not-included-in-jboss-app.xml-tp15061842s177p15083435.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: jboss data-source not included in jboss-app.xml

Posted by Wayne Fay <wa...@gmail.com>.
There may be a JBoss plugin for M2 that would create the xml file for
you. This is certainly not a feature of the ear plugin.

If you can't find an existing plugin, you could always write your own,
or create the jboss-app.xml file manually.

Wayne

On 1/24/08, elaroche <ed...@steria.fr> wrote:
>
> thanks for your reply.
>
> actually I don't want to include the datasource xml file in the ear. I need
> it to stay outside from my ear. What I need is the jboss-app.xml file to
> refer to the jndi datasource name.
>
> I'm starting to look for a workaround (creating the jboss-app.xml myself to
> include in the ear) but it's not the "maven" way, well not the right way.
> I'd like maven to generate the jboss-app.xml  properly.
>
>
> Manos Batsis wrote:
> >
> >
> > AFAIK you don't need to use jboss-app.xml, you can add a module in
> > application.xml [1]. Also check out [2].
> >
> > [1] http://www.theserverside.com/discussions/thread.tss?thread_id=34977
> > [2] http://jira.codehaus.org/browse/MEAR-52
> >
> > hth,
> >
> > Manos
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
> >
> >
>
> --
> View this message in context: http://www.nabble.com/jboss-data-source-not-included-in-jboss-app.xml-tp15061842s177p15062684.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
>
>

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


Re: jboss data-source not included in jboss-app.xml

Posted by elaroche <ed...@steria.fr>.
thanks for your reply.

actually I don't want to include the datasource xml file in the ear. I need
it to stay outside from my ear. What I need is the jboss-app.xml file to
refer to the jndi datasource name.

I'm starting to look for a workaround (creating the jboss-app.xml myself to
include in the ear) but it's not the "maven" way, well not the right way.
I'd like maven to generate the jboss-app.xml  properly. 


Manos Batsis wrote:
> 
> 
> AFAIK you don't need to use jboss-app.xml, you can add a module in 
> application.xml [1]. Also check out [2].
> 
> [1] http://www.theserverside.com/discussions/thread.tss?thread_id=34977
> [2] http://jira.codehaus.org/browse/MEAR-52
> 
> hth,
> 
> Manos
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/jboss-data-source-not-included-in-jboss-app.xml-tp15061842s177p15062684.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: jboss data-source not included in jboss-app.xml

Posted by Manos Batsis <ma...@geekologue.com>.


elaroche wrote:
 > I'm trying to generate a ear containing a jboss-app.xml  would
 > file which declare the datasource to use.


AFAIK you don't need to use jboss-app.xml, you can add a module in 
application.xml [1]. Also check out [2].

[1] http://www.theserverside.com/discussions/thread.tss?thread_id=34977
[2] http://jira.codehaus.org/browse/MEAR-52

hth,

Manos

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