Set descriptor property replacement setting in jboss-web.xml?

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

Set descriptor property replacement setting in jboss-web.xml?

arjan.tijms
Hi,

I wonder if it would make sense to be able to set the "spec-descriptor-property-replacement" from standalone.xml in jboss-web.xml (or other jboss specific files for e.g. a .ear)?

This is one of the few settings that we always need to change and it prevents devs using a stock JBoss/WildFly to deploy most of our applications to. Would be really great if this could be switched from within the application archive.

Kind regards,
Arjan Tijms



_______________________________________________
wildfly-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/wildfly-dev
Reply | Threaded
Open this post in threaded view
|

Re: Set descriptor property replacement setting in jboss-web.xml?

Tomaž Cerar-2
That is more of an chicken and egg problem.

Descriptors such as jboss-web.xml / jboss-deployment-structure.xml / jboss-all.xml /... 
get parsed differently based on how spec-descriptor-property-replacment / jboss-descriptor-property-replacement are configured.
So to enable that as part of such descriptor would kinda defy the whole purpose of it.

what is your most common use case of what are you replacing in spec descriptors?

--
tomaz

On Mon, Aug 8, 2016 at 3:11 PM, arjan tijms <[hidden email]> wrote:
Hi,

I wonder if it would make sense to be able to set the "spec-descriptor-property-replacement" from standalone.xml in jboss-web.xml (or other jboss specific files for e.g. a .ear)?

This is one of the few settings that we always need to change and it prevents devs using a stock JBoss/WildFly to deploy most of our applications to. Would be really great if this could be switched from within the application archive.

Kind regards,
Arjan Tijms



_______________________________________________
wildfly-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/wildfly-dev


_______________________________________________
wildfly-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/wildfly-dev
Reply | Threaded
Open this post in threaded view
|

Re: Set descriptor property replacement setting in jboss-web.xml?

arjan.tijms
Hi,

I wouldn't expect in this case that jboss-web.xml / jboss-deployment-structure.xml / jboss-all.xml /...  get parsed differently, just the actual spec descriptors like web.xml, persistence.xml etc.

The most common use case for this is a couple of context-params in web.xml, e.g.

<context-param>
   <param-name>javax.faces.FACELETS_REFRESH_PERIOD</param-name>
   <param-value>${facelets.refresh:-1}</param-value>
</context-param>

<context-param>
   <param-name>javax.faces.PROJECT_STAGE</param-name>
   <param-value>${project.stage:Production}</param-value>
</context-param>

And a couple of properties in persistence.xml, e.g.

<property name="hibernate.show_sql" value="${hibernate.show.sql:false}" />
<property name="hibernate.format_sql" value="${hibernate.format.sql:false}" />
<property name="hibernate.use_sql_comments" value="${hibernate.comment.sql:true}" />

There are a few more things depending on the project, but this is what nearly every one of them uses.

Kind regards,
Arjan Tijms




On Mon, Aug 8, 2016 at 3:26 PM, Tomaž Cerar <[hidden email]> wrote:
That is more of an chicken and egg problem.

Descriptors such as jboss-web.xml / jboss-deployment-structure.xml / jboss-all.xml /... 
get parsed differently based on how spec-descriptor-property-replacment / jboss-descriptor-property-replacement are configured.
So to enable that as part of such descriptor would kinda defy the whole purpose of it.

what is your most common use case of what are you replacing in spec descriptors?

--
tomaz

On Mon, Aug 8, 2016 at 3:11 PM, arjan tijms <[hidden email]> wrote:
Hi,

I wonder if it would make sense to be able to set the "spec-descriptor-property-replacement" from standalone.xml in jboss-web.xml (or other jboss specific files for e.g. a .ear)?

This is one of the few settings that we always need to change and it prevents devs using a stock JBoss/WildFly to deploy most of our applications to. Would be really great if this could be switched from within the application archive.

Kind regards,
Arjan Tijms



_______________________________________________
wildfly-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/wildfly-dev



_______________________________________________
wildfly-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/wildfly-dev
Reply | Threaded
Open this post in threaded view
|

Re: Set descriptor property replacement setting in jboss-web.xml?

Stuart Douglas
In reply to this post by arjan.tijms
Adding it to jboss-web.xml would not really work, however this could probably be made to work as an attribute (or two attributes) on the root element of jboss-all.xml.

Otherwise it would probably have to be some kind of separate file, as the current code base expects this to be known before any descriptors are actually parsed.

Stuart

On Mon, Aug 8, 2016 at 11:11 PM, arjan tijms <[hidden email]> wrote:
Hi,

I wonder if it would make sense to be able to set the "spec-descriptor-property-replacement" from standalone.xml in jboss-web.xml (or other jboss specific files for e.g. a .ear)?

This is one of the few settings that we always need to change and it prevents devs using a stock JBoss/WildFly to deploy most of our applications to. Would be really great if this could be switched from within the application archive.

Kind regards,
Arjan Tijms



_______________________________________________
wildfly-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/wildfly-dev


_______________________________________________
wildfly-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/wildfly-dev