File tree Expand file tree Collapse file tree 1 file changed +16
-1
lines changed
Expand file tree Collapse file tree 1 file changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -342,7 +342,6 @@ import S3Store, {type MetadataValue} from '@tus/s3-store'
342342import {createClient } from ' @redis/client'
343343
344344const client = await createClient ().connect ()
345- const path = ' ./uploads'
346345const prefix = ' foo' // prefix for the key (foo${id})
347346
348347new S3Store ({
@@ -351,6 +350,22 @@ new S3Store({
351350})
352351` ` `
353352
353+ #### ` IoRedisKvStore`
354+
355+ ` ` ` ts
356+ import { IoRedisKvStore } from ' @tus/server' ;
357+ import S3Store , { type MetadataValue } from ' @tus/s3-store' ;
358+ import Redis from ' ioredis' ;
359+
360+ const client = new Redis ();
361+ const prefix = ' foo' ; // prefix for the key (foo${id})
362+
363+ new S3Store ({
364+ // ...
365+ cache: new IoRedisKvStore < MetadataValue> (client, prefix),
366+ });
367+ ` ` `
368+
354369## Examples
355370
356371### Example: integrate tus into Express
You can’t perform that action at this time.
0 commit comments