|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Handling of configuration in WMB |
« View previous topic :: View next topic » |
Author |
Message
|
4integration |
Posted: Thu Jan 10, 2008 1:36 pm Post subject: Handling of configuration in WMB |
|
|
 Disciple
Joined: 04 Sep 2006 Posts: 197 Location: Gothenburg, Sweden
|
Hello,
We have several WMB environments (DEV, TEST, QA and PROD) and some of them in the same machine (Win2k3).
We have need for different configuration per environment type, e.g. we are using a database connection (ODBC) that is different per environment. Since we have several different ODBC configurations on the same machine we must use different names for DSNs.
Also we do not want to rebuild BAR files between different environments.
How do you handle configurations and do you have some recommendations? _________________ Best regards
4 Integration |
|
Back to top |
|
 |
jefflowrey |
Posted: Thu Jan 10, 2008 4:50 pm Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
There is a presupplied command - mqsiapplybaroverrides - that comes with v6 and later.
This doesn't rebuild the bar file, it merely adjusts the broker.xml file.
There are various other solutions available... depending on who you ask and in what context...
A number of people have done things with Ant to, for example, check projects out of version control, build a bar file, apply appropriate overrides, and then deploy - all automatically.
This has generally proven to be trickier than expected, at least at the v6 level. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
4integration |
Posted: Fri Jan 11, 2008 12:56 am Post subject: |
|
|
 Disciple
Joined: 04 Sep 2006 Posts: 197 Location: Gothenburg, Sweden
|
Ok, thanks...
Is it possible to have broker global variables? E.g. setting a variable that classifies the broker environment as TEST and that variable are readable from compute nodes?? _________________ Best regards
4 Integration |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Jan 11, 2008 5:51 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Not as such.
That doesn't mean it's not trivial to do. It's just not done in a way that looks like "global variable".
It's also a really bad idea. You end up having to hardcode DSN names into your flows, and otherwise removing most of the functionality that the deployment descriptor provides you in the first place.
Use the BAR File Editor, mqsiapplybarfileoverrides, or etc. to adjust the deployment descriptor before deploying your code to different environments.
You need to have a different procedure for deploying to production than to development anyway, so you might as well have the production process include this step. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
4integration |
Posted: Fri Jan 11, 2008 6:54 am Post subject: |
|
|
 Disciple
Joined: 04 Sep 2006 Posts: 197 Location: Gothenburg, Sweden
|
jefflowrey wrote: |
...
It's also a really bad idea. You end up having to hardcode DSN names into your flows, and otherwise removing most of the functionality that the deployment descriptor provides you in the first place.
... |
That's exactly what we want to avoid Today we have a component that have hardcoded DSN and i our new environment that problem have been discovered.
Therefore we want to use a configuration mechanism so the components will depend on keys, not the values(such as DSN names). _________________ Best regards
4 Integration |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Jan 11, 2008 7:26 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Right - the BAR file editor can be used to edit the Deployment Descriptor manually.
The mqsiapplybaroverride command can be used to edit the Deployment Descriptor in an automatic fashion.
You can use User Defined Properties, that can be set in the Deployment Descriptor, in those places in your code where you need a configurable value that is not a node property that is already exposed to the deployment descriptor. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|