Skip to main content
Popsink delivers your pipeline data to Cloudera as Apache Iceberg tables. The Iceberg target registers each table in the cluster’s Hive Metastore and writes its files to HDFS or Ozone, authenticating with Kerberos. The tables are regular Cloudera Iceberg tables: Impala, Hive, Spark and Cloudera Data Visualization query them, and Ranger governs them, with nothing to install on the cluster. Every change event is a row, so each table holds the source table’s change history. The current state is read through a view. See Current state.

Compatible versions

Iceberg format v3 is disabled on Cloudera: Impala does not read it.

How It Works

  1. The worker obtains a Kerberos ticket from the keytab you upload, and renews it on its own.
  2. It writes one Iceberg table per subscription under the warehouse path, and registers it in the Hive Metastore as an Iceberg table (table_type=ICEBERG, with the Hive storage handler), exactly as Cloudera’s own engines do.
  3. Rows are committed as Iceberg appends, at 10,000 rows or 60 seconds per table. Each commit takes the Hive Metastore lock on the table, so the worker can share a table with Hive, Impala or Spark writers without losing a snapshot.
  4. Impala picks up new tables and new commits from the metastore’s events: no REFRESH is needed when event polling is on (the default on Cloudera).
  5. A daily maintenance job compacts small files and expires old snapshots, through the same metastore lock.

Prerequisites

  • A Kerberized Cloudera cluster with a Hive Metastore reachable from Popsink, and a Hive database for the tables (e.g. popsink).
  • A Kerberos principal for Popsink (e.g. popsink@CORP.EXAMPLE.COM) and its keytab, created by your Kerberos or Active Directory administrator.
  • Ranger policies for that principal (see Ranger policies).
  • A warehouse path the principal can write to: on HDFS, e.g. /warehouse/tablespace/external/hive/popsink.db; on Ozone, a bucket exposed by the S3 Gateway.
  • A primary key on each subscription whose current state you want to read: flag the key columns in the subscription’s column mapping, or declare them on the datamodel.

Network

Popsink’s worker must reach, from its egress IPs or from inside your network for a self-hosted deployment: The worker reads and writes blocks directly on the DataNodes: opening the NameNode alone is not enough.

Ranger policies

In Ranger, give the Popsink principal (or a group it belongs to): Drop is used by the connection test only, which creates and drops a popsink_preflight_<random> table. The connector never drops a table it writes to.

Configure the target

In the console, open Connectors → Targets, click New Target and pick Cloudera. The tile opens the Iceberg target form, preset for Cloudera: catalog Hive Metastore, Kerberos on, storage HDFS, format v2. Once saved, the connector is listed as an Iceberg target with a Cloudera badge.

Catalog

Use the realm exactly as in the keytab, upper case. klist -kt popsink.keytab lists the principals a keytab holds.

Storage

Pick Storage Credentials → Static credentials of this connector → HDFS.The warehouse must be an hdfs://<nameservice>/… path.

Connection test

Test walks the steps the worker walks, and prefixes any failure with the step that failed: Save the target, then create a subscription for each source table. Each one creates its table on the first commit.

Querying the tables

Tables appear in the Hive database as soon as their first batch is committed:
Impala
If Impala’s metastore event processing is off (hms_event_polling_interval_s = 0), run INVALIDATE METADATA popsink.orders once for a new table, and REFRESH popsink.orders to see new commits.

What is written

The table holds the subscription’s mapped columns plus __op and __ts_ms, and, with metadata columns on, __kafka_partition, __kafka_offset, __kafka_timestamp and __ingested_at. See What Is Written. Iceberg types are chosen as on the Iceberg target. The connector never writes the Iceberg types Impala cannot read (time, uuid, fixed): times and UUIDs are written as string.
Impala reads a timestamptz column as a TIMESTAMP in UTC. To show local time, convert explicitly: from_utc_timestamp(__ingested_at, 'Europe/Paris').

Current state of a table

The Iceberg table is the change history: an update or a delete adds a row. To read one row per key, create a view that keeps the latest change of each key and hides deleted keys. The rules are detailed under Current state: the merge view.
Impala
The view is stored in the Hive Metastore, so Hive and Spark read it too. Replace id with your primary key columns, and drop the __kafka_offset tie-breaker if metadata columns are off on the subscription. Keep the delete filter after the ranking: filtering deletes first would bring a deleted row’s previous version back.
For large tables read often, materialize the view on a schedule (CREATE TABLE … STORED BY ICEBERG AS SELECT … FROM orders_current in a Cloudera Data Engineering or Oozie job) and point dashboards at the copy.

Table maintenance

The maintenance job runs daily on Cloudera as on any other catalog: compaction, snapshot expiry, orphan cleanup and, optionally, purge of deleted keys. It authenticates with the same keytab and commits through the metastore lock, so it never races the worker or your own jobs. If your team already runs Iceberg maintenance from Spark (rewrite_data_files, expire_snapshots), keep one of the two: turn off maintenance on the connector, or exclude Popsink’s database from your jobs.

Limitations

  • Iceberg format v2 only, for Impala.
  • The current-state view is created and maintained by you: the managed merge view is available on Snowflake only.
  • Kerberos is the only authentication to the metastore: LDAP or Knox-only access is not supported.
  • Ozone is reached through its S3 Gateway only: ofs:// and o3fs:// paths are not supported.
  • One Hive database per connector. A Hive database is one namespace level.
  • Columns are never dropped or retyped. Nested records and arrays are written as JSON text. See the Iceberg target limitations.

FAQ

No. Popsink writes standard Iceberg tables through the Hive Metastore’s own API, and the Kerberos principal, the keytab and the Ranger policies are all it needs.
Yes. Every commit takes the Hive Metastore lock on the table, like Cloudera’s engines, so concurrent commits are serialized and none is lost. Keep the columns Popsink writes under its control: a column renamed or retyped by another writer stops the subscription on that table.
Check that Impala’s metastore event processing is on. If it is off, run INVALIDATE METADATA <db>.<table> for a new table and REFRESH <db>.<table> for new commits.
Kerberos refuses tickets when clocks differ by more than five minutes. On a self-hosted deployment, synchronize the nodes running Popsink with your cluster’s NTP servers.

Iceberg target

Every option of the connector behind the Cloudera target.

Target data types

Compare column types across every target.

Start a pipeline

End-to-end example to validate your configuration.