feat(quicksight): add metadata APIs and limited registered-user embedding (#7529)

Closes #7522

Origin comparisons preserved host casing and default ports, CSP named only the immediate parent, and expired sessions remained in storage indefinitely. Normalize both sides of origin checks, allow all configured ancestors, and reap expired sessions across accounts with the shared sweep worker.
This commit is contained in:
jwoa95 authored and GitHub committed 2026-11-06 09:11:30 -04:00
1 parent 5058163409
commit f8670f64fb
40 files changed
+2511 -37

No files matched your search

@@ -108,6 +108,7 @@ import software.amazon.awssdk.services.opensearch.OpenSearchClient;
import software.amazon.awssdk.services.organizations.OrganizationsClient;
import software.amazon.awssdk.services.paymentcryptography.PaymentCryptographyClient;
import software.amazon.awssdk.services.pipes.PipesClient;
import software.amazon.awssdk.services.quicksight.QuickSightClient;
import software.amazon.awssdk.services.ram.RamClient;
import software.amazon.awssdk.services.rds.RdsClient;
import software.amazon.awssdk.services.redshift.RedshiftClient;
@@ -645,6 +646,14 @@ public final class TestFixtures {
.build();
}
public static QuickSightClient quickSightClient() {
return QuickSightClient.builder()
.endpointOverride(ENDPOINT)
.region(REGION)
.credentialsProvider(CREDENTIALS)
.build();
}
public static ServiceQuotasClient serviceQuotasClient() {
return ServiceQuotasClient.builder()
.endpointOverride(ENDPOINT)
@@ -0,0 +1,38 @@
package com.floci.test;
import org.junit.jupiter.api.DisplayName;
import org.junit.jupiter.api.Test;
import software.amazon.awssdk.services.quicksight.QuickSightClient;
import software.amazon.awssdk.services.quicksight.model.ResourceNotFoundException;
import java.util.List;
import java.util.UUID;
import static org.assertj.core.api.Assertions.assertThat;
import static org.assertj.core.api.Assertions.assertThatThrownBy;
import static org.junit.jupiter.api.Assumptions.assumeFalse;
class QuickSightTest {
@Test
@DisplayName("The local QuickSight subset stores dashboard metadata through the AWS SDK")
void dashboardMetadataRoundTrip() {
assumeFalse(TestFixtures.isRealAws(), "Exercises the metadata-only local subset without a QuickSight subscription");
String account = "000000000000";
String id = "compat-" + UUID.randomUUID();
try (QuickSightClient client = TestFixtures.quickSightClient()) {
String arn = client.createDashboard(request -> request.awsAccountId(account).dashboardId(id)
.name("Metadata dashboard").definition(definition -> definition.sheets(List.of()))).arn();
try {
assertThat(arn).isEqualTo(TestFixtures.arn("quicksight", account, "dashboard/" + id));
assertThat(client.describeDashboard(request -> request.awsAccountId(account).dashboardId(id))
.dashboard().name()).isEqualTo("Metadata dashboard");
assertThat(client.describeDashboard(request -> request.awsAccountId(account).dashboardId(id))
.dashboard().createdTime()).isNotNull();
} finally {
client.deleteDashboard(request -> request.awsAccountId(account).dashboardId(id));
}
assertThatThrownBy(() -> client.describeDashboard(request -> request.awsAccountId(account).dashboardId(id)))
.isInstanceOf(ResourceNotFoundException.class);
}
}
}