This document discusses ArangoDB Foxx, a feature of ArangoDB that allows developers to define REST APIs and build single page web applications directly against the ArangoDB database using JavaScript. Foxx allows defining controllers with routes, parameterizing routes, generating documentation, and structuring models. It aims to provide a streamlined way for front-end developers to interface directly with the database without overhead typically involved in separating concerns across servers. The document outlines several Foxx features and capabilities including authentication, asset handling, and sharing code through a repository.
FOXX - a Javascript application framework on top of ArangoDB
1. RWTH Aachen, Computer Science Student on branch master
triAGENS GmbH, Developer
moonglum moonbeamlabs
by Lucas Dohmen
Create APIs on your database
ArangoDB Foxx
8. Who is that guy?
• ArangoDB Core Team
• ArangoDB Foxx &
Ruby Adapter
• Student on the master
branch
• hacken.in & nerdkun.de
9. Who is that guy?
• ArangoDB Core Team
• ArangoDB Foxx &
Ruby Adapter
• Student on the master
branch
• hacken.in & nerdkun.de
/
(~(
) ) /_/
( _-----_(@ @)
( /
/|/--| V
" " " "
10. What is ?
• Free and Open Source…
• … Document and Graph Store…
• … with embedded JavaScript…
• … and an amazing query language
More about
ArangoDB at
Ruby UG Munich
next week
12. • …a feature of ArangoDB 1.4 (currently in
alpha, release: End of September)
• …an easy way to define REST APIs on top of
ArangoDB
• … a toolset for developing your single page
web application
• … not requiring any special code on the client
side – use it with Backbone, Ember, Angular…
Foxx is…
13. Why another solution?
• ArangoDB Foxx is streamlined for API
creation – not a Jack of all trades
• There‘s no communication overhead
between (serverside) application and
database
• It is designed for front end developers: Use
JavaScript, you already know that
18. • In your Foxx.Controller you describe your
routes
• But your application can consist of multiple
Foxx.Controllers
• … and you also want to deliver assets and
files
Manifest.json
19. {
"name": "my_website",
"version": "1.2.1",
"description": "My Website with a blog and a shop",
"thumbnail": "images/website-logo.png",
"controllers": {
"/blog": "apps/blog.js",
"/shop": "apps/shop.js"
},
"assets": {
"application.js": {
"files": [
"vendor/jquery.js",
"assets/javascripts/*"
]
}
}
}
20. More
• Define a setup and teardown function to
create and delete collections
• Define lib to set a base path for your require
statements
• Define files to deliver binary data unaltered
25. Models & Repositories
• Foxx also helps you structure the M part of
MVC
• We don‘t have time for that today
• But you can see a demonstration in our
demo app
• … or come to me later ;)
26. Foxx Apps Repo
• Look at demo applications
• Install components from a central repository
• Share your ideas
30. A Glance into
the Future
• Configure filters for your assets:
• UglifyJS2
• Later: Coffee, Sass, Client Templates…
• Configurable Logging
• Yo Generator
33. Thanks
• Database icon designed by Romeo Barreto
from The Noun Project
• Browser icon designed by Fernando
Vasconcelos from The Noun Project
• Logos from Node.js, Ruby on Rails, Django
and Symfony from the respective projects
• All other icons are from Font Awesome