WJb Store Examples & Demos

Explore SQL Server, PostgreSQL, MySQL, SQLite, and IndexedDB integrations with persistence and workflow state management examples.

Browser Store Providers
SQL Store Providers

🐬 MySQL

Run WJb on MySQL using the official WJb.MySQL store provider.

MySQL gives you durable, transactional persistence for jobs, workflows, execution history, monitoring data, actions and service configuration — while keeping the exact same programming model as every other WJb store.

The WJb Monitor Demo runs identically on MySQL. Only the store registration changes.

Why MySQL?

  • One of the most popular open-source databases in the world
  • Excellent performance and reliability
  • Strong transactional support
  • Wide ecosystem and tooling
  • Easy to run locally, on-premises or in the cloud
  • Great choice for both development and production
Ideal when your team already uses MySQL or prefers a widely adopted open-source database.

What Is Stored?

The WJb.MySQL store persists everything the Monitor needs:

  • Jobs and their current state
  • Workflow transitions
  • Full execution history
  • Monitoring and progress data
  • Action definitions
  • Service configuration
All of this becomes immediately available in the monitoring dashboard.

How It Works

1. Create the WJb database schema (one-time):

   await WJbMySql.InitDbAsync(connectionString);

2. Register the store:

   builder.Services.AddSingleton<IStore>(_ => 
       new MySqlStore(() => new(connectionString)));

3. Use the rest of the application exactly as usual.

The connection string is normally taken from appsettings.json:

{
  "ConnectionStrings": {
    "MySql": "Server=YOUR_SERVER;Database=WJbDemo;Uid=YOUR_USER;Pwd=YOUR_PASS"
  }
}

Monitor Demo

This sample shows the complete WJb Monitor Demo running on MySQL with almost zero changes compared to other providers.

You get the same:

  • Background jobs & workflows
  • Live monitoring dashboard
  • Execution history
  • Retry handling
  • Action & service discovery
Only the storage backend is different.

Resources

An unhandled error has occurred. Reload 🗙

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.