Cloudflare Hyperdrive

cloudflareDatabase proxycloudflare-hyperdrive

Pooled and cached connections from Workers to an existing Postgres or MySQL database.

Provider
cloudflare
Category
Data
Properties · 5 set by this component
propertytypevaluesrequiredkind defaultthis component
cacheMaxAgeSeconds · component propertyinteger—no60inherited
engine · component propertyenumpostgres | mysqlnopostgresinherited
hedging · advancedboolean—nofalseinherited
loadShedding · advancedboolean—nofalseinherited
managedboolean—nofalse▸ true
poolSharded · advancedboolean—nofalse▸ false
poolingboolean—notrue▸ true
queryCaching · component propertyboolean—notrueinherited
requestCoalescing · advancedboolean—nofalseinherited
routingenumnone | shard-key | lookupnonone▸ none
scatterGather · advancedboolean—nofalse▸ false
staleWhileRevalidateSeconds · component propertyinteger—no15inherited
Rules that apply · 0

Every rule whose selector covers this component's kind or its category. Whether a rule fires depends on the design: its properties, its edges and its groups.

No rule reads this kind yet. That is a gap, not a guarantee.
Use it in a design
nodes:
  - { id: "hyperdrive", component: "cloudflare-hyperdrive" }
Other Database proxy products · 13
Source
# yaml-language-server: $schema=../../schema/component.schema.json
# Hyperdrive: pooled, cached connections from Workers to an existing Postgres or MySQL database.
# "How Hyperdrive works" states it manages the connection pool for you; "Query caching" states
# caching is enabled by default with max_age 60 s and stale_while_revalidate 15 s, reads only.
schemaVersion: "1"
type: "component"
id: "cloudflare-hyperdrive"
kind: "database-proxy"
provider: "cloudflare"
docs: "https://developers.cloudflare.com/hyperdrive/configuration/query-caching/"
defaults:
  managed: true
  pooling: true
  routing: "none"
  poolSharded: false
  scatterGather: false
properties:
  engine:
    type: "enum"
    values: ["postgres", "mysql"]
    default: "postgres"
  queryCaching:
    type: "boolean"
    default: true
  cacheMaxAgeSeconds:
    type: "integer"
    default: 60
  staleWhileRevalidateSeconds:
    type: "integer"
    default: 15

The same page as markdown, for an agent: /catalogue/components/cloudflare-hyperdrive.md