Skip to content

Commit

Permalink
Merge pull request #2416 from telefonicaid/task/log_json_geometry
Browse files Browse the repository at this point in the history
add more info about errors when crateInstanceFromJson geometry
  • Loading branch information
fgalan authored Sep 25, 2024
2 parents d6e9e78 + a6d9cb3 commit 40a4c68
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 10 deletions.
4 changes: 2 additions & 2 deletions CHANGES_NEXT_RELEASE
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
- [cygnus-ngsi][arcgis] Log json geometry before create instance and in errors related
- [cygnus-common][arcgis] toString of complex geometry is not returning equivalent input (#2418)
- [cygnus-ngsi][arcgis] Log json geometry before create instance
- [cygnus-ngsi][arcgis] Fix CygnusRuntimeError due to Cannot invoke "java.util.List.size()" because "serverFeatures" is null (#2413)
- [cygnus-ngsi][arcgis] Fix CygnusRuntimeError due to Cannot invoke "java.util.List.size()" because "serverFeatures" is null (#2413)
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,8 @@ public static Geometry createInstanceFromJson(JsonObject json) throws ArcgisExce
try {
return new MultiPoint(json.get(POINTS_TAG).getAsString());
} catch (Exception e) {
LOGGER.error(e.getClass().getSimpleName() + " " + e.getMessage());
throw new ArcgisException("Unable to parse MultiPoint from json " + e.getMessage());
LOGGER.error(e.getClass().getSimpleName() + " error " + e.getMessage() + " parsing MultiPoint from json " + json);
throw new ArcgisException("Unable to parse MultiPoint from json " + json + " due to " + e.getMessage());
}

}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,8 @@ public static Geometry createInstanceFromJson(JsonObject json) throws ArcgisExce

return new Point(x, y, SpatialReference.WGS84);
} catch (Exception e) {
LOGGER.error(e.getClass().getSimpleName() + " " + e.getMessage());
throw new ArcgisException("Unable to parse Point from json " + e.getMessage());
LOGGER.error(e.getClass().getSimpleName() + " error " + e.getMessage() + " parsing Point from json " + json);
throw new ArcgisException("Unable to parse Point from json " + json + " due to " + e.getMessage());
}

}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,8 @@ public static Geometry createInstanceFromJson(JsonObject json) throws ArcgisExce
try {
return new PolyLine(json.get(PATHS_TAG).getAsString());
} catch (Exception e) {
LOGGER.error(e.getClass().getSimpleName() + " " + e.getMessage());
throw new ArcgisException("Unable to parse PolyLine from json " + e.getMessage());
LOGGER.error(e.getClass().getSimpleName() + " error " + e.getMessage() + " parsing PolyLine from json " + json);
throw new ArcgisException("Unable to parse PolyLine from json " + json + " due to " + e.getMessage());
}

}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,8 @@ public static Geometry createInstanceFromJson(JsonObject json) throws ArcgisExce
try {
return new Polygon(json.get(RINGS_TAG).getAsString());
} catch (Exception e) {
LOGGER.error(e.getClass().getSimpleName() + " " + e.getMessage());
throw new ArcgisException("Unable to parse Polygon from json " + e.getMessage());
LOGGER.error(e.getClass().getSimpleName() + " error " + e.getMessage() + " parsing Polygon from json " + json);
throw new ArcgisException("Unable to parse Polygon from json " + json + " due to " + e.getMessage());
}

}
Expand Down

0 comments on commit 40a4c68

Please sign in to comment.