Consumption Analytics Documentation

Home > Documentation for older versions > Cloud Cruiser 4 > Collecting, transforming, and publishing > Steps for all collectors > Using transform processors > Truncating identifier values

Truncating identifier values

Identifier names and values cannot exceed 255 characters. If an identifier name or value is too long, the charge step truncates it to the maximum length before loading into the database. This article shows two ways you can truncate identifiers during transformation and how to control logging for the automatic truncation that occurs in the charge step.

Truncating with CreateIdentifierFromIdentifier

You can use InputIdentifier within the CreateIdentifierFromIdentifier transform. For example, to truncate the first 100 characters of a ServiceDescription identifier, the syntax is:

<bean class="com.cloudcruiser.batch.transform.InputIdentifier">
  <property name="name" value="ServiceDescription"/>
  ​<property name="len" value="100"/>

The limitations of this way of truncating identifiers are that it sets the same identifier as the target and a source along with an end value with no padding.

Truncating with TruncateIdentifiers

The TruncateIdentifiers transform accepts one or more identifiers names or an expression, and sets the maximum length for specified or matching identifiers. For example, to truncate the first 100 characters of identifiers that match *.Description , the syntax is:

<bean class="com.cloudcruiser.batch.transform.TruncateIdentifiers">
  <property name="active" value="true" />
  <property name="maxLength" value="100" />
  <property name="identifierPattern" value="*.Description" />
  <property name="identifiers" value="AccountName,AccountAlias" />

Logging truncation by the charge step

During the charge step of the job, when running CCRecordChargeTasklet , you can use the identifierTruncationLogLevel property to set the level at which the "identifier too long" conditions are logged. A message is logged when an identifier name or value exceeds the maximum length that can be stored in the database, 255 characters. This setting only affects logging and has no impact on data processing.

The valid values are ERROR, WARN (the default), INFO, DEBUG, TRACE, and OFF. For example:

<batch:step id="charge" next="emailFiles">
    <bean class="com.cloudcruiser.batch.CCRecordChargeTasklet">
      <property name="identifierTruncationLogLevel" value="WARN"/>
Last modified


This page has no custom tags.


This page has no classifications.

 (c) Copyright 2017-2020 Hewlett Packard Enterprise Development LP