Skip to content

Data Forwarding to AWS S3


  1. Complete the Rule Name and Filter Conditions settings;
  2. Continue with archive configuration.

Configure

  1. For Archive Type, select AWS S3, which means the matched data will be saved to this object storage;
  2. Select a storage format;

    • If you select Apache Iceberg, complete the additional configuration;
  3. When the storage format is JSON or Parquet, select whether to enable encrypted storage;

  4. Select an access type;
  5. Click OK to complete creation.
Note

If the archive type information changes, make sure the configuration of the associated platform is updated accordingly to avoid data write failures caused by configuration changes. The new configuration rules take effect within 5 minutes.

When the storage format is JSON or Parquet and encrypted storage is enabled, if you need to download files and read them locally, see Decrypt Files.

Apache Iceberg

Apache Iceberg is an open table format. After you select Apache Iceberg as the storage format, Guance writes data as Parquet files to your Iceberg table through REST Catalog. The data can be read directly by data lake engines such as Spark, Trino, and Flink, and supports table capabilities such as schema evolution and snapshots.

Note

The Iceberg format currently supports write operations only. Archived data cannot be queried within Guance, and this rule cannot be selected on the "Data Explorer" page. To query the data, connect to the same Catalog through an external query engine and read it.

  1. For Storage Format, select Apache Iceberg (❗️After selection, the "Encrypted Storage" and "Data Waiting Time" configuration items are no longer displayed on the page);
  2. In Iceberg Catalog, select a Catalog Provider and enter the Catalog URI and Warehouse (both are required). The value formats vary by Provider:

    Catalog Provider Catalog URI Warehouse Value
    Generic REST Catalog REST Catalog URL, such as https://catalog.example.com; do not manually append /v1 Warehouse storage address, such as s3://warehouse/observability
    AWS S3 Tables https://s3tables.<region>.amazonaws.com/iceberg Complete Table Bucket ARN, such as arn:aws:s3tables:<region>:<account-id>:bucket/<bucket-name> (the ARN prefix for the China region is arn:aws-cn)
    AWS Glue https://glue.<region>.amazonaws.com/iceberg 12-digit AWS root account ID (not an IAM user ID), such as 294654068288
    • If you select "Generic REST Catalog", you can also optionally enter an Endpoint: if you need to forward data to a private cloud or a custom S3 address, you can enter an Endpoint. For public cloud scenarios, leave it blank; the system automatically determines whether internal network forwarding can be used. If you enter an Endpoint, billing is based on public network forwarding.
  3. Under Target Table, enter the Namespace (a single-level namespace that cannot contain .) and Table (table name); if the table does not exist, it is created automatically, and data is automatically partitioned by hour(date);

  4. Select a Catalog Authentication method and enter the corresponding credentials:

    • Generic REST Catalog supports the following authentication methods:

      • No authentication: no input required;
      • Basic Auth: enter the Credential (username:password);
      • Bearer Token: enter the Token;
      • OAuth2: enter the Credential (client-id:client-secret); you can optionally enter an OAuth2 Server URI; if left blank, the Catalog default address is used;
    • AWS S3 Tables / AWS Glue: SigV4 is always used; no additional configuration is required, and the AWS access credentials configured above are automatically reused;

  5. Complete authorization and archive information configuration according to the access type instructions below;

  6. Click "Test Connection" to verify connectivity between the bucket and the Catalog. After the test passes, click OK to save the current rule.

Note
  • After a rule is created, the storage format, region, Catalog URI, Warehouse, Namespace, and Table cannot be modified; the bucket and storage path can be modified, and the change logic is the same as that of existing rules;
  • Custom partition rules, file formats, table properties, and other configurations are not supported for now;
  • The storage path naming convention is the same as that of existing rules.

Access Type

Role Authorization

  1. You must use the external ID generated by default by Guance to configure third-party access to AWS resources;

  2. After configuring the Guance IAM role in AWS, fill in the archive information: AWS account ID, AWS role name, region, and bucket name;

  3. Enter the storage path to make it easier to further distinguish and locate the specific location for data forwarding;

  4. Click "Test Connection". If the above information meets the requirements, a message indicating a successful test connection is displayed. Click OK to save the current rule.

Storage Path Naming Convention
  1. Create a single folder or multi-level folders; a slash (/) indicates the creation of multi-level folders.
  2. Folder names cannot start or end with a slash (/).
  3. Cannot contain two or more consecutive slashes (/).
  4. Applies to all access types.
Note
  • If the entered folder does not exist, Guance creates it directly, and data is still stored under that path.
  • Change the storage path with caution. Because there is a delay of about 5 minutes in updating the configuration, some data may still be forwarded to the original directory after the change.
If the test fails:

Verify the following:

  • Whether the external ID has expired;
  • Whether the account ID is correct;
  • Whether the account role exists;
  • Whether the bucket exists;
  • Whether the Region is inconsistent.

Exercise caution in the following cases:

  • If you click to regenerate the external ID, the previous ID will expire after 24 hours. Go to the AWS console to replace it as soon as possible;
  • Do not click to generate the external ID multiple times. Proceed with caution!

Access Keys

  1. Click to download the AWS resource authorization template and go to AWS to configure the Guance IAM policy;
  2. After configuration is complete, fill in the account information by entering the AWS AK & SK, region, and Bucket name;
  3. Enter the storage path to make it easier to further distinguish and locate the specific location for data forwarding;
  4. Click "Test Connection". If the above information meets the requirements, a message indicating a successful test connection is displayed;
If the test fails:

Verify the following:

  • Whether the account ID is correct
  • Whether the AK / SK exists
  • Whether the bucket exists
  • Whether the Region is inconsistent

Account Authorization

  1. AWS provides cross-account authorization capabilities. You need to use the dedicated account ID for Guance and follow the configuration instructions to add a cross-account access authorization policy;

  2. After configuration is complete, select a region and enter the bucket name;

  3. Enter the storage path to make it easier to further distinguish and locate the specific location for data forwarding;

  4. Click "Test Connection". If the above information meets the requirements, a message indicating a successful test connection is displayed. Click OK to save the current rule.

If the test fails:

Verify the following:

  • Whether the account ID is correct
  • Whether the bucket exists
  • Whether the Region is inconsistent

Data Waiting Time

Data is first written to a local temporary file. When the file size reaches 256 MB or the waiting time reaches the set value, the system automatically compresses and uploads the file. You can adjust the waiting time based on your actual needs, including 15 minutes, 30 minutes, and 1 hour:

  • A shorter setting results in lower downstream data latency but generates more files
  • A longer setting results in fewer files but increases downstream data latency accordingly
Note

When the storage format is Apache Iceberg, this configuration does not apply.

Next Steps

Continue to configure the data viewing permissions for the current forwarding rule.

Note

When the storage format is Apache Iceberg, only write operations are currently supported, and data viewing permissions do not need to be configured.

Feedback

Is this page helpful?