[ openjms-Feature Requests-865685 ] Request JmsServer(Configuration) constructor

"SourceForge.net" <[email protected]> Thu, 06 May 2004 04:37:01 -0700
Newsgroups gmane.comp.java.openjms.devel
Message-ID <[email protected]>
Feature Requests item #865685, was opened at 2003-12-26 01:19
Message generated for change (Comment added) made by tanderson
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=474139&aid=865685&group_id=54559

>Category: enhancement
Group: None
Status: Closed
Priority: 5
Submitted By: Nathan Meyers (nathanmeyers)
>Assigned to: Tim Anderson (tanderson)
Summary: Request JmsServer(Configuration) constructor

Initial Comment:
This is a request to improve embeddability. I'd like to launch the server 
with a Configuration object built by means other than reading 
openjms.xml. This could be easily solved with an additional JmsServer 
constructor and ConfigurationManager.setConfig() capable of taking 
Configuration objects: 
 
JmsServer.java: 
 
public JmsServer(Configuration config) { 
    version(); 
    // initialise the configuration manager 
    ConfigurationManager.setConfig(config); 
    _config = config; 
} 
 
 
ConfigurationManager.java: 
 
public static synchronized void setConfig(Configuration config) { 
  _config = config; 
} 
 

----------------------------------------------------------------------

>Comment By: Tim Anderson (tanderson)
Date: 2004-05-06 21:37

Message:
Logged In: YES 
user_id=557161

Doh. Fixed in CVS. Fix will be available in the 0.7.6.1 release.

----------------------------------------------------------------------

Comment By: J Aaron Farr (jaaron_farr)
Date: 2004-05-06 12:13

Message:
Logged In: YES 
user_id=366739

There's a bug in the constructor.  The constructor is:

    public JmsServer(Configuration config) throws
ServerException {
        version();
        ConfigurationManager.setConfig(config);
    }

bug should be:
    
    public JmsServer(Configuration config) throws
ServerException {
        version();
        ConfigurationManager.setConfig(config);
        _config = config;
    }

Otherwise the inti(); method throws a null pointer exception
since the _config variable is never initialized.

----------------------------------------------------------------------

Comment By: Tim Anderson (tanderson)
Date: 2004-01-03 15:02

Message:
Logged In: YES 
user_id=557161

Checked into CVS. Changes will be available in the final 0.7.6 
release.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=474139&aid=865685&group_id=54559


-------------------------------------------------------
This SF.Net email is sponsored by Sleepycat Software
Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to deliver
higher performing products faster, at low TCO.
http://www.sleepycat.com/telcomwpreg.php?From=osdnemail3