Create an ArangoDB cluster on Google Compute Engine with a single command

Last week we’ve released the first version of our new deployment tool for cloud computing platforms with Digital Ocean support. (Edit: now also available: Amazon Web Services) Today we show how to deploy an ArangoDB cluster on Google Compute Engine with a single command.

Google Compute Engine

To easy-deploy an ArangoDB cluster on Google Compute Engine you just need to install the official gcloud tool, download a single bash script and watch the tool take care of the rest for you.

wget https://raw.githubusercontent.com/ArangoDB/deployment/publish/GoogleComputeEngine_ArangoDB_Cluster.sh
chmod 755 GoogleComputeEngine_ArangoDB_Cluster.sh

Google Compute Engine prerequisites

The script needs an available and configured Google Project.

ProjectID
  • Create a project (GCE Projects).
  • Remember your project-id, you’ll need that later for gcloud configuration.
  • Enable Google Compute Engine API (more…)
More info...

ArangoDB Release Candidate: Testing New Features & Stability

How often did you typed

var db = require("internal").db;

in the arangod console?

If you are familiar with the arangosh JavasScript shell than you probably use a custom .arangosh.rc startup script in your home-directory which defines your own extra variables and functions that you need often.

Now we’ve also added support for a file .arangod.rc that will be executed on server start. For example, you could put the following into the .arangod.rc file:

internal = require("internal");
fs = require("fs");
db = internal.db;
time = internal.time;
timed = function (cb) {
  var s  = time(); 
  cb();
  return time() - s;
};
print = internal.print;

You’ll never have to go through the history again to add your favourite function again. (Available in devel-branch, coming to the next releases soon).

More info...

Git Commit Analysis with ArangoDB: Insightful Data Exploration

I often find myself searching for certain commits using git log and friends. While I really love the power and flexibility that come with the git and other Unix command-line tools, sometimes it can be more convenient to use a database to filter and aggregate commit data.

I gave it a quick try yesterday and imported the commit history of ArangoDB’s Git repository into ArangoDB and ran some queries on the data.

// retrieving number of commits per month / year
query = 'FOR commit IN commits 
           COLLECT year = DATE_YEAR(commit.date), month = DATE_MONTH(commit.date) 
           WITH COUNT INTO count 
         RETURN { month: CONCAT(year, "/", month), count: count }';
db._query(query).toArray();

While the query results for our repository may not be interesting for everyone, I think it is still worth sharing what I did. Even though I didn’t try it, I think the overall procedure is applicable with any other Git repository.

More queries and how to convert and import Git commits in ArangoDB: Read on in Jan’s Blog

More info...

Running ArangoDB Made Simple: Step-by-Step Guide

docker run -p 8529:8529 arangodb/arangodb

I’ve created an automated build repository on docker, so that you can easily start a docker container with the latest stable release. If you miss anything in the container, please let me know. Thanks to frodenas, hipertracker, joaodubas, webwurst who also created dockerfiles.

ArangoDB

A distributed open-source database with a flexible data model for documents, graphs, and key-values. Build high performance applications using a convenient sql-like query language or JavaScript extensions.

Start a ArangoDB instance

In order to start an ArangoDB instance run

unix> docker run --name arangodb-instance -d arangodb/arangodb

By default ArangoDB listen on port 8529 for request and the image includes EXPOST 8529. If you link an application container, it is automatically available in the linked container. See the following examples. (more…)

More info...

ArangoDB Cookbook: Recipes for Database Optimization

It’s new – and just for you! With the new ArangoDB Cookbook we want to guide you thru various challenges that might arise in your daily business with NoSQL – and ArangoDB in particular.

You have a problem with or need an introduction to NoSQL data modeling / scaling ArangoDB / building Foxx apps / graph processing or something related to your favorite programming language? Then have a look if there’s a recipe match in the Cookbook!

Create your own recipes and help others in the ArangoDB community. We appreciate every participation that makes the cookbook a valuable source for ArangoDB users. Just write your problem description and solution in plain markdown and start a pull request on Github.

Need an example?

Lets assume you checked the foxx introduction on our website and now you want to build your own Foxx app, but you don’t know how to start.

(more…)

More info...

ArangoDB Java Driver for Graphs: Enhanced Functionality

After defining a graph and filling it with some vertices and edges (see part 1), the time has come to retrieve information out of the graph.

Please take a look at the defined graph operations of ArangoDB. These will be the base for our next examples. (Yes, there may be other ways to get the results, this post does not claim completeness!)

We will start with some easy stuff and then smoothly advance in complexity.

Question: “How many edges are defined within the graph?”

(more…)

More info...

ArangoDB Java Driver: Graph Data Manipulation & Queries

With ArangoDB 2.2 the new graph API was released featuring multi collection graphs (see blog). With the new version (2.2.1) of arangodb-java-driver the new graph API is supported. In the following you can find a small example of creating a graph with Java.

For the import via maven and configuring the driver, please read the Basics and Driver Setup. For the following we assume, that arangodbDriver is a configured instance of the driver.

So let’s start the whole thing…

(more…)

More info...

ArangoDB Java Driver: Batch & Asynchronous Mode | ArangoDB Blog

The current arangodb-java-driver supports the usage of ArangoDB’s batch and asynchronous interface. This post will guide you through the usage of these features.

The batch interface

The batch interface enables the user to stack a series of calls and execute them in a batch request. Each stacked request returns a request id that can be used to retrieve the single results from the batch response. So how do you use this feature in the java driver ?

First we create an instance of the java driver:

ArangoConfigure configure = new ArangoConfigure();
configure.init();
ArangoDriver driver = new ArangoDriver(configure);

(more…)

More info...

Set Up Bash Completion for ArangoDB: Step-by-Step Guide

I was interested in how bash auto-completion works and how to write a custom completer. After about an hour of work, I came up with a solution that at least seems to work on Ubuntu. I now have auto-completion for ArangoDB and all its client tools!

The problem

I use the command-line for almost everything, including starting and stopping ArangoDB and its client tools. They provide lots of options which I cannot completely memorize.

The bash solution for “I don’t know what I am looking for” is to press the TAB key. This will bring up a list of suggestions for how to complete the currently entered word. I thought using the same thing for ArangoDB’s command-line options would be nice, too.

Read more on Jan’s Blog

More info...

Compile ArangoDB Source: Step-by-Step Guide | ArangoDB Blog

Though we provide a lot of pre-built packages for the stable versions of ArangoDB here, it is often more interesting to play with the bleeding edge development version. New ArangoDB features are normally added to the devel branch, where they can be tested, documented and improved. When a feature matures, it is either backported to a stable branch or will eventually be released when the next stable branch is forked from devel.

Contributing to the core of ArangoDB is also much easier with a ready-to-go devel version. This post explains how to set one up from scratch.

Read more on Jan’s Blog

More info...

Get the latest tutorials,
blog posts and news: