File tree Expand file tree Collapse file tree 1 file changed +2
-8
lines changed Expand file tree Collapse file tree 1 file changed +2
-8
lines changed Original file line number Diff line number Diff line change @@ -117,7 +117,7 @@ public function acquire(SessionConfiguration $config): Generator
117
117
$ key = $ this ->createKey ($ this ->data , $ config );
118
118
119
119
/** @var RoutingTable|null */
120
- $ table = $ this ->cache ->get ($ key, null );
120
+ $ table = $ this ->cache ->get ($ key );
121
121
$ triedAddresses = [];
122
122
123
123
$ latestError = null ;
@@ -130,13 +130,7 @@ public function acquire(SessionConfiguration $config): Generator
130
130
foreach ($ addresses as $ address ) {
131
131
$ triedAddresses [] = $ address ;
132
132
133
- $ uri = Uri::create ($ address );
134
- $ port = $ this ->data ->getUri ()->getPort ();
135
- if ($ port !== null ) {
136
- $ uri = $ uri ->withPort ($ port );
137
- }
138
-
139
- $ pool = $ this ->createOrGetPool ($ uri );
133
+ $ pool = $ this ->createOrGetPool ($ this ->data ->getUri ()->withHost ($ address ));
140
134
try {
141
135
/** @var BoltConnection $connection */
142
136
$ connection = GeneratorHelper::getReturnFromGenerator ($ pool ->acquire ($ config ));
You can’t perform that action at this time.
0 commit comments