Layers

The OLP CLI supports the following:

  • add a layer to a catalog
  • show a layer in a catalog
  • update a layer in a catalog
  • delete a layer in a catalog
  • inspect a layer in a catalog

catalog layer add

Adds the specified layer to a catalog.

Linux
Windows
olp catalog layer add <catalog HRN> <layer ID> <layer name> <layer type> \
   --summary <layer summary> --description <layer description> [command options]
olp catalog layer add <catalog HRN> <layer ID> <layer name> <layer type> ^
   --summary <layer summary> --description <layer description> [command options]

Required parameters:

  • <catalog HRN> The HRN of the catalog.
  • <layer ID> The ID of the layer to add.
  • <layer name> The human-readable name of the layer.
  • <layer type> The type of the layer, either --versioned, --volatile, --stream, or --index.
  • --summary <layer summary> A one-line summary of the layer contents.
  • --description <layer description> A detailed description of the catalog and its contents. Enclose the description with quotes.

Required parameters for an index layer:

  • --index-definitions <index-key-name:index-key-type[:duration][:zoom-level]> Index definitions of the layer:
    • index-key-name is the name used in the Query API to express the query predicate.
    • index-key-type describes the type of keys supported. Possible values are bool, int, string, heretile, or timewindow. duration represents the length of a tile slice timewindow key. zoom-level represents the heretile zoom level.

Optional parameters:

  • --content-type <layer data type> The content type of the layer, such as application/vnd.geo+json and text/plain. The default value is application/x-protobuf.
  • --content-encoding <encoding type> The content encoding of the layer, such as gzip. If this parameter is specified, all data in a layer is compressed by the specified algorithm. The default value is Uncompressed, which means no compression.
  • --tags <tag1 tag2 ..> Catalog keywords; used for search discovery.
  • --schema <schema HRN> An HRN of the data schema for this layer.
  • --billing-tags <tag1 tag2 ...> A list of billing tags. Used for search discovery.
  • --coverage <code1 code2 ...> A list of ISO 3166 two-letter codes for countries and regions. Optionally, followed by up to three characters codes for subdivisions, such as DE for Germany, PL for Poland, or CN-HK for Hong Kong, China. These codes must be separated by spaces.
  • --quiet Displays empty output with no additional information.
  • --scope <project HRN> Specifies the project HRN to use as the scope in the request. The value specified with --scope overrides any value for here.token.scope provided in the credentials file used for the command.

Optional parameters for a volatile layer:

  • --max-memory-policy The eviction policy of the layer.
  • --data-redundancy <single-instance|multi-instance> The data redundancy for the layer. Single-instance layers do not have data redundancy whereas multiple-instance layers do. Note that data redundancy is specific to volatile layers only and refers to data redundancy within a single region. For details on cost considerations, see Data Limits and Costs.
  • --storage-capacity <size in MB> The storage capacity of the layer specified in megabytes, with an increment step of 100 (for example 100, 500, 600, 2000).
    • Minimum value: 100 MB (100);
    • Maximum value: 21 GB (21000).
  • --ttl The layer's time-to-live or expiry time in milliseconds.
    • Maximum value: 7 days (604800000 ms);
    • Minimum value: 1 minute (60000 ms);
    • Default value: 1 hour (3600000 ms).
  • --digest <md5|sha-1|sha-256> The digest algorithm to use to calculate the checksum for the layer. Possible values are md5, sha-1, sha-256.
  • --partitioning <generic|heretile[:tilelevel1,tilelevel2...]> The partitioning scheme of the layer, either heretile or generic. For heretile, you can specify tile levels separated by a comma, such as heretile:level1,level2. The platform supports tile levels from 1 to 15. The default value is generic.
  • --crc <CRC-32C> The algorithm used to calculate a cyclic redundancy check; currently supported is only <CRC-32C> (case is ignored, you can use crc-32c).

Optional parameters for a stream layer:

It is recommended to provide all 3 properties that define the scale of the required streaming layer:

  • --data-in <size><KB|MB>
  • --data-out <size><KB|MB>
  • --parallelization <number of Kafka partitions>.

