This respository contains database configuration for ArangoDB database for your Go project along with base-crud, creation of Collections, Graphs (coming soon) Custom Analyzers, Views, Query Executor and DB Transaction
-
go-driver: The go-driver is leveraged to provide the functionality a user might need.
-
viper: is used to read config from environment variables.
-
logrus: is used for logging so that you can further make use of extended functionality of the logrus package in case you might want to set the formatting levels, make your logs more verbose.
Note: logrus can be omitted if you feel the need to.
The default incorporated functionalities that comes along are:
- Creation of Databases and corresponding users
- Creation of Collections,Custom Analyzer and Views at the startup (preferably)
- Query Executor for Execution of raw AQL queries
- QueryExecutor with cursor full count while executing raw AQL queries
- Initializing a DB Transaction
- Delayed
- Add tests for every function (Unit tests)
- Add creation of Graphs
- Add different analyzer types (like norm, ngram, pipeline etc)
- Include Edit View functionality (ArangoDB does not support editing the views by default)
- Improve documentation and code structure
- Add scripts for backing up data
-
Clone the repository at your preferred location:
git clone https://github.com/aaqibb13/guinevere.git
-
Run:
go mod tidy
-
You're ready to use the base setup.
-
Make sure you have docker installed on your system (based on which machine you're on:
Linux
,Mac
orWindows
) -
cd into
guinevere/deployments
and run:docker-compose -f arango-docker-compose.yml up --build -d db
-
You should be able to view the ArangoDB server running on
127.0.0.1:8529
which you can access using the credentials specified in thearango-docker-compose.yml
file.