In the jms-destination.xml in SAP NetWeaver 2004 and SAP NetWeaver 2004s There Is a User/Password Tags. When Should I Use Them?
The username and password elements in jms-destinations.xml are optional. They have the same semantics as the respective elements in jms-factories.xml, but, if supplied, the destination ones override the factory ones. When the application is started, the descriptors are parsed, and the JMS Connector creates the required destinations using the standard JMS API calls (createConnection, createQueue/createTopic). In case username and password have been supplied in the descriptors, the JMS Connector will pass these as parameters to the createConnection invocation; otherwise createConnection will be invoked without parameters. Note that these username and password of the jms-destinations.xml are used only during application startup. Then, it is up to the applications JMS logic how the destinations will be accessed by creating connection with or without supplying username and password. Moreover, the username and password passed may be different than the ones provided in the applications descri