Important

You are viewing documentation for an older version of Confluent Platform. For the latest, click here.

Hostname Resolver Transformation

It is often useful to re-key Apache Kafka® Source Records host field’s value as an IP address into a resolved hostname for that IP address. The Hostname Resolver Transformation makes this easy. This transformation will perform a reverse DNS lookup to replace IP addresses with hostnames. For example, 127.0.0.1 will be replaced with localhost on most machines.

For example, use the transformation by including the following lines in your Connector config:

transforms=myHostnameTransformName
transforms.hostname.type=io.confluent.connect.syslog.HostnameResolverTransformation

Configuration Options

field.name

The name of the field that contains the ip address of the remote host.

  • Type: string
  • Default: remoteAddress
  • Importance: medium
dns.cache.stats.secs

The amount of time in seconds to dump the cache statistics for the DNS cache.

  • Type: int
  • Default: 300
  • Valid Values: [1,…]
  • Importance: low
dns.cache.ttl.secs

The amount of time to cache a DNS entry for in seconds.

  • Type: int
  • Default: 300
  • Valid Values: [1,…]
  • Importance: low
dns.query.timeout.secs

The amount of time in seconds before the query is timed out.

  • Type: int
  • Default: 15
  • Valid Values: [1,…]
  • Importance: low