| 1 | import * as Cloudflare from "alchemy/Cloudflare"; |
| 2 | |
| 3 | /** |
| 4 | * Queue resource used by the Api worker as a producer (via |
| 5 | * `Cloudflare.Queues.WriteQueue(Queue)`). Exercises the Queue + QueueWrite |
| 6 | * resources end-to-end in the Effect-based example. |
| 7 | * |
| 8 | * The async example (`examples/cloudflare-worker-async`) demonstrates the |
| 9 | * consumer side via a native `queue()` handler on the default export — the |
| 10 | * Effect worker's `Main` type currently only exposes a `fetch` handler, so |
| 11 | * consumer-side wiring on Effect workers is a follow-up. |
| 12 | */ |
| 13 | export const Queue = Cloudflare.Queues.Queue("Queue"); |