The recommendation from SAP for extension development is to use cloud application programming (CAP). In addition to data definition, it makes it queryable and writable over odata or rest protocol without coding. This is useful because the service can serve web applications, be exposed to internal applications, or even be associated with SAP API management to interface with customers and partners systems.
However great is CAP, geospatial data is often consumed differently. Visualization tools like qgis or dbeaver establish a direct connection to SAP HANA. GIS platforms like geoserver or Esri ArcGIS can publish data as layers over various web service protocols.
We came across a customer in the forest industry that needed to develop mutliple S/4 extensions and therefore would use CAP. They also needed to query, process and expose geospatial data. There requirements were:
{"ID": 1, "label": "Warehouse 1", "address": "okipii, Finland" }
HTTP/1.1 200 OK
OData-Version: 4.0
content-type: application/json;odata.metadata=minimal
Date: Tue, 07 Sep 2021 13:41:27 GMT
Connection: close
Content-Length: 297
{
"@odata.context": "$metadata#Warehouse/$entity",
"ID": 1,
"label": "Warehouse 1",
"surface": null,
"address": "okipii, Finland",
"geo_score": 0.99,
"geo_point": {
"type": "Point",
"coordinates": [
22.59858989715576,
62.495699882507324
]
},
"geo_city": "Kurikka",
"geo_county": "Etelä-Pohjanmaa",
"geo_country_iso3": "FIN"
}
### Harvesting block in a protected area during a specific season.
POST http://localhost:4004/forest/HarvestingBlock
Content-Type: application/json
{"ID":2,"dt":"2022-10-10","geom_as_wkt":"POLYGON ((23.77344846725464 61.42467889322534, 23.77394199371338 61.425407593025284, 23.77162456512451 61.426126012789695, 23.77134561538696 61.42581812063022, 23.771259784698486 61.425161273869925, 23.77145290374756 61.42508943041672, 23.77344846725464 61.42467889322534))"}
HTTP/1.1 500 Internal Server Error
OData-Version: 4.0
content-type: application/json;odata.metadata=minimal
Date: Tue, 07 Sep 2021 14:11:37 GMT
Connection: close
Content-Length: 138
{
"error": {
"code": "500",
"message": "Harvesting in this location and date infringes the sanctuary \"Little Trolls of the woods in Autumn\""
}
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
38 | |
25 | |
17 | |
13 | |
7 | |
7 | |
7 | |
7 | |
6 | |
6 |