Support for the basics of federation #1

Merged
steffo merged 8 commits from feature/basics into main 2024-10-17 22:48:14 +00:00
Showing only changes of commit dbf7f6d49f - Show all commits

View file

@ -1,12 +1,12 @@
import {createFederation} from "@fedify/fedify" import {createFederation} from "@fedify/fedify"
import {RedisKvStore} from "https://jsr.io/@fedify/redis/0.3.0/src/kv.ts" import {RedisKvStore} from "https://jsr.io/@fedify/redis/0.3.0/src/kv.ts"
import {Redis} from "ioredis"; import {Redis} from "ioredis"
const federation = createFederation<void>({ const federation = createFederation<void>({
kv: new RedisKvStore( kv: new RedisKvStore(
new Redis({}), new Redis({}),
{} {},
), ),
}); });
@ -15,16 +15,15 @@ const handler: Deno.ServeHandler = function handler(request) {
request, request,
{ {
contextData: undefined, contextData: undefined,
} },
) );
return response return response
} };
Deno.serve( Deno.serve(
{ {
port: 8080 port: 8080,
}, },
handler handler,
) );