Skip to content

Commit

Permalink
Fix config and more caching improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
JakeGinnivan committed Aug 20, 2024
1 parent ff210da commit 3c692e3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion website/app/lib/config.server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,10 @@ export const {
OTEL_EXPORTER_OTLP_METRICS_ENDPOINT: z.string().optional(),
OTEL_EXPORTER_OTLP_LOGS_ENDPOINT: z.string().optional(),

USE_GITHUB_CONTENT: z.string().transform((val) => val === 'true'),
USE_GITHUB_CONTENT: z
.string()
.transform((val) => val === 'true')
.default('true'),

GITHUB_REF: z.string().default('main'),
GITHUB_TOKEN: z.string().optional(),
Expand Down
2 changes: 1 addition & 1 deletion website/app/lib/mdx.server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ const compilationCache = new LRUCache<string, string>({
const contentListingCache = new LRUCache<string, string[]>({
max: 250,
maxSize: 1024 * 1024 * 12, // 12 mb
ttl: 1000 * 60 * 60 * 24, // 24 hours
ttl: 1000 * 60 * 60, // 1 hour
sizeCalculation(value, key) {
return JSON.stringify(value).length + (key ? key.length : 0)
},
Expand Down

0 comments on commit 3c692e3

Please sign in to comment.