diff options
| author | Arnaud Simon <arnaudsimon@apache.org> | 2007-11-13 10:57:46 +0000 |
|---|---|---|
| committer | Arnaud Simon <arnaudsimon@apache.org> | 2007-11-13 10:57:46 +0000 |
| commit | 0ce22df53e824db1be3987a966ac56f99c4bb9b6 (patch) | |
| tree | 2c650c0552995dce83b29435d6046c5900e628e3 | |
| parent | f157d23910e7b3e4d35d6458d10ad8ea0cf9900b (diff) | |
| download | qpid-python-0ce22df53e824db1be3987a966ac56f99c4bb9b6.tar.gz | |
Changed to use initial context helper
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk@594482 13f79535-47bb-0310-9956-ffa450edef68
| -rw-r--r-- | qpid/java/perftests/src/main/java/org/apache/qpid/requestreply/PingPongProducer.java | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/qpid/java/perftests/src/main/java/org/apache/qpid/requestreply/PingPongProducer.java b/qpid/java/perftests/src/main/java/org/apache/qpid/requestreply/PingPongProducer.java index c3689151d2..da6d6eb7d0 100644 --- a/qpid/java/perftests/src/main/java/org/apache/qpid/requestreply/PingPongProducer.java +++ b/qpid/java/perftests/src/main/java/org/apache/qpid/requestreply/PingPongProducer.java @@ -669,12 +669,9 @@ public class PingPongProducer implements Runnable, ExceptionListener // _log.debug("protected void createConnection(String clientID = " + clientID + "): called");
// _log.debug("Creating a connection for the message producer.");
- File propsFile = new File(_fileProperties);
- InputStream is = new FileInputStream(propsFile);
- Properties properties = new Properties();
- properties.load(is);
+
- Context context = new InitialContext(properties);
+ Context context = InitialContextHelper.getInitialContext(_fileProperties);
ConnectionFactory factory = (ConnectionFactory) context.lookup(_factoryName);
_connection = factory.createConnection(_username, _password);
|
