Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
CMCDragonkai committed Jul 20, 2022
1 parent 3690d10 commit fb83c35
Show file tree
Hide file tree
Showing 5 changed files with 77 additions and 1 deletion.
42 changes: 42 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,8 @@
"uuid": "^8.3.0"
},
"devDependencies": {
"@swc/core": "^1.2.215",
"@babel/preset-env": "^7.13.10",
"@swc/core": "^1.2.215",
"@types/cross-spawn": "^6.0.2",
"@types/google-protobuf": "^3.7.4",
"@types/jest": "^28.1.3",
Expand All @@ -130,6 +130,7 @@
"eslint-config-prettier": "^8.5.0",
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-prettier": "^4.0.0",
"fast-check": "^3.0.1",
"grpc_tools_node_protoc_ts": "^5.1.3",
"jest": "^28.1.1",
"jest-junit": "^14.0.0",
Expand Down
26 changes: 26 additions & 0 deletions src/queue/Queue.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
// epic queue
// need to do a couple things:
// 1. integrate fast-check
// 2. integrate span checks
// 3. might also consider span logs?
// 4. open tracing observability
// 5. structured logging
// 6. async hooks to get traced promises to understand the situation
// 7. do we also get fantasy land promises? and async cancellable stuff?
// 8. task abstractions?
// need to use the db for this
// 9. priority structure
// 10. timers
// abort controller

// timeout scheduling system is task scheduling
// queue is the persistent version of this
// in general you have a job scheduling problem
// but lighter weight

class Queue {


}

export default Queue;
Empty file added src/queue/index.ts
Empty file.
7 changes: 7 additions & 0 deletions src/timer/Timer.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
class Timer {

protected timer: ReturnType<typeof setTimeout>;
public readonly timerP: Promise<void>;
protected _timedOut: boolean;

}

0 comments on commit fb83c35

Please sign in to comment.