HttpNamespace
The HttpNamespace resource lets you manage AWS ServiceDiscovery HttpNamespaces and their configuration settings.
Minimal Example
Section titled “Minimal Example”Create a basic HttpNamespace with required properties and a description.
import AWS from "alchemy/aws/control";
const httpNamespace = await AWS.ServiceDiscovery.HttpNamespace("myHttpNamespace", { name: "my-http-namespace", description: "This namespace is used for HTTP service discovery."});
Advanced Configuration
Section titled “Advanced Configuration”Configure an HttpNamespace with tags for resource management.
const taggedHttpNamespace = await AWS.ServiceDiscovery.HttpNamespace("taggedHttpNamespace", { name: "tagged-http-namespace", description: "This namespace is used for HTTP service discovery with tags.", tags: [ { key: "Environment", value: "Production" }, { key: "Department", value: "Engineering" } ]});
Adoption of Existing Resources
Section titled “Adoption of Existing Resources”Create an HttpNamespace and adopt an existing resource if it already exists.
const existingHttpNamespace = await AWS.ServiceDiscovery.HttpNamespace("existingHttpNamespace", { name: "existing-http-namespace", adopt: true // Adopt the existing namespace if it already exists});
Updating an HttpNamespace
Section titled “Updating an HttpNamespace”Update an existing HttpNamespace by modifying its description.
const updatedHttpNamespace = await AWS.ServiceDiscovery.HttpNamespace("updatedHttpNamespace", { name: "my-http-namespace", description: "Updated description for the HTTP namespace."});