Table: fastly_dictionary - Query Fastly Dictionaries using SQL
Fastly Dictionaries are key-value stores that are associated with a particular Fastly service. They are designed to help you store and manage data that can be referenced from VCL, Fastly's own caching configuration language. These dictionaries can be used to customize how cached content is served, making them a crucial part of Fastly's edge cloud platform.
Table Usage Guide
The fastly_dictionary
table provides insights into Fastly Dictionaries, which are key-value stores associated with a particular Fastly service. As a DevOps engineer, you can use this table to manage and manipulate data that can be referenced from VCL, Fastly's own caching configuration language. This table can be particularly useful when you need to customize how cached content is served, enhancing your control over Fastly's edge cloud platform.
Examples
Basic info
Explore which Fastly dictionaries have been created with write-only permissions. This can help you understand how your data is being secured and managed within your Fastly service.
select id, name, service_id, service_version, write_only, created_atfrom fastly_dictionary;
select id, name, service_id, service_version, write_only, created_atfrom fastly_dictionary;
List dictionaries created in the last 30 days
Explore which dictionaries have been created recently to keep track of changes and updates. This is useful for maintaining an up-to-date understanding of the system and identifying any unexpected modifications.
select id, name, service_id, service_version, write_only, created_atfrom fastly_dictionarywhere created_at >= now() - interval '30 days';
select id, name, service_id, service_version, write_only, created_atfrom fastly_dictionarywhere created_at >= datetime('now', '-30 days');
List dictionaries that have not been deleted
Explore which dictionaries within your Fastly service are still active and have not been deleted. This can be useful for managing your data resources and ensuring they are up-to-date.
select id, name, service_id, service_version, write_only, created_atfrom fastly_dictionarywhere deleted_at is null;
select id, name, service_id, service_version, write_only, created_atfrom fastly_dictionarywhere deleted_at is null;
List write-only dictionaries
Explore which dictionaries in your Fastly service are set to write-only. This can help identify areas where data is being stored but not read, potentially highlighting inefficiencies or security concerns.
select id, name, service_id, service_version, write_only, created_atfrom fastly_dictionarywhere write_only;
select id, name, service_id, service_version, write_only, created_atfrom fastly_dictionarywhere write_only = 1;
Schema for fastly_dictionary
Name | Type | Operators | Description |
---|---|---|---|
_ctx | jsonb | Steampipe context in JSON form, e.g. connection_name. | |
created_at | timestamp with time zone | Timestamp (UTC) of when the Dictionary was created. | |
deleted_at | timestamp with time zone | Timestamp (UTC) of when the Dictionary was deleted. | |
id | text | The ID of the Dictionary. | |
name | text | = | The name of the Dictionary. |
service_id | text | Alphanumeric string identifying the service. | |
service_version | bigint | Integer identifying a service version. | |
title | text | Title of the resource. | |
updated_at | timestamp with time zone | Timestamp (UTC) of when the Dictionary was updated. | |
write_only | boolean | Determines if items in the dictionary are readable or not. |
Export
This table is available as a standalone Exporter CLI. Steampipe exporters are stand-alone binaries that allow you to extract data using Steampipe plugins without a database.
You can download the tarball for your platform from the Releases page, but it is simplest to install them with the steampipe_export_installer.sh
script:
/bin/sh -c "$(curl -fsSL https://steampipe.io/install/export.sh)" -- fastly
You can pass the configuration to the command with the --config
argument:
steampipe_export_fastly --config '<your_config>' fastly_dictionary