18
18
*/
19
19
package org .apache .polaris .core .persistence ;
20
20
21
- import com .fasterxml .jackson .core .JsonProcessingException ;
22
- import com .fasterxml .jackson .databind .JsonNode ;
23
- import com .fasterxml .jackson .databind .ObjectMapper ;
24
21
import jakarta .annotation .Nonnull ;
25
22
import java .util .ArrayList ;
26
23
import java .util .HashSet ;
@@ -69,7 +66,6 @@ public class PolarisTestMetaStoreManager {
69
66
70
67
// the start time
71
68
private final long testStartTime ;
72
- private final ObjectMapper objectMapper = new ObjectMapper ();
73
69
74
70
private final boolean supportsChangeTracking ;
75
71
@@ -1515,14 +1511,14 @@ public PolarisBaseEntity updateEntity(
1515
1511
Assertions .assertThat (afterUpdateEntity .getGrantRecordsVersion ()).isEqualTo (grantRecsVersion );
1516
1512
1517
1513
// update should have been performed
1518
- Assertions .assertThat (jsonNode ( updatedEntity .getProperties () ))
1519
- .isEqualTo (jsonNode ( updatedPropEntity .getProperties () ));
1520
- Assertions .assertThat (jsonNode ( afterUpdateEntity .getProperties () ))
1521
- .isEqualTo (jsonNode ( updatedPropEntity .getProperties () ));
1522
- Assertions .assertThat (jsonNode ( updatedEntity .getInternalProperties () ))
1523
- .isEqualTo (jsonNode ( updatedPropEntity .getInternalProperties () ));
1524
- Assertions .assertThat (jsonNode ( afterUpdateEntity .getInternalProperties () ))
1525
- .isEqualTo (jsonNode ( updatedPropEntity .getInternalProperties () ));
1514
+ Assertions .assertThat (updatedEntity .getPropertiesAsMap ( ))
1515
+ .isEqualTo (updatedPropEntity .getPropertiesAsMap ( ));
1516
+ Assertions .assertThat (afterUpdateEntity .getPropertiesAsMap ( ))
1517
+ .isEqualTo (updatedPropEntity .getPropertiesAsMap ( ));
1518
+ Assertions .assertThat (updatedEntity .getInternalPropertiesAsMap ( ))
1519
+ .isEqualTo (updatedPropEntity .getInternalPropertiesAsMap ( ));
1520
+ Assertions .assertThat (afterUpdateEntity .getInternalPropertiesAsMap ( ))
1521
+ .isEqualTo (updatedPropEntity .getInternalPropertiesAsMap ( ));
1526
1522
1527
1523
// lookup the tracking slice to verify this has been updated too
1528
1524
if (supportsChangeTracking ) {
@@ -1542,17 +1538,6 @@ public PolarisBaseEntity updateEntity(
1542
1538
return updatedEntity ;
1543
1539
}
1544
1540
1545
- private JsonNode jsonNode (String json ) {
1546
- if (json == null ) {
1547
- return null ;
1548
- }
1549
- try {
1550
- return objectMapper .readTree (json );
1551
- } catch (JsonProcessingException e ) {
1552
- throw new RuntimeException (e );
1553
- }
1554
- }
1555
-
1556
1541
/** Execute a list operation and validate the result */
1557
1542
private void validateListReturn (
1558
1543
List <PolarisEntityCore > path ,
0 commit comments