Updating maps API services
Updating MapGL JS services API
-
Make sure that a newer version of MapGL JS API service exists in the Docker Registry. See On-Premise releases.
-
Update settings in the
values-mapgl.yaml
configuration file, if necessary. See the example in the installation instructions. -
Run the command to update the service:
helm upgrade --version=1.4.5 --atomic --values ./values-mapgl.yaml mapgl-js-api 2gis-on-premise/mapgl-js-api
Updating Tiles API services
You can update the Tiles API service with or without simultaneously updating its data (the tiles themselves).
-
Make sure that a newer version of Tiles API service exists in the Docker Registry. See On-Premise releases.
If you are going to update data as well, make sure that the artifacts storage contains the newer dataset. See Installation artifacts lifecycle.
-
Update settings in the
values-tiles.yaml
configuration file, if necessary. See the example in the installation instructions. -
Run the command to update the service:
-
To update the service only:
helm upgrade --version=1.4.5 --atomic --values ./values-tiles.yaml tiles-api 2gis-on-premise/tiles-api --set importer.enabled=false
-
To update both the service and the data:
helm upgrade --version=1.4.5 --atomic --values ./values-tiles.yaml tiles-api 2gis-on-premise/tiles-api
After each update, the newly downloaded tiles are stored in a new Cassandra keyspace. The name of the keyspace is constructed based on:
- the data type (
web
orraster
), - the Cassandra cluster name,
- the Unix time when the manifest was generated.
Keyspace name example:
dgis_tileserver_web_test_1653477379
.All the data in an older keyspace become obsolete after a successful switch to a new keyspace. It is recommended to remove older keyspaces to free up disk space. You can do this automatically as follows:
-
Set the
importer.cleaner.enabled
setting totrue
. -
Set the
importer.cleaner.limit
setting to the amount of old keyspaces to keep. For example,1
means that only one obsolete keyspace will be kept while all older ones will be deleted. Note that it is not permitted to set the limit lower than1
, as this would result in deletion of the current keyspace at the time of runninghelm upgrade
. -
By default, the deleted data will still occupy disk space as a Cassandra table snapshot. You can delete the obsolete snapshots manually by using nodetool clearsnapshot, or you can configure automatic deletion via JMX:
- Make sure that remote JMX access is enabled in your Cassandra configuration.
- Set the
cassandra.credentials.jmxUser
andcassandra.credentials.jmxPassword
values. - Set the
importer.clearSnapshots
value totrue
.
- the data type (