Skip to content

Dsql ​

Parity grade: A · SDK aws-sdk-go-v2/service/dsql@v1.22.3 · last audited 2026-10-10 (5bb0d02ee)

Category: Other · View PARITY.md on GitHub · All Services

Parity & Coverage ​

MetricValue
PARITY entries audited16 (16 ok)
Feature families4 (4 ok)
Known gaps7
Structural gaps (can't be emulated)2
Deferred items0
Resource leaksclean

Known Gaps ​

  • Data plane opt-in (DSQL_ENGINE=docker, or --engines=auto/docker with a reachable runtime; default stub keeps the control plane only). The cluster endpoint <id>.dsql.<region>.on.aws is not resolvable and clients cannot assume port 5432: connect to host/port from GET /_gopherstack/dsql/clusters/{id}; tokens are generated for the control-plane endpoint (also accepted: endpoint:port, loopback:port). The CA is served at /_gopherstack/dsql/ca.pem.
  • Cluster data is ephemeral: each data plane is a fresh postgres container with no volume, so a restart or snapshot restore re-creates clusters (CREATING until up) with an empty database.
  • Unsupported-feature rejection covers CREATE TRIGGER, DROP TRIGGER, ALTER TABLE ... DISABLE/ENABLE TRIGGER, isolation levels other than repeatable read, temporary tables, TRUNCATE, VACUUM, CREATE TABLESPACE, CREATE DATABASE and LANGUAGE plpgsql functions at the statement start only (not inside multi-statement strings or DO blocks). Foreign keys and sequences are accepted: the current User Guide documents both as supported (the bd issue text predates that). Plain CREATE INDEX is rejected (ASYNC required). The unsupported set matches the migration guide (no triggers, temporary tables, TRUNCATE, VACUUM, tablespaces or extra databases; SQL functions but no PL/pgSQL).
  • CREATE INDEX ASYNC runs a plain (blocking) CREATE INDEX in a background job: CONCURRENTLY deadlocks with a session in sys.wait_for_job, so a failed unique build leaves no INVALID index (DSQL leaves one). Old completed/failed rows are pruned on the next submit as documented; job_id is 26 base32 characters as in the docs, object_id is the index oid once built.
  • Transaction rules are enforced inside PostgreSQL (event + statement triggers with transition tables), so they hold on both wire protocols. Still open, each with its blocker: the 5 minute transaction age limit ('transaction age limit of 300s exceeded') needs a hook at commit or a timer inside the server, and stock PostgreSQL has neither (a statement-time check would not fire for an idle transaction, and a test would need a 5 minute wait); the 1 KiB combined index key size limit ('key size too large') needs per-index key bytes of every written row, which the statement-level transition-table guard in services/dsql/bootstrap.go (gs_dml_ins) does not compute; the 128 MiB per-query memory limit ('query requires too much temp space, out of memory', 53200) has no PostgreSQL setting with that behaviour.
  • The cluster resource policy (PutClusterPolicy) is not evaluated at connect time; only the caller's identity policies are, and only when IAM enforcement is on. AWS IAM GRANT/REVOKE and sys.iam_pg_role_mappings are modelled (roles are logged in with an engine-private password), other sys.* views are absent.
  • The postgres TLS front proxy duplicates the framing and startup code in services/rds/engine_proxy.go; a shared pkgs/ package is a follow-up.

Structural Gaps ​

These do not block an A grade — no implementation could produce real data here because the underlying data source cannot exist in an emulator.

  • bypassPolicyLockoutSafetyCheck (CreateCluster, PutClusterPolicy) is accepted but not evaluated: the lockout check asks whether the calling principal keeps access, and the emulator has no authenticated caller identity or IAM policy evaluation (same stance as services/kms).
  • GetVpcEndpointServiceName returns wire-shaped names only: there is no PrivateLink / VPC endpoint plane to back them.

Audited Operations ​

16 audited operations
OperationWireErrorsStatePersist
CreateClusterokokokok
GetClusterokokokok
ListClustersokokokok
UpdateClusterokokokok
DeleteClusterokokokok
GetClusterPolicyokokokok
PutClusterPolicyokokokok
DeleteClusterPolicyokokokok
GetVpcEndpointServiceNameokokokok
CreateStreamokokokok
GetStreamokokokok
DeleteStreamokokokok
ListStreamsokokokok
TagResourceokokokok
UntagResourceokokokok
ListTagsForResourceokokokok

Audited Feature Families ​

Feature FamilyStatus
Clusterok
ClusterPolicyok
Streamok
Tagsok

Released under the MIT License.