@veridid/workflow-parser 0.4.0 → 0.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (58) hide show
  1. package/dist/db.js +40 -0
  2. package/dist/dbCrud.js +210 -0
  3. package/dist/index.js +22 -0
  4. package/dist/parser.js +125 -0
  5. package/{src/support/Schema.sql → dist/schema.sql} +2 -2
  6. package/dist/src/implementations/action.default.js +82 -0
  7. package/dist/src/implementations/action.default.js.map +1 -0
  8. package/dist/src/implementations/display.default.js +93 -0
  9. package/dist/src/implementations/display.default.js.map +1 -0
  10. package/dist/src/implementations/workflow.default.js +79 -0
  11. package/dist/src/implementations/workflow.default.js.map +1 -0
  12. package/{src → dist/src}/index.js +1 -0
  13. package/dist/src/index.js.map +1 -0
  14. package/{src → dist/src}/interfaces/actionextension.js +1 -0
  15. package/dist/src/interfaces/actionextension.js.map +1 -0
  16. package/{src → dist/src}/interfaces/actioninterface.js +1 -0
  17. package/dist/src/interfaces/actioninterface.js.map +1 -0
  18. package/{src → dist/src}/interfaces/displayextension.js +1 -0
  19. package/dist/src/interfaces/displayextension.js.map +1 -0
  20. package/{src → dist/src}/interfaces/displayinterface.js +1 -0
  21. package/dist/src/interfaces/displayinterface.js.map +1 -0
  22. package/{src → dist/src}/interfaces/workflowinterface.js +1 -0
  23. package/dist/src/interfaces/workflowinterface.js.map +1 -0
  24. package/dist/src/workflowparser.js +59 -0
  25. package/dist/src/workflowparser.js.map +1 -0
  26. package/dist/test/action.extension.js +34 -0
  27. package/dist/test/action.extension.js.map +1 -0
  28. package/dist/test/display.extension.js +29 -0
  29. package/dist/test/display.extension.js.map +1 -0
  30. package/dist/test/test.js +178 -0
  31. package/dist/test/test.js.map +1 -0
  32. package/{test → dist/test}/testworkflows.json +8 -10
  33. package/package.json +8 -3
  34. package/src/implementations/action.default.js +0 -114
  35. package/src/implementations/action.default.ts +0 -74
  36. package/src/implementations/display.default.js +0 -132
  37. package/src/implementations/display.default.ts +0 -98
  38. package/src/implementations/workflow.default.js +0 -146
  39. package/src/implementations/workflow.default.ts +0 -64
  40. package/src/index.ts +0 -6
  41. package/src/interfaces/actionextension.ts +0 -7
  42. package/src/interfaces/actioninterface.ts +0 -11
  43. package/src/interfaces/displayextension.ts +0 -7
  44. package/src/interfaces/displayinterface.ts +0 -13
  45. package/src/interfaces/workflowinterface.ts +0 -24
  46. package/src/workflowparser.js +0 -100
  47. package/src/workflowparser.ts +0 -70
  48. package/test/action.extension.js +0 -65
  49. package/test/action.extension.ts +0 -22
  50. package/test/display.extension.js +0 -60
  51. package/test/display.extension.ts +0 -16
  52. package/test/docker-compose.yml +0 -33
  53. package/test/pg_hba.conf +0 -14
  54. package/test/postgresql.conf +0 -42
  55. package/test/tables.sql +0 -17
  56. package/test/test.js +0 -233
  57. package/test/test.ts +0 -159
  58. package/tsconfig.json +0 -15
