Home / Function/ upstashCache() — drizzle-orm Function Reference

upstashCache() — drizzle-orm Function Reference

Architecture documentation for the upstashCache() function in cache.ts from the drizzle-orm codebase.

Entity Profile

Dependency Diagram

graph TD
  7f72dc06_fb21_102e_18b8_89421e2ed0a7["upstashCache()"]
  44f92f64_5c49_a0a8_3c18_2e6651af97f8["cache.ts"]
  7f72dc06_fb21_102e_18b8_89421e2ed0a7 -->|defined in| 44f92f64_5c49_a0a8_3c18_2e6651af97f8
  style 7f72dc06_fb21_102e_18b8_89421e2ed0a7 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

drizzle-orm/src/cache/upstash/cache.ts lines 204–213

export function upstashCache(
	{ url, token, config, global = false }: { url: string; token: string; config?: CacheConfig; global?: boolean },
): UpstashCache {
	const redis = new Redis({
		url,
		token,
	});

	return new UpstashCache(redis, config, global);
}

Domain

Subdomains

Frequently Asked Questions

What does upstashCache() do?
upstashCache() is a function in the drizzle-orm codebase, defined in drizzle-orm/src/cache/upstash/cache.ts.
Where is upstashCache() defined?
upstashCache() is defined in drizzle-orm/src/cache/upstash/cache.ts at line 204.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free