-
1. Re: How to write on standalone.xml permanently?
wdfink Jul 25, 2012 6:49 AM (in response to nill)All files in *_history are not to be used in general, these are only saved snapshots of the configuration.
If you want change the configuration i is recommended to use the management interface (CLI and web-console).
You might change the standalone-full.xml by hand.
-
2. Re: How to write on standalone.xml permanently?
nill Jul 25, 2012 7:12 AM (in response to wdfink)"You might change the standalone-full.xml by hand."
- That is what not happening ! Whatever new things I write in that file just vanishes as soon as I start the server. I will be too glad if those changes remain.
That is why started to write on all the standalone-full.xml versions I could lay hand on. Even when i did it, JBoss, it seems, has a hidden copy and replacing my new file with that one as soon as it starts.
-
3. Re: How to write on standalone.xml permanently?
wdfink Jul 25, 2012 7:15 AM (in response to nill)1 of 1 people found this helpfulI don't see that in my environment.
What version do you use?
Maybe start with a fresh Instance and change only one thing and check it.
Also how do you start the JBoss?
-
4. Re: How to write on standalone.xml permanently?
nill Jul 25, 2012 7:43 AM (in response to wdfink)I am using JBoss AS 7.1.1 Brontes. I start it from eclipse.
I am managing the situation now in a very strange way.
Each time I have to do a change, i rename the existing JBoss, then I unpack JBoss into existing path and copy all the modules I need from old location, use the intended standalone-full.xml with new changes and then it works. But it is really cumbersome !
-
5. Re: How to write on standalone.xml permanently?
nill Jul 25, 2012 8:17 AM (in response to nill)I think I have resolved my problem.
*For those beginners who may be facing this problem like me, the solution is to delete everything under the directory standalone_xml_history.
Thanks to Wolf-Dieter Fink for the assistance,
-
6. Re: How to write on standalone.xml permanently?
pmerson Aug 30, 2012 1:45 PM (in response to nill)Removing history doesn't always work!
I'm having the same kind of problem: upon startup AS 7.1.0.Final removes a segment I added to standalone-full.xml. More specifically, the <jms-connection-factories> definition inside the <subsystem xmlns="urn:jboss:domain:messaging:1.1"> definition is yanked out.
I tried (in order):
1) Deleting contents under the standalone_xml_history directory.
2) Deleting the standalone_xml_history directory.
3) Deleting contents under the standalone-full_xml_history directory.
4) Deleting the standalone-full_xml_history directory.
And no success. AS 7.1 is still silently "doctoring" my standalone-full.xml. Interesting thing is that the connection factory I define in the section that is removed works. But then, if I bounce the server it won't be there anymore.
-
7. Re: How to write on standalone.xml permanently?
wdfink Aug 31, 2012 5:03 AM (in response to pmerson)This sounds like a bug.
Do you have checked the xsd of the subsystem that the config is correct (I suppose yes because you say it works)
Could you try the latest AS7.2.x upstream from git or nightly builds to retest?
-
8. Re: How to write on standalone.xml permanently?
pmerson Sep 3, 2012 1:16 PM (in response to wdfink)I found some related issues:
- https://issues.jboss.org/browse/AS7-3170
- https://issues.jboss.org/browse/AS7-3442
- https://issues.jboss.org/browse/AS7-2830
- https://issues.jboss.org/browse/AS7-649
But I also believe it's a new bug. My bad luck is that this bug hampers the workaround for another bug described here.
I was testing with AS 7.1 on my local machine, but my organization has JBoss EAP on all server machines.
I installed EAP 6.0 locally and observed the exact same problem.
What is the github URL for the latest AS 7.2.x upstream?
-
9. Re: How to write on standalone.xml permanently?
pmerson Sep 5, 2012 2:26 PM (in response to pmerson)I downloaded and built the latest version (jboss-as-7.2.0.Alpha1-SNAPSHOT) from github.com/jbossas/jboss-as.git. The same problem is still there.
The edits to standalone-full.xml that are erased by this automatic rewrite are needed for MDBs to consume messages from a remote HornetQ server. My next attempt is to go back to EAP 5.1.
-
10. Re: How to write on standalone.xml permanently?
jmesnil Sep 11, 2012 5:07 AM (in response to pmerson)Paulo Merson wrote:
The edits to standalone-full.xml that are erased by this automatic rewrite are needed for MDBs to consume messages from a remote HornetQ server. My next attempt is to go back to EAP 5.1.
What's exactly the edits you're doing to standalone-full.xml? I am not able to reproduce this issue and don't see any automatic rewrites.
-
11. Re: How to write on standalone.xml permanently?
pmerson Sep 11, 2012 2:15 PM (in response to jmesnil)1) I changed the messaging subsystem definition to:
{code:xml}
<subsystem xmlns="urn:jboss:domain:messaging:1.1">
<hornetq-server>
<persistence-enabled>false</persistence-enabled>
<connectors>
<netty-connector name="netty-remote" socket-binding="remote-messaging"/>
</connectors>
<jms-connection-factories>
<pooled-connection-factory name="myhornetq-ra">
<transaction mode="xa"/>
<connectors>
<connector-ref connector-name="netty-remote"/>
</connectors>
<entries>
<entry name="java:/JmsXA"/>
</entries>
</pooled-connection-factory>
</jms-connection-factories>
</hornetq-server>
</subsystem>
{code}
2) I added the following socket binding:
{code:xml}
<socket-binding name="remote-messaging" port="5446"/>
{code}
3) I had also added datasource definitions that are unrelated to this problem and were working fine before.
The automatic rewrite changes the messaging subsystem definition to:
{code:xml}
<subsystem xmlns="urn:jboss:domain:messaging:1.1">
<hornetq-server>
<persistence-enabled>false</persistence-enabled>
<connectors>
<netty-connector name="netty-remote" socket-binding="remote-messaging"/>
</connectors>
</hornetq-server>
</subsystem>
{code}
I observed the same problem on AS 7.1.0 Final and 7.2.0.Alpha1-SNAPSHOT. The only difference is that AS 7.1.0 has messaging:1.1 and 7.2.0 has messaging:1.3.
-
12. Re: How to write on standalone.xml permanently?
jmesnil Sep 12, 2012 5:56 AM (in response to pmerson)thanks paulo, this was indeed a bug: https://issues.jboss.org/browse/AS7-5538
I have created patches for both AS7 7.1 and 7.2 branches. In the mean time, you can work around this issue by adding a *connection-factory* to the messaging subsystem to ensure that the *pooled-connection-factory* are correctly persisted:
<subsystem xmlns="urn:jboss:domain:messaging:1.1">
<hornetq-server>
<persistence-enabled>false</persistence-enabled>
<connectors>
<netty-connector name="netty-remote" socket-binding="remote-messaging"/>
</connectors>
<jms-connection-factories>
<connection-factory name="dummyCF">
<connectors>
<connector-ref connector-name="netty-remote"/>
</connectors>
<entries>
<entry name="java:jboss/exported/jms/dummyCF"/>
</entries>
</connection-factory>
<pooled-connection-factory name="myhornetq-ra">
<transaction mode="xa"/>
<connectors>
<connector-ref connector-name="netty-remote"/>
</connectors>
<entries>
<entry name="java:/JmsXA"/>
</entries>
</pooled-connection-factory>
</jms-connection-factories>
</hornetq-server>
</subsystem>
I'll now work on making sure that remote MDB works without adding the whole messaging subsystem...
-
13. Re: How to write on standalone.xml permanently?
pmerson Sep 13, 2012 5:21 PM (in response to jmesnil)Just confirming that the addition of the dummy <connection-factory> prevented the rewrite on my AS 7 environment. Thank you Jeff.