Skip to content
This repository was archived by the owner on Jan 11, 2022. It is now read-only.

spawnfest/eArangoDB

Repository files navigation

earangodb

CI Status

Erlang CI codecov

Description

It aims to implement easy communication with ArangoDB database using its HTTP API. This library is written in Erlang so that it can be used from both Erlang and Elixir.

Documentation

Exdoc documentation is provided for this project here.

Installation

To rebar.config add:

{deps, [
    ....
    {earangodb, ".*", {git, "git://github.com/spawnfest/eArangoDB.git", {branch, "master"}}}
]}.

Configuration

There is one parameter to be configured, which is a map containing self explanatory keys: url, port, user and password.

To configure the earangodb connection, put this parameter in persistent term storage, as shown below.

In your_project_app.erl in start/2 just put:

start(_StartType, _StartArgs) ->
    ...
    EarangodbWorkerConfig = #{
        url => "localhost",
        port => 8529,
        user => <<"root">>,
        password => <<"test">>
    },
    persistent_term:put(earangodb_config, EarangodbWorkerConfig),
    {ok, _} = application:ensure_all_started(earangodb),
    ...

You may alternatively put this code under a separate supervisor's init.

DEMO

To see the demo use case of this lib by going to: demo/demo_cities/README.md

About

SpawnFest 2021

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors