0.6.0 • Published 1 year ago

@moirae/typeorm v0.6.0

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

@moirae/typeorm

A Moirae plugin leveraging a SQL database providing:

  • EventStore: entity model for the database table
  • TypeORMStore: overriding the default EVENT_STORE token

  • KeyValue: entity model for a key-value cache

  • SetRoot/SetValue: entity models for a set cache
  • TypeORMCache: overriding the default CACHE token

Compatibility

The following have been tested with Moirae and are known to be compatible.

  • sqlite3
  • postgresql

Usage

When using this module, it's required to explicitly import TypeOrmModule.forFeature(<EntityArr>) into the Moirae config. The <EntityArr> should contain:

  • The EventStore entity if using TypeORM as an event store
  • The CACHE_ENTITIES array if using TypeORM as a cache

The TypeORM plugin may be used as an event store, a cache, or both.

MoiraeModule.forRootAsync({
    cache: {
        type: "typeorm",
    },
    imports: [TypeOrmModule.forFeature([EventStore, CACHE_ENTITIES])],
    store: {
        type: "typeorm",
    }
})
0.6.0

1 year ago

0.5.3

2 years ago

0.4.1

2 years ago

0.4.2

2 years ago

0.3.1

2 years ago

0.3.0

2 years ago

0.2.2

2 years ago

0.2.0

2 years ago

0.1.0

2 years ago