# workflow-es-mysql

> MySQL provider for Workflow ES

Latest version **1.0.0-beta.0** (published 2019-04-14) · MIT license · 0 weekly downloads

## Install

```sh
npm install workflow-es-mysql
pnpm add workflow-es-mysql
yarn add workflow-es-mysql
bun add workflow-es-mysql
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0-beta.0 |
| Published | 2019-04-14 |
| First published | 2019-04-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 5 |
| Unpacked size | 21.3 KB |
| Known vulnerabilities | 0 (+13 in 3 direct dependencies) |
| Install scripts | no |
| GitHub stars | 216 |
| Author | Carlos Ottoboni |
| Maintainers | danielgerlag |
| Keywords | workflow, mysql |

## Links

- npm: https://www.npmjs.com/package/workflow-es-mysql
- Repository: https://github.com/danielgerlag/workflow-es
- Homepage: https://github.com/danielgerlag/workflow-es#readme
- Issues: https://github.com/danielgerlag/workflow-es/issues
- npm.io page: https://npm.io/package/workflow-es-mysql

## Dependencies (5)

- [mysql2](https://npm.io/package/mysql2.md) ^1.6.4
- [sequelize](https://npm.io/package/sequelize.md) ^4.41.2
- [workflow-es](https://npm.io/package/workflow-es.md) ^2.3.2
- [reflect-metadata](https://npm.io/package/reflect-metadata.md) ^0.1.12
- [sequelize-typescript](https://npm.io/package/sequelize-typescript.md) ^0.6.6

## Recent versions

- 1.0.0-beta.0 (latest) — 2019-04-14

## README

# MySQL Persistence provider for Workflow ES

Provides support to persist workflows running on [Workflow ES](https://github.com/danielgerlag/workflow-es) to a MySQL database.

## Installing

Install the npm package "workflow-es-mysql"

```
> npm install workflow-es-mysql --save
```

## Usage

Use the .usePersistence() method when setting up your workflow host.

> Make sure you have a MySQL server running and a schema to be used by workflow-es

```javascript
const workflow_es = require("workflow-es");
const workflow_mysql = require("workflow-es-mysql");
...
var config = workflow_es.configureWorkflow();
let mySqlPersistence = new workflow_mysql.MySqlPersistence("mysql://root:password@localhost:port/workflow-node");
await mySqlPersistence.connect;
config.usePersistence(mySqlPersistence);
var host = config.getHost();
...
await host.start();
```

---
_Source: https://npm.io/package/workflow-es-mysql · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