Either combination of --data-in and --data-out or --parallelization is required.

Note

The --data-in/--data-out parameters come to replace --data-in-mbps/--data-out-mbps as the more convenient and granular way to control stream layer throughput.

  • --data-in <size><KB|MB> The maximum throughput for incoming data in the layer.
    • Maximum value: 32MB (32,800 KBps maximum or 32,768 KBps rounded up to the nearest 100th);
    • Minimum value: 100KB (can only be multiple of 100 KBps);
    • Default value: 1MB, if no scale parameters are set; otherwise it is calculated by the HERE platform;
    • If the unit value is omitted the MB will be used by default;
  • --data-out <size><KB|MB> The maximum throughput for outgoing data in the layer.

    • Maximum value: 64MB (65,500 KBps maximum or 65,536 KBps rounded up to the nearest 100th);
    • Minimum value: 100KB (can only be multiple of 100 KBps);
    • Default value: 4MB, if no scale parameters are set; otherwise it is calculated by the HERE platform;
    • If the unit value is omitted the MB will be used by default;
  • --parallelization <number of Kafka partitions> A number of Kafka partitions for a stream layer. If this parameter is set, then the --data-in-mbps <size in Mbps>/--data-in <size><KB|MB> and --data-out-mbps <size in Mbps>/--data-out <size><KB|MB> parameters can be omitted and default values will be used.

    • Maximum value: 32;
    • Minimum value: 1;
    • Default value: 1, if no scale parameters are set; otherwise it is calculated by the HERE platform.
  • --ttl <time in ms> The layer's time-to-live or expiry time in milliseconds.
    • Maximum value: 72 hours (259200000 ms);
    • Minimum value: 10 minutes (600000 ms);
    • Default value: 1 hour (3600000 ms).

For more information on stream layer parameters, see Data Client Library Developer Guide.

Deprecated optional parameters for a stream layer:
  • --data-in-mbps <size in Mbps> The maximum throughput for incoming data in the layer. Now deprecated, --data-in should be used instead.
    • Maximum value: 32;
    • Minimum value: 1;
    • Default value: 1, if no scale parameters are set; otherwise it is calculated by the HERE platform.
  • --data-out-mbps <size in Mbps> The maximum throughput for outgoing data in the layer. Now deprecated, --data-out should be used instead.
    • Maximum value: 64;
    • Minimum value: 1;
    • Default value: 4, if no scale parameters are set; otherwise it is calculated by the HERE platform.

Optional parameters for a versioned layer:

  • --digest <md5|sha-1|sha-256> The digest algorithm to use to calculate the layer checksum. Possible values are md5, sha-1, or sha-256.
  • --partitioning <generic|heretile[:tilelevel1,tilelevel2...]> The partitioning scheme of the layer, either heretile or generic. For heretile you can specify tile levels separated by a comma, such as heretile:level1,level2. The platform supports tile levels from 1 to 15. The default value is generic.
  • --crc <CRC-32C> The algorithm used to calculate a cyclic redundancy check; currently supported is only <CRC-32C> (case is ignored, you can use crc-32c).

Optional parameters for an index layer:

  • --ttl <time in dd, mm, yy> The time-to-live or expiry time for the data in the index layer. Possible values are 7.days, 15.days, 1.month, 2.months, 3.months, 4.months, 5.months, 6.months, 1.year, 1.5.years, 2.years, and unlimited.
  • --crc <CRC-32C> The algorithm used to calculate a cyclic redundancy check; currently supported is only <CRC-32C> (case is ignored, you can use crc-32c).
  • --digest <md5|sha-1|sha-256> The digest algorithm used to calculate the checksum for the layer. Possible values are md5, sha-1, sha-256.

Example:

The command below adds a versioned layer with the ID new-layer to catalog1.

Linux
Windows
olp catalog layer add hrn:here-cn:data:::catalog1 new-layer new-layer-name \
   --versioned --summary "A summary"
olp catalog layer add hrn:here-cn:data:::catalog1 new-layer new-layer-name ^
   --versioned --summary "A summary"

