• Stars
    star
    335
  • Rank 124,914 (Top 3 %)
  • Language
    Clojure
  • License
    Other
  • Created almost 4 years ago
  • Updated about 1 month ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Fluree database library

Fluree DB

Usage documentation is located at https://docs.flur.ee.

Overview

Fluree is an immutable, temporal, ledger-backed semantic graph database that has a cloud-native architecture.

This repository is a stateless database as a library and designed to be utilized in conjunction with the Fluree Ledger which maintains all state. This database can be run in containers and dynamically scale to any desired load, can be embedded inside of your applications (Clojure, NodeJS for now) or can run as a stand-alone JVM service.

This database can also be built as a web-worker, and be embedded inside the browser. Thus far, a React Wrapper (Beta) has been developed that allows you to create real-time apps by wrapping your React components with queries (GraphQL or FlureeQL).

It is also possible to run Fluree in a "serverless" manner, where by utilizing Fluree SmartFunctions to embed data security along side your data (Data Defending Itself), you can have a permissioned application with just a single-page application (i.e. React) and Fluree Ledgers, but no application server.

Fluree includes time travel, allowing you to instantly query as of any historical moment in time, and even allows the abilty to stage proposed transactions to time travel into the future, to a hypothesized version of your data.

The best way to get started with Fluree is to go to the Getting Started page at https://flur.ee/getstarted/.

Development

Contributing

All contributors must complete a Contributor License Agreement.

Prerequisites

  1. Install clojure tools-deps (version 1.10.3.933 or later).
    1. macOS: brew install clojure/tools/clojure
    2. Arch Linux: pacman -S clojure
  2. Install Node & NPM
    1. macOS: brew install node
    2. Arch Linux: pacman -S nodejs
  3. Install babashka
    1. macOS: brew install borkdude/brew/babashka

Building

NOTE: use make -j to run tasks in parallel.

  • make deps - install all local dependencies

  • make - make everything below

  • make jar - make Java JAR file

  • make nodejs - make JavaScript Fluree DB for Node

  • make browser - make JavaScript Fluree DB for browsers

  • make webworker - make JavaScript Fluree DB for web worker

  • make install - install jar file into local .m2/maven

  • make clean - clean all build directories/files

Tests

  • make test - run all automated tests below
  • make cljtest - run all CLJ tests
  • make cljstest - run CLJS tests in headless Chrome & NodeJS
  • make cljs-browser-test - run CLJS tests in headless Chrome
    • Needs karma-cli installed globally: npm install -g karma-cli
    • Needs Google Chrome browser installed
  • make cljs-node-test - run CLJS tests in NodeJS
  • make nodejs-test - run node package in node
  • make browser-test - run browser package in headless Chrome

Running specific tests

This applies to CLJ tests only, not CLJS.

clojure -X:cljtest :kaocha.filter/focus [focus-spec]

...where focus-spec can be a test namespace or a fully-qualified deftest var. Note that the square brackets around the focus-spec must be present in the command, they are NOT there to indicate "optional" or "placeholder" in the example.

This feature comes from the test runner kaocha which has additional features.

CLJS REPL

In order to get a Node or web browser CLJS REPL running, you need to do the following:

  1. Run npx shadow-cljs watch flureenjs (or flureedb for a browser REPL)
  2. (Node only) Run node out/nodejs/flureenjs.js in a separate shell
  3. (browser only) Connect to http://localhost:9630/ in your browser
    1. This seems currently broken though. It first gets stuck at "shadow-cljs Loading..." with an "unknown route" error in the JS console. If you reload that seems to resolve. But even once the dashboard loads and you connect a REPL, it says "No available JS runtime."
  4. Connect an nREPL to the port specified in .shadow-cljs/nrepl.port
  5. Inside that REPL run (shadow/repl :flureenjs) (or :flureedb for a browser REPL)
  6. Try running something CLJS-specific to ensure you've got a working CLJS REPL
    1. For example: (js/parseInt "42")

More Repositories

1

ledger

Fluree ledger server source
Clojure
78
star
2

developer-hub

A repository showcasing Fluree-backed demos
31
star
3

example-zero-knowledge

