Giter Club home page Giter Club logo

tigrisdata-archive / tigris Goto Github PK

View Code? Open in Web Editor NEW
900.0 14.0 37.0 4.02 MB

Tigris is an Open Source Serverless NoSQL Database and Search Platform.

Home Page: https://www.tigrisdata.com/

License: Apache License 2.0

Makefile 0.23% Go 96.79% Shell 2.87% Dockerfile 0.10%
database data golang kubernetes real-time consensus go streaming transactional-database search foundationdb search-engine elasticsearch open-source opensearch dynamodb mongodb

tigris's Introduction

Tigris

Tigris is a Serverless NoSQL Database and Search Platform that offers an open source alternative to MongoDB and DynamoDB. Tigris is built on FoundationDB and combines the consistency of ACID transactions with the scale and flexibility of NoSQL, at a fraction of the cost.

Go Report Build Status Contributor Covenant

Website | Quickstart | API Reference | Discord | Twitter

Helpful Links

Community & Support

Developing

Setup local development environment

To setup your local development environment. Make sure you have Go installed or run:

sh scripts/install_go.sh

Add your $GOPATH to your $PATHS environment variable. And then to download and install the build dependencies and FoundationDB run:

sh scripts/install_build_deps.sh

Building with Docker Containers

Start local Tigris server listening on http://localhost:8081 by running:

make run

This would bring dependencies and server up in the docker containers with all your changes.

Alternatively, you can run make run_full to bring up monitoring tools as well.

Running tests

Run in the docker container

Tests are executed using make test. This runs both unit and integration tests in the docker containers.

Run in the IDE

Run make run to bring the server up in the docker container. Now you can run individual tests in the IDE of your choice. Entire test suite can be run using make local_test.

Debugging the server in the IDE

Run make local_run to start Tigris server on the host. Now you can attach to the process and debug from the IDE.

License

This software is licensed under the Apache 2.0.

tigris's People

Contributors

adilansari avatar akhill10 avatar dependabot[bot] avatar efirs avatar garrensmith avatar himank avatar jigarjoshi avatar karuppiah7890 avatar marcelosousa avatar mattayres avatar ovaistariq avatar pboros avatar rbarabas avatar tanay1337 avatar terbepetra avatar tigrisdata-argocd-bot avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

tigris's Issues

Request stickiness for transactional APIs

The requests in the context of a transaction must go to the same app worker.

Forwarding logic will be implemented on the server so that the request is forwarded to the correct app worker.

Database creation in parallel

Describe the bug
For tests, I run several requests to create databases in parallel.
Sometimes the error for database creation is nil however database is absent.
Sometimes the error does appear.

To Reproduce

  1. put files in one folder, run go mod tidy
  2. run go test -count=1 ./...

Expected behavior
Expected 3 databases to be present:

skydancer:~/tigriscli$ tigris list databases
testthree
testtwo
testone

Screenshots
Instead, the error appears:

skydancer:~/tigriscli$ go test -count=1 ./... 
--- FAIL: TestThree (0.01s)
    tigriscli_test.go:37: recreate db testthree
    tigriscli_test.go:40: 
        	Error Trace:	tigriscli_test.go:40
        	            				tigriscli_test.go:25
        	Error:      	Received unexpected error:
        	            	database already exist
        	Test:       	TestThree
FAIL
FAIL	tigriscli	0.054s
FAIL

and the databases list if not full,

skydancer:~/tigriscli$ tigris list databases
testthree
testtwo

The name of the absent database testone is not the testthree that appeared in the error message.

Desktop (please complete the following information):
Linux skydancer 5.11.0-49-generic #55-Ubuntu SMP Wed Jan 12 17:36:34 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

Additional context

  • cli tigris version v1.0.0-alpha.8
  • tigris container date docker inspect --format '{{ .Created }}' tigrisdata/tigris:latest 2022-05-04T01:53:00.992143876Z
  • github.com/tigrisdata/tigris-client-go v1.0.0-alpha.10

Expose the size of the collection

Is your feature request related to a problem? Please describe.
It's a feature request to let know the collection size

Describe the solution you'd like

  • Approximate or precise size of the collection in the in a new method totalSize in a /api/v1/databases/{db}/collections/{collection}/ namespace
  • Includes all: indexes, keys, fields, etc.
  • Implementations in the tigrisdb and support it in the client

Describe alternatives you've considered

  • Just to start a 0 value can be returned. The actual size value can be added later.
  • Give a size value in the ListCollectionsResponse method is not really meant for presenting the size information

Additional context

Set `"additionalProperties": false` by default

Description
It's a feature request.
If one inserts data with scheme that differs from the collection creation call, by default, the tigris server allows to do so.
It's must have been impossible to do so, because it's impossible to read data after that in the gRPC client.
But it did.

Describe the solution you'd like

Set "additionalProperties": false by default.

Describe alternatives you've considered

However, tigris-cli allows to read data afterwards, maybe the solution is to make it possible to read data in gRPC client afterwards? But how, taking into account that there must be strict values (use json.RawMessage?).

Additional context

Add any other context or screenshots about the feature request here.

Error `DatabaseNotFound` for collection and database requests

Is your feature request related to a problem? Please describe.

It's a feature request to add details / change the error code to distinguish whether the collection not found or the database not found in:

  • collection requests (read, update, replace, delete documents) and in the
  • database requests (list collections, drop, create or update collections)

Describe the solution you'd like

Preferably using https://pkg.go.dev/google.golang.org/genproto/googleapis/rpc/status#Status and standardized details.
https://cloud.google.com/apis/design/errors#error_details

Describe alternatives you've considered

In the current solution the gRPC code codes.InvalidArgument hides this details

server/services/v1/query_runner.go-123		
     return nil, api.Errorf(codes.InvalidArgument, "database doesn't exists '%s'", dbName)

It's not convenient to parse string "database doesn't exists '%s'" which would vary from database to database and can be easily changed by developers.

Additional context

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.