|
4 | 4 |
|
5 | 5 | use Exception; |
6 | 6 | use GuzzleHttp\Client; |
7 | | -use GuzzleHttp\Exception\GuzzleException; |
8 | | -use GuzzleHttp\Exception\RequestException; |
9 | 7 | use Neo4j\QueryAPI\Objects\ProfiledQueryPlanArguments; |
10 | 8 | use Neo4j\QueryAPI\Objects\ResultCounters; |
11 | 9 | use Neo4j\QueryAPI\Objects\ProfiledQueryPlan; |
@@ -145,34 +143,34 @@ private function createProfileData(array $data): ProfiledQueryPlan |
145 | 143 | } |
146 | 144 |
|
147 | 145 | $queryArguments = new ProfiledQueryPlanArguments( |
148 | | - $mappedArguments['GlobalMemory'], |
149 | | - $mappedArguments['planner-impl'], |
150 | | - $mappedArguments['memory'], |
151 | | - $mappedArguments['string-representation'], |
152 | | - $mappedArguments['runtime'] ?? null, |
153 | | - $mappedArguments['Time'], |
154 | | - is_int($mappedArguments['PageCacheMisses']), |
155 | | - is_int($mappedArguments['PageCacheHits']), |
156 | | - $mappedArguments['runtime-impl'], |
157 | | - $mappedArguments['version'], |
158 | | - is_int($mappedArguments['DbHits']), |
159 | | - $mappedArguments['batch-size'], |
160 | | - is_string($mappedArguments['Details']), |
161 | | - $mappedArguments['planner-version'], |
162 | | - is_string($mappedArguments['PipelineInfo']), |
163 | | - $mappedArguments['runtime-version'], |
164 | | - is_int($mappedArguments['Id']), |
165 | | - (float)($mappedArguments['EstimatedRows'] ?? 0.0), |
166 | | - is_string($mappedArguments['planner'] ? $mappedArguments['planner'] : json_encode($mappedArguments['planner'])), |
167 | | - is_int($mappedArguments['Rows']) |
| 146 | + globalMemory: $mappedArguments['GlobalMemory'] ?? null, |
| 147 | + plannerImpl: $mappedArguments['planner-impl'] ?? null, |
| 148 | + memory: $mappedArguments['Memory'] ?? null, |
| 149 | + stringRepresentation: $mappedArguments['string-representation'] ?? null, |
| 150 | + runtime: $mappedArguments['runtime'] ?? null, |
| 151 | + time: $mappedArguments['Time'] ?? null, |
| 152 | + pageCacheMisses: $mappedArguments['PageCacheMisses'] ?? null, |
| 153 | + pageCacheHits: $mappedArguments['PageCacheHits'] ?? null, |
| 154 | + runtimeImpl: $mappedArguments['runtime-impl'] ?? null, |
| 155 | + version: $mappedArguments['version'] ?? null, |
| 156 | + dbHits: $mappedArguments['DbHits'] ?? null, |
| 157 | + batchSize: $mappedArguments['batch-size'] ?? null, |
| 158 | + details: $mappedArguments['Details'] ?? null, |
| 159 | + plannerVersion: $mappedArguments['planner-version'] ?? null, |
| 160 | + pipelineInfo: $mappedArguments['PipelineInfo'] ?? null, |
| 161 | + runtimeVersion: $mappedArguments['runtime-version'] ?? null, |
| 162 | + id: $mappedArguments['Id'] ?? null, |
| 163 | + estimatedRows: $mappedArguments['EstimatedRows'] ?? null, |
| 164 | + planner: $mappedArguments['planner'] ?? null, |
| 165 | + rows: $mappedArguments['Rows' ?? null] |
168 | 166 | ); |
169 | 167 |
|
170 | 168 |
|
171 | 169 | $profiledQueryPlan = new ProfiledQueryPlan( |
172 | 170 | $data['dbHits'], |
173 | 171 | $data['records'], |
174 | 172 | $data['hasPageCacheStats'], |
175 | | - $data['PageCacheHits'], |
| 173 | + $data['pageCacheHits'], |
176 | 174 | $data['pageCacheMisses'], |
177 | 175 | $data['pageCacheHitRatio'], |
178 | 176 | $data['time'], |
|
0 commit comments