Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

kurrent-io/gaffer

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

589 Commits
589 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Gaffer

Develop, test, debug, and deploy KurrentDB projections.

KurrentDB projections are server-side JavaScript that derive new streams and state from existing events. Gaffer uses the same JS engine as KurrentDB itself, so what you debug locally behaves like what runs in production.

Install

CLI:

npm i -g @kurrent/gaffer

VS Code extension - install KurrentDB Gaffer for run/debug from gaffer.toml, breakpoint debugging, and an auto-registered MCP server.

Test library:

npm i -D @kurrent/projections-testing

Quick start

Run a projection from the CLI:

gaffer dev order-count --fixture happy

gaffer dev replaying the order-count projection against the happy fixture

Or test it from your existing test suite:

import { createProjection } from "@kurrent/projections-testing";

const projection = createProjection<{ count: number }>(`
  fromAll().when({
    $init: () => ({ count: 0 }),
    OrderPlaced: (s) => ({ count: s.count + 1 }),
  });
`, { engineVersion: 2 });

for (const { state } of projection.run(events)) {
  // assert on state at each step
}

See the demo project for a complete example with fixtures, errors, partitioned state, and bi-state projections.

Packages

Component Package License
CLI @kurrent/gaffer Kurrent License v1
VS Code extension kurrent-io.gaffer-vscode Kurrent License v1
Test library @kurrent/projections-testing Apache 2.0
JS bindings @kurrent/gaffer-runtime Kurrent License v1
Go bindings github.com/kurrent-io/gaffer/bindings/go Kurrent License v1

Per-component LICENSE files live in each directory. See LICENSE_CONTRIBUTIONS.md for the license map and NOTICE.md for third-party attribution.

Communities

Contributing

See CONTRIBUTING.md for development setup and conventions. Bugs go to Issues; feature requests and questions to Discussions.

About

Dev toolkit for KurrentDB projections - local development, testing, debugging, and deployment.

Resources

Contributing

Security policy

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.