Example:

The command below adds a versioned layer with the md5 digest, heretile partitioning, and tile levels to catalog1.

Linux
Windows
olp catalog layer add hrn:here-cn:data:::catalog1 new-layer new-layer-name \
   --versioned --partitioning heretile:7,10,14 --digest md5 --summary "A summary"
olp catalog layer add hrn:here-cn:data:::catalog1 new-layer new-layer-name ^
   --versioned --partitioning heretile:7,10,14 --digest md5 --summary "A summary"

catalog layer show

Displays the layer properties.

olp catalog layer show <catalog HRN> <layer ID> [command options]

Required parameters:

  • <catalog HRN> The HRN of the catalog.
  • <layer ID> The ID of the layer to show.

Optional parameters:

  • --credentials <path to credentials file> The name of a credentials file to use with the command. Credentials files are downloaded separately from the platform portal.
  • --json Displays results in JSON format.
  • --profile <profile name> The name of the credentials profile to use from the olpcli.ini file.
  • --quiet Displays the type of the layer and its partitioning scheme, separated by space.
  • --scope <project HRN> Specifies the project HRN to use as the scope in the request. The value specified with --scope overrides any value for here.token.scope provided in the credentials file used for the command.

For more information on using credentials and profiles, see Credentials Setup.

Example:

The command below displays the test-layer properties inside the test-catalog.


olp catalog layer show hrn:here-cn::data:::test-catalog test-layer --json

Output:

{
    "summary": "Summary",
    "volume": {"volumeType": "Durable"},
    "layerType": "Versioned",
    "billingTags": [],
    "crc": "CRC-32C",
    "name": "Test Layer",
    "description": "some description",
    "partitioning": {"scheme": "generic"},
    "id": "test-layer",
    "contentType": "application/octet-stream",
    "tags": []
}

catalog layer update

Updates the specified layer in the catalog.

olp catalog layer update <catalog HRN> <layer ID> [command options]

Warning: Risk of irrecoverable data inconsistency

The update of content type(--content-type), content encoding(--content-encoding), or content schema definition(--schema) for a layer with data in it can lead to irrecoverable data inconsistency. Any such changes could adversely impact downstream consumers of the data.

Required parameters:

  • <catalog HRN> The HRN of the catalog.
  • <layer ID> The ID of the layer to update.

Optional parameters:

  • --name <layer name> The human-readable name of the layer.
  • --summary <layer summary> A one-line summary of the layer contents.
  • --description <layer description> A detailed description of the catalog and its contents. Enclose the description with quotes.
  • --tags <tag1 tag2 ...> Catalog keywords used for search discovery.
  • --schema <schema HRN> An HRN of the data schema for this layer.
  • --billing-tags <tag1 tag2 ...> A list of billing tags used for search discovery.
  • --coverage <code1 code2 ...> A list of ISO 3166 two-letter codes for countries and regions. Optionally, followed by up to three characters codes for subdivisions, such as DE for Germany, PL for Poland, or CN-HK for Hong Kong, China. These codes must be separated by spaces.
  • --quiet Displays empty output with no additional information.
  • --scope <project HRN> Specifies the project HRN to use as the scope in the request. The value specified with --scope overrides any value for here.token.scope provided in the credentials file used for the command.

Optional parameters for a stream layer:

  • --ttl The layer's time-to-live or expiry time in milliseconds.
    • Maximum value: 7 days (604800000 ms);
    • Minimum value: 1 minute (60000 ms);
    • Default value: 1 hour (3600000 ms).
  • --content-type <layer data type> The content type of the layer, such as application/vnd.geo+json and text/plain. The default value is application/x-protobuf.
  • --content-encoding <encoding type> The content encoding of the layer, such as gzip. If this parameter is specified, all data in a layer is compressed by the specified algorithm. The default value is Uncompressed, which means no compression.
  • --data-in <size><KB|MB> The maximum throughput for incoming data in the layer.
    • Maximum value: 32MB (32,800 KBps maximum or 32,768 KBps rounded up to the nearest 100th);
    • Minimum value: 100KB (can only be a multiple of 100 KBps);
    • Default value: 1MB, if no scale parameters are set; otherwise it is calculated by the HERE platform;
    • If the unit value is omitted, MB will be used by default;
  • --data-out <size><KB|MB> The maximum throughput for outgoing data in the layer.
    • Maximum value: 64MB (65,500 KBps maximum or 65,536 KBps rounded up to the nearest 100th);
    • Minimum value: 100KB (can only be a multiple of 100 KBps);
    • Default value: 4MB, if no scale parameters are set; otherwise it is calculated by the HERE platform;
    • If the unit value is omitted, MB will be used by default;

