idz: Begin db backend stub

This commit is contained in:
Tau 2019-04-28 21:42:46 -04:00
parent 98c9f9106d
commit f0f2ab138d
2 changed files with 7 additions and 2 deletions

5
src/idz/db/index.ts Normal file
View File

@ -0,0 +1,5 @@
import { Transaction } from "../repo";
export async function beginDbSession(): Promise<Transaction> {
throw new Error("WIP");
}

View File

@ -1,11 +1,11 @@
import { Socket } from "net";
import { beginFilesystemSession } from "./file";
import { beginDbSession } from "./db";
import { dispatch } from "./handler";
import { setup } from "./setup";
export default async function idz(socket: Socket) {
const world = await beginFilesystemSession("./state");
const world = await beginDbSession();
const { input, output } = setup(socket);
console.log("Idz: Connection opened");