summaryrefslogtreecommitdiff
path: root/devel/ice/files/patch-cpp-src-IceStorm-TopicI.cpp
blob: b647892a57720eaadd931fb6f0beab4d305fe41d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
--- cpp.orig/src/IceStorm/TopicI.cpp	2011-06-15 21:43:58.000000000 +0200
+++ cpp/src/IceStorm/TopicI.cpp	2012-09-12 22:14:00.000000000 +0200
@@ -666,7 +666,7 @@ TopicImpl::subscribe(const QoS& origQoS, const Ice::ObjectPrx& obj)
         {
             try
             {
-                DatabaseConnectionPtr connection = _databaseCache->getConnection();
+                DatabaseConnectionPtr connection = _databaseCache->newConnection();
                 TransactionHolder txn(connection);
 
                 SubscriberRecordKey key;
@@ -703,7 +703,7 @@ TopicImpl::subscribe(const QoS& origQoS, const Ice::ObjectPrx& obj)
     {
         try
         {
-            DatabaseConnectionPtr connection = _databaseCache->getConnection();
+            DatabaseConnectionPtr connection = _databaseCache->newConnection();
             TransactionHolder txn(connection);
 
             SubscriberRecordKey key;
@@ -788,7 +788,7 @@ TopicImpl::subscribeAndGetPublisher(const QoS& qos, const Ice::ObjectPrx& obj)
     {
         try
         {
-            DatabaseConnectionPtr connection = _databaseCache->getConnection();
+            DatabaseConnectionPtr connection = _databaseCache->newConnection();
             TransactionHolder txn(connection);
 
             SubscriberRecordKey key;
@@ -912,7 +912,7 @@ TopicImpl::link(const TopicPrx& topic, Ice::Int cost)
     {
         try
         {
-            DatabaseConnectionPtr connection = _databaseCache->getConnection();
+            DatabaseConnectionPtr connection = _databaseCache->newConnection();
             TransactionHolder txn(connection);
 
             SubscriberRecordKey key;
@@ -1311,7 +1311,7 @@ TopicImpl::observerAddSubscriber(const LogUpdate& llu, const SubscriberRecord& r
     {
         try
         {
-            DatabaseConnectionPtr connection = _databaseCache->getConnection();
+            DatabaseConnectionPtr connection = _databaseCache->newConnection();
             TransactionHolder txn(connection);
 
             SubscriberRecordKey key;
@@ -1380,7 +1380,7 @@ TopicImpl::observerRemoveSubscriber(const LogUpdate& llu, const Ice::IdentitySeq
     {
         try
         {
-            DatabaseConnectionPtr connection = _databaseCache->getConnection();
+            DatabaseConnectionPtr connection = _databaseCache->newConnection();
             TransactionHolder txn(connection);
 
             for(Ice::IdentitySeq::const_iterator id = ids.begin(); id != ids.end(); ++id)
@@ -1456,7 +1456,7 @@ TopicImpl::destroyInternal(const LogUpdate& origLLU, bool master)
     {
         try
         {
-            DatabaseConnectionPtr connection = _databaseCache->getConnection();
+            DatabaseConnectionPtr connection = _databaseCache->newConnection();
             TransactionHolder txn(connection);
 
             // Erase all subscriber records and the topic record.
@@ -1531,7 +1531,7 @@ TopicImpl::removeSubscribers(const Ice::IdentitySeq& ids)
     {
         try
         {
-            DatabaseConnectionPtr connection = _databaseCache->getConnection();
+            DatabaseConnectionPtr connection = _databaseCache->newConnection();
             TransactionHolder txn(connection);
 
             for(Ice::IdentitySeq::const_iterator id = ids.begin(); id != ids.end(); ++id)