dapr-sqlite-statestore

command module
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 17, 2022 License: Apache-2.0 Imports: 4 Imported by: 0

README

SQLite3 state store for Dapr

This project contains a pluggable component for using SQLite3 as a state store with Dapr.

Example usage

See the example folder for an example app and how to run the component.

Docker image

Published on GitHub Container Registry:

ghcr.io/italypaleale/dapr-sqlite-statestore:latest

Supported features

  • ✅ CRUD
  • ✅ Transactional
  • ✅ ETag
  • ✅ TTL
  • ✅ Actors
  • ❌ Query

Setup Dapr component

To setup a SQLite state store, create a component of type state.sqlite. See this guide on how to create and apply a state store configuration.

apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
  name: <NAME>
spec:
  type: state.sqlite
  version: v1
  metadata:
    - name: connectionString
      value: mysqlite.db

Spec metadata fields

Field Details Example
connectionString The connection string to connect to the database. Usually, that's just the path to a file on disk. If needed, you pass a DSN with the options listed in the docs for go-sqlite3 path-to-db.db
DSN: file:mydb.db?immutable=1
tableName Name of the table where to store data state
cleanupIntervalInSeconds Interval, in seconds, to purge expired records. Set to <=0 to disable. 1200 (20 minutes)

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL