Commit 02c9ce7
authored
Deprecate APM\Command::getServer(), add getPort and getHost instead (#2773)
CommandSucceededEvent|CommandFailedEvent::getServer() has been deprecated in ext-mongodb 1.20 and removed in 2.0.0.
For backward compatibility: we keep this method in MongoDB ODM, but throw an exception the extension is not compatible. I'm not adding a trigger_deprecation as this is already triggered by the extension method call.
The new methods getPort() and getHost() are added as proxy to extension methods that are always available in the required ext-mongodb 1.21+.
This is not covered by tests, I can add tests on CommandLogger before merging.1 parent 3783f0e commit 02c9ce7
1 file changed
+17
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| 14 | + | |
| 15 | + | |
14 | 16 | | |
15 | 17 | | |
16 | 18 | | |
| |||
70 | 72 | | |
71 | 73 | | |
72 | 74 | | |
| 75 | + | |
73 | 76 | | |
74 | 77 | | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
75 | 82 | | |
76 | 83 | | |
77 | 84 | | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
78 | 95 | | |
79 | 96 | | |
80 | 97 | | |
| |||
0 commit comments