Optional parameters for an index layer:

  • --ttl The layer's time-to-live or expiry time in milliseconds.
    • Maximum value: 7 days (604800000 ms);
    • Minimum value: 1 minute (60000 ms);
    • Default value: 1 hour (3600000 ms).
  • --digest <md5|sha-1|sha-256> The digest algorithm to use to calculate the checksum for the layer. Possible values are md5, sha-1, sha-256.

Note

TTL changes can take up to 24 hours to propagate, so any data in the process of expiration per previous TTL will expire before the new TTL changes are applied.

Optional parameters for a versioned layer:

  • --digest <md5|sha-1|sha-256> The digest algorithm to use to calculate the checksum for the layer. Possible values are md5, sha-1, sha-256.

Note

The --digest parameter cannot be updated once set. If this parameter has been already specified for olp catalog layer add or olp catalog layer update commands, it cannot be changed.

Example:

The command below updates the name of layer from old-layer to newname and the tags to tag1 and tag2.

Linux
Windows
olp catalog layer update hrn:here-cn:data:::catalog1 old-layer --name newname \
   --description "New Description" --tags tag1 tag2
olp catalog layer update hrn:here-cn:data:::catalog1 old-layer --name newname ^
   --description "New Description" --tags tag1 tag2

catalog layer delete

Deletes the specified stream, volatile, or index layer in the catalog. Versioned layers cannot be deleted due to possible dependencies across other versioned layers.

olp catalog layer delete <catalog HRN> <layer ID> [command options]

Warning

Deleting a layer permanently and irrevocably removes both the data and the metadata associated with the layer.

Required parameters:

  • <catalog HRN> The HRN of the catalog.
  • <layer ID> The ID of the layer to delete.

Optional parameters:

  • --credentials <path to credentials file> The name of a credentials file to use with the command. Credentials files are downloaded separately from the platform portal.
  • --profile <profile name> The name of the credentials profile to use from the olpcli.ini file.
  • --quiet Displays empty output with no additional information.
  • --scope <project HRN> Specifies the project HRN to use as the scope in the request. The value specified with --scope overrides any value for here.token.scope provided in the credentials file used for the command.

Example:

The command below deletes the some-layer layer from the hrn:here-cn:data:::catalog1 catalog.


olp catalog layer delete hrn:here-cn:data:::catalog1 some-layer

catalog layer inspect

Opens an external browser and navigates to the layer inspect page in the platform portal. The data can be inspected visually (HERE Tile layers only) and structurally, provided that the layer is properly configured. See the Data Inspector Library documentation for more information.

The command fails if you cannot access the catalog or if the specified layer does not exist.

olp catalog layer inspect <catalog HRN> <layer ID> [command options]

Optional parameters:

  • --credentials <path to credentials file> The name of a credentials file to use with the command. Credentials files are downloaded separately from the platform portal.
  • --profile <profile name> The name of the credentials profile to use from the olpcli.ini file.
  • --quiet Displays empty output with no additional information.
  • --scope <project HRN> Specifies the project HRN to use as the scope in the request. The value specified with --scope overrides any value for here.token.scope provided in the credentials file used for the command.

Note

The olp catalog layer inspect command checks whether the catalog is accessible to an app according to app permissions. However, for the catalog layer to be visible in the portal, your user too must have read permissions to the catalog.

For more information on using credentials and profiles, see Credentials Setup.

results matching ""

    No results matching ""