Schemagen generating ignoring <outputDirectory> when <transformSchemas> present.

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Schemagen generating ignoring <outputDirectory> when <transformSchemas> present.

Miguel Garz
Good morning/afternoon everybody.
I'm having some problem with the mojo-Jaxb plugin.
What's happening is that I configured the plugin to output the schemas to a specific folder,
that works fine, unless I use the <transformSchemas> tag to configure the schema name.
In this case, what happens is that the schemas are generated, without the correct name, but in the standard folder (not the one in the <outputDirectory>).
Below is my maven pom configuration and also a excerpt of my code (with the annotations),
Would someone know what I'm doing wrong or if it is a bug on the plugin?
Thanks,
Miguel Garz

My pom:

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>jaxb2-maven-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<phase>generate-resources</phase>
<id>schemagen</id>
<goals>
<goal>schemagen</goal>
</goals>
<configuration>
<verbose>true</verbose>
<transformSchemas>
<transformSchema>
<toPrefix>rid</toPrefix>
<toFile>ri6-ws-domain</toFile>
</transformSchema>
</transformSchemas>
<includes>
<include>com/delagelanden/rijee6/domain/*.java</include>
</includes>
<outputDirectory>${basedir}/../schema/src/main/xsd</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>


My classes:

...
public class Project {
...


Reply | Threaded
Open this post in threaded view
|

Re: Schemagen generating ignoring <outputDirectory> when <transformSchemas> present.

Anders Hammar
I had a quick look at the plugin's ITs and there is verification of this functionality. SO it might very well be a bug. At least I can't spot anything wrong in your pom snippet. Please file a JIRA ticket with a small test project. Also, as there is minimal development on this plugin any patches would increase the likelihood of this being fixed.

Btw, your specified output directory path is not good. NEVER go outside of your Maven project in the file system. Also, ALWAYS stay within the ${project.build.directory} folder. Be sure to use something like that in your test project for the ticket.


On Mon, May 27, 2013 at 3:07 PM, Miguel Garz <[hidden email]> wrote:
Good morning/afternoon everybody.
I'm having some problem with the mojo-Jaxb plugin.
What's happening is that I configured the plugin to output the schemas to a specific folder,
that works fine, unless I use the <transformSchemas> tag to configure the schema name.
In this case, what happens is that the schemas are generated, without the correct name, but in the standard folder (not the one in the <outputDirectory>).
Below is my maven pom configuration and also a excerpt of my code (with the annotations),
Would someone know what I'm doing wrong or if it is a bug on the plugin?
Thanks,
Miguel Garz

My pom:

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>jaxb2-maven-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<phase>generate-resources</phase>
<id>schemagen</id>
<goals>
<goal>schemagen</goal>
</goals>
<configuration>
<verbose>true</verbose>
<transformSchemas>
<transformSchema>
<toPrefix>rid</toPrefix>
<toFile>ri6-ws-domain</toFile>
</transformSchema>
</transformSchemas>
<includes>
<include>com/delagelanden/rijee6/domain/*.java</include>
</includes>
<outputDirectory>${basedir}/../schema/src/main/xsd</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>


My classes:

...
public class Project {
...



Reply | Threaded
Open this post in threaded view
|

Re: Schemagen generating ignoring <outputDirectory> when <transformSchemas> present.

Anders Hammar
The first sentence turned out wrong. It should read:
I had a quick look at the plugin's ITs and there is no verification of this functionality.

/Anders


On Mon, May 27, 2013 at 3:49 PM, Anders Hammar <[hidden email]> wrote:
I had a quick look at the plugin's ITs and there is verification of this functionality. SO it might very well be a bug. At least I can't spot anything wrong in your pom snippet. Please file a JIRA ticket with a small test project. Also, as there is minimal development on this plugin any patches would increase the likelihood of this being fixed.

Btw, your specified output directory path is not good. NEVER go outside of your Maven project in the file system. Also, ALWAYS stay within the ${project.build.directory} folder. Be sure to use something like that in your test project for the ticket.


On Mon, May 27, 2013 at 3:07 PM, Miguel Garz <[hidden email]> wrote:
Good morning/afternoon everybody.
I'm having some problem with the mojo-Jaxb plugin.
What's happening is that I configured the plugin to output the schemas to a specific folder,
that works fine, unless I use the <transformSchemas> tag to configure the schema name.
In this case, what happens is that the schemas are generated, without the correct name, but in the standard folder (not the one in the <outputDirectory>).
Below is my maven pom configuration and also a excerpt of my code (with the annotations),
Would someone know what I'm doing wrong or if it is a bug on the plugin?
Thanks,
Miguel Garz

My pom:

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>jaxb2-maven-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<phase>generate-resources</phase>
<id>schemagen</id>
<goals>
<goal>schemagen</goal>
</goals>
<configuration>
<verbose>true</verbose>
<transformSchemas>
<transformSchema>
<toPrefix>rid</toPrefix>
<toFile>ri6-ws-domain</toFile>
</transformSchema>
</transformSchemas>
<includes>
<include>com/delagelanden/rijee6/domain/*.java</include>
</includes>
<outputDirectory>${basedir}/../schema/src/main/xsd</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>


My classes:

...
public class Project {
...




Reply | Threaded
Open this post in threaded view
|

Re: Schemagen generating ignoring <outputDirectory> when <transformSchemas> present.

Miguel Garz
Thank you,
I will do it!

Regards,
Miguel Garz


On Mon, May 27, 2013 at 3:50 PM, Anders Hammar <[hidden email]> wrote:
The first sentence turned out wrong. It should read:
I had a quick look at the plugin's ITs and there is no verification of this functionality.

/Anders


On Mon, May 27, 2013 at 3:49 PM, Anders Hammar <[hidden email]> wrote:
I had a quick look at the plugin's ITs and there is verification of this functionality. SO it might very well be a bug. At least I can't spot anything wrong in your pom snippet. Please file a JIRA ticket with a small test project. Also, as there is minimal development on this plugin any patches would increase the likelihood of this being fixed.

Btw, your specified output directory path is not good. NEVER go outside of your Maven project in the file system. Also, ALWAYS stay within the ${project.build.directory} folder. Be sure to use something like that in your test project for the ticket.


On Mon, May 27, 2013 at 3:07 PM, Miguel Garz <[hidden email]> wrote:
Good morning/afternoon everybody.
I'm having some problem with the mojo-Jaxb plugin.
What's happening is that I configured the plugin to output the schemas to a specific folder,
that works fine, unless I use the <transformSchemas> tag to configure the schema name.
In this case, what happens is that the schemas are generated, without the correct name, but in the standard folder (not the one in the <outputDirectory>).
Below is my maven pom configuration and also a excerpt of my code (with the annotations),
Would someone know what I'm doing wrong or if it is a bug on the plugin?
Thanks,
Miguel Garz

My pom:

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>jaxb2-maven-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<phase>generate-resources</phase>
<id>schemagen</id>
<goals>
<goal>schemagen</goal>
</goals>
<configuration>
<verbose>true</verbose>
<transformSchemas>
<transformSchema>
<toPrefix>rid</toPrefix>
<toFile>ri6-ws-domain</toFile>
</transformSchema>
</transformSchemas>
<includes>
<include>com/delagelanden/rijee6/domain/*.java</include>
</includes>
<outputDirectory>${basedir}/../schema/src/main/xsd</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>


My classes:

...
public class Project {
...





Reply | Threaded
Open this post in threaded view
|

Re: Schemagen generating ignoring <outputDirectory> when <transformSchemas> present.

Miguel Garz
Hi Anders,
I'm not open a issue in Jira:
It says that I should contact the administrator to open a issue, but there is no reference e-mail,
would you have any idea on what I should do?
Thanks,
Miguel


On Mon, May 27, 2013 at 3:53 PM, Miguel Garz <[hidden email]> wrote:
Thank you,
I will do it!

Regards,
Miguel Garz


On Mon, May 27, 2013 at 3:50 PM, Anders Hammar <[hidden email]> wrote:
The first sentence turned out wrong. It should read:
I had a quick look at the plugin's ITs and there is no verification of this functionality.

/Anders


On Mon, May 27, 2013 at 3:49 PM, Anders Hammar <[hidden email]> wrote:
I had a quick look at the plugin's ITs and there is verification of this functionality. SO it might very well be a bug. At least I can't spot anything wrong in your pom snippet. Please file a JIRA ticket with a small test project. Also, as there is minimal development on this plugin any patches would increase the likelihood of this being fixed.

Btw, your specified output directory path is not good. NEVER go outside of your Maven project in the file system. Also, ALWAYS stay within the ${project.build.directory} folder. Be sure to use something like that in your test project for the ticket.


On Mon, May 27, 2013 at 3:07 PM, Miguel Garz <[hidden email]> wrote:
Good morning/afternoon everybody.
I'm having some problem with the mojo-Jaxb plugin.
What's happening is that I configured the plugin to output the schemas to a specific folder,
that works fine, unless I use the <transformSchemas> tag to configure the schema name.
In this case, what happens is that the schemas are generated, without the correct name, but in the standard folder (not the one in the <outputDirectory>).
Below is my maven pom configuration and also a excerpt of my code (with the annotations),
Would someone know what I'm doing wrong or if it is a bug on the plugin?
Thanks,
Miguel Garz

My pom:

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>jaxb2-maven-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<phase>generate-resources</phase>
<id>schemagen</id>
<goals>
<goal>schemagen</goal>
</goals>
<configuration>
<verbose>true</verbose>
<transformSchemas>
<transformSchema>
<toPrefix>rid</toPrefix>
<toFile>ri6-ws-domain</toFile>
</transformSchema>
</transformSchemas>
<includes>
<include>com/delagelanden/rijee6/domain/*.java</include>
</includes>
<outputDirectory>${basedir}/../schema/src/main/xsd</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>


My classes:

...
public class Project {
...






Reply | Threaded
Open this post in threaded view
|

Re: Schemagen generating ignoring <outputDirectory> when <transformSchemas> present.

Miguel Garz
In reply to this post by Miguel Garz
Hi people,
I'm actually looking into the plugin code, and I think I might fix it.
Is it a possibility to download the source code and build the plugin locally?
Any help?
Thanks,
Miguel Garz


On Mon, May 27, 2013 at 3:07 PM, Miguel Garz <[hidden email]> wrote:
Good morning/afternoon everybody.
I'm having some problem with the mojo-Jaxb plugin.
What's happening is that I configured the plugin to output the schemas to a specific folder,
that works fine, unless I use the <transformSchemas> tag to configure the schema name.
In this case, what happens is that the schemas are generated, without the correct name, but in the standard folder (not the one in the <outputDirectory>).
Below is my maven pom configuration and also a excerpt of my code (with the annotations),
Would someone know what I'm doing wrong or if it is a bug on the plugin?
Thanks,
Miguel Garz

My pom:

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>jaxb2-maven-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<phase>generate-resources</phase>
<id>schemagen</id>
<goals>
<goal>schemagen</goal>
</goals>
<configuration>
<verbose>true</verbose>
<transformSchemas>
<transformSchema>
<toPrefix>rid</toPrefix>
<toFile>ri6-ws-domain</toFile>
</transformSchema>
</transformSchemas>
<includes>
<include>com/delagelanden/rijee6/domain/*.java</include>
</includes>
<outputDirectory>${basedir}/../schema/src/main/xsd</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>


My classes:

...
public class Project {
...



Reply | Threaded
Open this post in threaded view
|

Re: Schemagen generating ignoring <outputDirectory> when <transformSchemas> present.

Anders Hammar
But it's better to use trunk instead of the tag.

/Anders


On Mon, May 27, 2013 at 5:33 PM, Miguel Garz <[hidden email]> wrote:
Hi people,
I'm actually looking into the plugin code, and I think I might fix it.
Is it a possibility to download the source code and build the plugin locally?
Any help?
Thanks,
Miguel Garz


On Mon, May 27, 2013 at 3:07 PM, Miguel Garz <[hidden email]> wrote:
Good morning/afternoon everybody.
I'm having some problem with the mojo-Jaxb plugin.
What's happening is that I configured the plugin to output the schemas to a specific folder,
that works fine, unless I use the <transformSchemas> tag to configure the schema name.
In this case, what happens is that the schemas are generated, without the correct name, but in the standard folder (not the one in the <outputDirectory>).
Below is my maven pom configuration and also a excerpt of my code (with the annotations),
Would someone know what I'm doing wrong or if it is a bug on the plugin?
Thanks,
Miguel Garz

My pom:

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>jaxb2-maven-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<phase>generate-resources</phase>
<id>schemagen</id>
<goals>
<goal>schemagen</goal>
</goals>
<configuration>
<verbose>true</verbose>
<transformSchemas>
<transformSchema>
<toPrefix>rid</toPrefix>
<toFile>ri6-ws-domain</toFile>
</transformSchema>
</transformSchemas>
<includes>
<include>com/delagelanden/rijee6/domain/*.java</include>
</includes>
<outputDirectory>${basedir}/../schema/src/main/xsd</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>


My classes:

...
public class Project {
...