@@ -1,7 +0,0 @@
1
- import { Instance, IWorkflow, Workflow } from "./workflowinterface";
2
- import { IAction, Transition } from "./actioninterface"
3
-
4
-
5
- export interface IDisplayExtension {
6
- displays: (instance: Instance, template: any) => Promise<any>;
7
- }
@@ -1,13 +0,0 @@
1
- import { Workflow, Instance } from "./workflowinterface";
2
-
3
- export interface IDisplay {
4
- processDisplay: (
5
- clientID: string,
6
- curentWorkflow: Workflow,
7
- instance: Instance,
8
- currentState: string) => Promise<DisplayData>;
9
- }
10
-
11
- export interface DisplayData {
12
- displayData: any[]
13
- }
@@ -1,24 +0,0 @@
1
- export interface IWorkflow {
2
-
3
- getWorkflowByID: (workflowID: string) => Promise<Workflow>;
4
- getInstanceByID: (workflowID: string, clientID: string) => Promise<Instance>;
5
- updateInstanceByID: (clientID: string, workflowID: string, stateID: string, data: any) => Promise<Instance>;
6
- newInstance: (clientID: string, workflowID: string, stateID: string, data: any) => Promise<Instance>;
7
-
8
- }
9
-
10
- export interface Workflow {
11
- workflow_id: string;
12
- name: string;
13
- initial_state: string;
14
- render: any[];
15
- states: [{state_id: string, display_data: any, actions: any, transitions: any}]
16
- }
17
-
18
- export interface Instance {
19
- instance_id: string;
20
- workflow_id: string;
21
- client_id: string,
22
- current_state: string;
23
- state_data: any;
24
- }
@@ -1,100 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- var __generator = (this && this.__generator) || function (thisArg, body) {
12
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
13
- return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
14
- function verb(n) { return function (v) { return step([n, v]); }; }
15
- function step(op) {
16
- if (f) throw new TypeError("Generator is already executing.");
17
- while (g && (g = 0, op[0] && (_ = 0)), _) try {
18
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
19
- if (y = 0, t) op = [op[0] & 2, t.value];
20
- switch (op[0]) {
21
- case 0: case 1: t = op; break;
22
- case 4: _.label++; return { value: op[1], done: false };
23
- case 5: _.label++; y = op[1]; op = [0]; continue;
24
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
25
- default:
26
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
27
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
28
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
29
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
30
- if (t[2]) _.ops.pop();
31
- _.trys.pop(); continue;
32
- }
33
- op = body.call(thisArg, _);
34
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
35
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
36
- }
37
- };
38
- Object.defineProperty(exports, "__esModule", { value: true });
39
- exports.WorkflowParser = void 0;
40
- var WorkflowParser = /** @class */ (function () {
41
- function WorkflowParser(display, action, workflow) {
42
- this.display = display;
43
- this.action = action;
44
- this.workflow = workflow;
45
- }
46
- WorkflowParser.prototype.parse = function (clientID, action) {
47
- return __awaiter(this, void 0, void 0, function () {
48
- var curentWorkflow, instance, currentState, transition, updatedInstance, display;
49
- return __generator(this, function (_a) {
50
- switch (_a.label) {
51
- case 0:
52
- console.log("=== parse clientID=", clientID, " action=", action);
53
- return [4 /*yield*/, this.workflow.getWorkflowByID(action === null || action === void 0 ? void 0 : action.workflowID)];
54
- case 1:
55
- curentWorkflow = _a.sent();
56
- console.log("+++ currentWorkflow");
57
- return [4 /*yield*/, this.workflow.getInstanceByID(clientID, action === null || action === void 0 ? void 0 : action.workflowID)];
58
- case 2:
59
- instance = _a.sent();
60
- console.log("+++ instance");
61
- currentState = instance.current_state;
62
- return [4 /*yield*/, this.action.processAction(curentWorkflow, instance, action)];
63
- case 3:
64
- transition = _a.sent();
65
- console.log("+++ transition");
66
- if (!(transition.type != "none")) return [3 /*break*/, 7];
67
- if (!(transition.type === 'workflowTransition')) return [3 /*break*/, 6];
68
- return [4 /*yield*/, this.workflow.getWorkflowByID(transition === null || transition === void 0 ? void 0 : transition.workflow_id)];
69
- case 4:
70
- // get the new workflow
71
- curentWorkflow = _a.sent();
72
- return [4 /*yield*/, this.workflow.getInstanceByID(clientID, transition === null || transition === void 0 ? void 0 : transition.workflow_id)];
73
- case 5:
74
- // get the new instance
75
- instance = _a.sent();
76
- currentState = instance.current_state;
77
- _a.label = 6;
78
- case 6:
79
- if (transition.type === 'stateTransition') {
80
- // set the new current state
81
- currentState = transition.state_id;
82
- }
83
- _a.label = 7;
84
- case 7: return [4 /*yield*/, this.workflow.updateInstanceByID(clientID, curentWorkflow.workflow_id, currentState, instance.state_data)];
85
- case 8:
86
- updatedInstance = _a.sent();
87
- console.log("+++ Updated instance");
88
- return [4 /*yield*/, this.display.processDisplay(clientID, curentWorkflow, updatedInstance, currentState)];
89
- case 9:
90
- display = _a.sent();
91
- console.log("+++ Prcoessed display");
92
- // return workflowID and display
93
- return [2 /*return*/, { workflowID: curentWorkflow.workflow_id, displayData: display.displayData }];
94
- }
95
- });
96
- });
97
- };
98
- return WorkflowParser;
99
- }());
100
- exports.WorkflowParser = WorkflowParser;
@@ -1,70 +0,0 @@
1
- import { IDisplay } from "./interfaces/displayinterface";
2
- import { IAction } from "./interfaces/actioninterface";
3
- import { IWorkflow } from "./interfaces/workflowinterface";
4
-
5
- export class WorkflowParser {
6
- display: IDisplay;
7
- action: IAction;
8
- workflow: IWorkflow;
9
-
10
- constructor(
11
- display: IDisplay,
12
- action: IAction,
13
- workflow: IWorkflow
14
- ) {
15
- this.display = display;
16
- this.action = action;
17
- this.workflow = workflow;
18
- }
19
-
20
- async parse(
21
- clientID: string,
22
- action: {
23
- workflowID: string;
24
- actionID: string;
25
- data?: any }
26
- ): Promise<any> {
27
- console.log("=== parse clientID=", clientID, " action=", action);
28
-
29
- // get the workflow as JSON
30
- let curentWorkflow = await this.workflow.getWorkflowByID(action?.workflowID);
31
- console.log("+++ currentWorkflow");
32
-
33
- // get the instance as JSON
34
- let instance = await this.workflow.getInstanceByID(clientID, action?.workflowID);
35
- console.log("+++ instance");
36
-
37
- // current state in the workflow
38
- let currentState = instance.current_state;
39
-
40
- // process the action
41
- let transition = await this.action.processAction(curentWorkflow, instance, action);
42
- console.log("+++ transition");
43
-
44
- if(transition.type != "none") {
45
- // process the transition
46
- if(transition.type === 'workflowTransition') {
47
- // get the new workflow
48
- curentWorkflow = await this.workflow.getWorkflowByID(transition?.workflow_id);
49
- // get the new instance
50
- instance = await this.workflow.getInstanceByID(clientID, transition?.workflow_id);
51
- currentState = instance.current_state;
52
- }
53
- if(transition.type === 'stateTransition') {
54
- // set the new current state
55
- currentState = transition.state_id;
56
- }
57
- }
58
-
59
- // update the instance
60
- const updatedInstance = await this.workflow.updateInstanceByID(clientID, curentWorkflow.workflow_id, currentState, instance.state_data);
61
- console.log("+++ Updated instance");
62
-
63
- // process the display
64
- const display = await this.display.processDisplay(clientID, curentWorkflow, updatedInstance, currentState)
65
- console.log("+++ Prcoessed display");
66
-
67
- // return workflowID and display
68
- return {workflowID: curentWorkflow.workflow_id, displayData: display.displayData};
69
- }
70
- }
@@ -1,65 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- var __generator = (this && this.__generator) || function (thisArg, body) {
12
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
13
- return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
14
- function verb(n) { return function (v) { return step([n, v]); }; }
15
- function step(op) {
16
- if (f) throw new TypeError("Generator is already executing.");
17
- while (g && (g = 0, op[0] && (_ = 0)), _) try {
18
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
19
- if (y = 0, t) op = [op[0] & 2, t.value];
20
- switch (op[0]) {
21
- case 0: case 1: t = op; break;
22
- case 4: _.label++; return { value: op[1], done: false };
23
- case 5: _.label++; y = op[1]; op = [0]; continue;
24
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
25
- default:
26
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
27
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
28
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
29
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
30
- if (t[2]) _.ops.pop();
31
- _.trys.pop(); continue;
32
- }
33
- op = body.call(thisArg, _);
34
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
35
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
36
- }
37
- };
38
- Object.defineProperty(exports, "__esModule", { value: true });
39
- exports.ExtendedAction = void 0;
40
- var ExtendedAction = /** @class */ (function () {
41
- function ExtendedAction() {
42
- }
43
- ExtendedAction.prototype.actions = function (actionInput, instance, action, transition) {
44
- return __awaiter(this, void 0, void 0, function () {
45
- return __generator(this, function (_a) {
46
- console.log("^^^ Extension -> actions");
47
- // handle the types of actions
48
- switch (action === null || action === void 0 ? void 0 : action.type) {
49
- case "extension":
50
- // check condition
51
- if (eval(action.condition)) {
52
- // save the data from the workflow action to the instance data
53
- instance.state_data = Object.assign(instance.state_data, action.value);
54
- }
55
- break;
56
- default:
57
- }
58
- return [2 /*return*/, transition];
59
- });
60
- });
61
- };
62
- ;
63
- return ExtendedAction;
64
- }());
65
- exports.ExtendedAction = ExtendedAction;
@@ -1,22 +0,0 @@
1
- import { IActionExtension } from "../src/interfaces/actionextension";
2
- import { Transition } from "../src/interfaces/actioninterface";
3
- import { Instance, Workflow } from "../src/interfaces/workflowinterface";
4
-
5
- export class ExtendedAction implements IActionExtension {
6
- async actions(actionInput: any, instance: Instance, action: any, transition: Transition): Promise<Transition>{
7
- console.log("^^^ Extension -> actions");
8
- // handle the types of actions
9
- switch(action?.type) {
10
- case "extension":
11
- // check condition
12
- if(eval(action.condition)) {
13
- // save the data from the workflow action to the instance data
14
- instance.state_data = Object.assign(instance.state_data, action.value);
15
- }
16
- break;
17
- default:
18
- }
19
-
20
- return transition;
21
- };
22
- }
@@ -1,60 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- var __generator = (this && this.__generator) || function (thisArg, body) {
12
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
13
- return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
14
- function verb(n) { return function (v) { return step([n, v]); }; }
15
- function step(op) {
16
- if (f) throw new TypeError("Generator is already executing.");
17
- while (g && (g = 0, op[0] && (_ = 0)), _) try {
18
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
19
- if (y = 0, t) op = [op[0] & 2, t.value];
20
- switch (op[0]) {
21
- case 0: case 1: t = op; break;
22
- case 4: _.label++; return { value: op[1], done: false };
23
- case 5: _.label++; y = op[1]; op = [0]; continue;
24
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
25
- default:
26
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
27
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
28
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
29
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
30
- if (t[2]) _.ops.pop();
31
- _.trys.pop(); continue;
32
- }
33
- op = body.call(thisArg, _);
34
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
35
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
36
- }
37
- };
38
- Object.defineProperty(exports, "__esModule", { value: true });
39
- exports.ExtendedDisplay = void 0;
40
- var ExtendedDisplay = /** @class */ (function () {
41
- function ExtendedDisplay() {
42
- }
43
- ExtendedDisplay.prototype.displays = function (instance, template) {
44
- return __awaiter(this, void 0, void 0, function () {
45
- return __generator(this, function (_a) {
46
- console.log("^^^ Extension -> displays");
47
- // handle the types of actions
48
- switch (template.type) {
49
- case "extended":
50
- template.text = "Extended display render!!";
51
- break;
52
- }
53
- return [2 /*return*/, template];
54
- });
55
- });
56
- };
57
- ;
58
- return ExtendedDisplay;
59
- }());
60
- exports.ExtendedDisplay = ExtendedDisplay;
@@ -1,16 +0,0 @@
1
- import { Transition } from "../src/interfaces/actioninterface";
2
- import { IDisplayExtension } from "../src/interfaces/displayextension";
3
- import { Instance, Workflow } from "../src/interfaces/workflowinterface";
4
-
5
- export class ExtendedDisplay implements IDisplayExtension {
6
- async displays(instance: Instance, template: any): Promise<any>{
7
- console.log("^^^ Extension -> displays");
8
- // handle the types of actions
9
- switch(template.type) {
10
- case "extended":
11
- template.text= "Extended display render!!";
12
- break;
13
- }
14
- return template;
15
- };
16
- }
@@ -1,33 +0,0 @@
1
- version: '3.8'
2
- services:
3
- postgres:
4
- container_name: container-pg
5
- image: postgres:16.2
6
- command: -c config_file=/etc/postgresql.conf
7
- hostname: localhost
8
- ports:
9
- - "5432:5432"
10
- environment:
11
- POSTGRES_USER: admin
12
- POSTGRES_PASSWORD: root
13
- POSTGRES_DB: test_workflows
14
- volumes:
15
- - postgres-data:/var/lib/postgresql/data
16
- - ./postgresql.conf:/etc/postgresql.conf
17
- - ./pg_hba.conf:/etc/pg_hba.conf
18
- restart: unless-stopped
19
-
20
- pgadmin:
21
- container_name: container-pgadmin
22
- image: dpage/pgadmin4
23
- depends_on:
24
- - postgres
25
- ports:
26
- - "5050:80"
27
- environment:
28
- PGADMIN_DEFAULT_EMAIL: admin@admin.com
29
- PGADMIN_DEFAULT_PASSWORD: root
30
- restart: unless-stopped
31
-
32
- volumes:
33
- postgres-data:
package/test/pg_hba.conf DELETED
@@ -1,14 +0,0 @@
1
- # TYPE DATABASE USER ADDRESS METHOD
2
-
3
- # "local" is for Unix domain socket connections only
4
- local all all trust
5
- # IPv4 local connections:
6
- host all all 0.0.0.0/0 trust
7
- host all all all trust
8
- # IPv6 local connections:
9
- host all all ::1/128 trust
10
- # Allow replication connections from localhost, by a user with the
11
- # replication privilege.
12
- #local replication postgres trust
13
- #host replication postgres 127.0.0.1/32 trust
14
- #host replication postgres ::1/128 trust
@@ -1,42 +0,0 @@
1
- #------------------------------------------------------------------------------
2
- # FILE LOCATIONS
3
- #------------------------------------------------------------------------------
4
-
5
- # The default values of these variables are driven from the -D command-line
6
- # option or PGDATA environment variable, represented here as ConfigDir.
7
-
8
- #data_directory = 'ConfigDir' # use data in another directory
9
- # (change requires restart)
10
- hba_file = '/etc/pg_hba.conf' # host-based authentication file
11
- # (change requires restart)
12
- #ident_file = 'ConfigDir/pg_ident.conf' # ident configuration file
13
- # (change requires restart)
14
-
15
- # If external_pid_file is not explicitly set, no extra PID file is written.
16
- #external_pid_file = '' # write an extra PID file
17
- # (change requires restart)
18
-
19
-
20
- #------------------------------------------------------------------------------
21
- # CONNECTIONS AND AUTHENTICATION
22
- #------------------------------------------------------------------------------
23
-
24
- # - Connection Settings -
25
-
26
- listen_addresses = '*' # what IP address(es) to listen on;
27
- # comma-separated list of addresses;
28
- # defaults to 'localhost'; use '*' for all
29
- # (change requires restart)
30
- port = 5432 # (change requires restart)
31
- #max_connections = 100 # (change requires restart)
32
- #reserved_connections = 0 # (change requires restart)
33
- #superuser_reserved_connections = 3 # (change requires restart)
34
- #unix_socket_directories = '/tmp' # comma-separated list of directories
35
- # (change requires restart)
36
- #unix_socket_group = '' # (change requires restart)
37
- #unix_socket_permissions = 0777 # begin with 0 to use octal notation
38
- # (change requires restart)
39
- #bonjour = off # advertise server via Bonjour
40
- # (change requires restart)
41
- #bonjour_name = '' # defaults to the computer name
42
- # (change requires restart)
package/test/tables.sql DELETED
@@ -1,17 +0,0 @@
1
- CREATE TABLE workflows (
2
- workflowID VARCHAR(255) PRIMARY KEY,
3
- name VARCHAR(255),
4
- formatVersion VARCHAR(50),
5
- initialState VARCHAR(255),
6
- render JSONB,
7
- states JSONB
8
- );
9
-
10
- CREATE TABLE instances (
11
- instanceID UUID PRIMARY KEY DEFAULT gen_random_uuid(),
12
- workflowID VARCHAR(255),
13
- clientID VARCHAR(255),
14
- connectionID VARCHAR(255),
15
- currentState VARCHAR(255),
16
- stateData JSONB
17
- );