This Github repo demonstrates how one could set up a Fluree ledger to use zero-knowledge proofs.
JavaScript
28
star
4

fluree.crypto

Clojure(script) Cryptography used by Fluree
Clojure
20
star
5

raft

Raft as a library. Includes optional capabilities from the Raft whitepaper, such as snapshotting.
Clojure
20
star
6

json-ld

Clojure JSON-LD library
Clojure
17
star
7

fluree.cli

Terminal-based tool that allows users to verify Fluree ledger files, read consensus state, and more.
Clojure
10
star
8

http-api-gateway

Fluree 3 HTTP API server component
Clojure
9
star
9

server

Fluree Server - Operates Fluree in consensus, fault-tolerant, redundant
Clojure
9
star
10

to-do-lists-generator

JavaScript
9
star
11

js-react-wrapper

React wrapper for Fluree's JavaScript query engine
JavaScript
8
star
12

ledger-docker-compose-example

Simple example for creating a Fluree service in a Docker container
8
star
13

credentials-demo

A React App built to demo Fluree's credentials & identity management value
JavaScript
7
star
14

fluree-admin-ui

FlureeDB admin dashboard
JavaScript
6
star
15

crypto-utils

A collection of Javascript cryptography functions for Fluree
JavaScript
6
star
16

example-full-text-search

This mini-app uses Fluree's full-text capabilities to quickly through 25,000 recipes.
JavaScript
6
star
17

storj-fluree

This project provides a connection between Fluree and the decentrailed cloud storage network, Storj.
Go
6
star
18

smart-function-library

Library of Common Smart Functions
JavaScript
6
star
19

example-supply-chain

This repo demonstrates one way to use smart functions in Fluree to govern a supply chain process.
JavaScript
6
star
20

fluree-cli

Command line tool to manage Fluree data, local and remote
Clojure
5
star
21

dev-week-2024

JavaScript
5
star
22

vscode-fluree

A VS Code extension that connects to a single Fluree database, and allows you to issue queries, transaction, and tests against that database.
TypeScript
4
star
23

homebrew-flureedb

Homebrew tap for flureedb
Ruby
4
star
24

developers-site

Repo containing the docusaurus developers site for the fluree org
JavaScript
4
star
25

vector-db

Simple HNSW vector db in clojure
Clojure
4
star
26

example-s3-ledger

3
star
27

pod-fluree-crypto

Babashka pod for the fluree.crypto library
Clojure
3
star
28

f.template-react

Fluree React Template
JavaScript
3
star
29

kafka

Example of piping events from a Fluree ledger (new blocks) into a Kafka topic
Clojure
3
star
30

fql-react

React client for Fluree QL
JavaScript
3
star
31

fluree-nodejs-server

Bare-bones node.js application using the Fluree node.js library to access a downloaded Fluree instance
JavaScript
3
star
32

example-parts-tracking

JavaScript
2
star
33

flureenjs-listener-example

Example repo documenting use of the Fluree NodeJS library and it's listener() capability
JavaScript
2
star
34

node_demo_aws

JavaScript
2
star
35

fql-graphql

Conversion utility from graphql to FlureeQL
JavaScript
2
star
36

dataset-academic-credentials

Repository for code and artifacts for loading the Academic Credentials sample dataset into Fluree.
2
star
37

auth-pass-example

Example application showcasing Fluree's password authentication API
JavaScript
2
star
38

fluree-client

TypeScript
2
star
39

basic-react-template

Reusable template for a CMS SPA with forms/tables that transact/query with flureedb
JavaScript
2
star
40

terraform-example

An example of how to use Terraform to deploy Fluree as a 3-node transactor group against Docker
HCL
1
star
41

example-iam-mdm

JavaScript
1
star
42

docs.flur.ee

Fluree Docs
JavaScript
1
star
43

crypto-base

Base cryptography functions that are used in Fluree
HTML
1
star
44

fluree-react

Fluree React Wrapper
JavaScript
1
star
45

fluree-migrate

Rust
1
star
46

nexus-example-react-app

JavaScript
1
star
47

flurl

Command line Fluree ledger HTTP API client (like curl) that allows request signing
Clojure
1
star