ArangoDB & Ashikawa     Workshop            Part 2: Ashikawa   by Frank Celler and Lucas Dohmen
Ashikawa• Ruby Gems for ArangoDB• Ashikawa::Core• Ashikawa::AR• DataMapper 2?
Ashikawa::Core• Low Level Driver for ArangoDB• Abstracts the REST interface of ArangoDB• Basis for the other gems   gem in...
Ashikawa::AR• Implements the Active Record pattern• Integrates with Rails• Used on happy-geoco.de Rails Rumble  Project   ...
Data Mapper 2• Not yet• Implements the Data Mapper pattern• Will support various data sources• If you want to know more, g...
Ok, let‘s go
Ashikawa::Core
ArangoDB started? ;)
gem install ashikawa-core
require "ashikawa-core"db = Ashikawa::Core::Database.new  "127.0.0.1:8529"my_collection = db["stuff"]my_collection << {  n...
What can you do?• Access ArangoDB at a low level• More on rubydoc.info • Just search for ashikawa-core
Ashikawa::AR
Setup a new Rails Apprails new --skip-active-record              Add    ashikawa-ar, ~> 0.1.2          to you gemfile
Configure your DBYourApplicationName::Application.configure do  # ...  # ArangoDB configuration  Ashikawa::AR.setup :defaul...
class MyFineModel    include Ashikawa::AR::Model    attribute :name    attribute :my_attribute    attribute :my_string, St...
What can you do?• Define attributes via virtus• Validate attributes via aequitas• Find: all, by_example, find_by_aql…• Delet...
Contact          @moonbeamlabs            @arangodb     triAGENS/ashikawa-core      triAGENS/ashikawa-ar       lucas@arang...
Upcoming SlideShare
Loading in...5
×

Rupy2012 ArangoDB Workshop Part2

1,133
-1

Published on

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
1,133
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
23
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Rupy2012 ArangoDB Workshop Part2

  1. 1. ArangoDB & Ashikawa Workshop Part 2: Ashikawa by Frank Celler and Lucas Dohmen
  2. 2. Ashikawa• Ruby Gems for ArangoDB• Ashikawa::Core• Ashikawa::AR• DataMapper 2?
  3. 3. Ashikawa::Core• Low Level Driver for ArangoDB• Abstracts the REST interface of ArangoDB• Basis for the other gems gem install ashikawa-core
  4. 4. Ashikawa::AR• Implements the Active Record pattern• Integrates with Rails• Used on happy-geoco.de Rails Rumble Project gem install ashikawa-ar
  5. 5. Data Mapper 2• Not yet• Implements the Data Mapper pattern• Will support various data sources• If you want to know more, go to Piotr Solnica‘s talk this weekend :(• We will work on the support of ArangoDB
  6. 6. Ok, let‘s go
  7. 7. Ashikawa::Core
  8. 8. ArangoDB started? ;)
  9. 9. gem install ashikawa-core
  10. 10. require "ashikawa-core"db = Ashikawa::Core::Database.new "127.0.0.1:8529"my_collection = db["stuff"]my_collection << { name: "Test", something: "cool"}p my_collection.all.first.to_hash
  11. 11. What can you do?• Access ArangoDB at a low level• More on rubydoc.info • Just search for ashikawa-core
  12. 12. Ashikawa::AR
  13. 13. Setup a new Rails Apprails new --skip-active-record Add ashikawa-ar, ~> 0.1.2 to you gemfile
  14. 14. Configure your DBYourApplicationName::Application.configure do # ... # ArangoDB configuration Ashikawa::AR.setup :default, "127.0.0.1:8529"endConfiguration via database.yml already planned ;)
  15. 15. class MyFineModel include Ashikawa::AR::Model attribute :name attribute :my_attribute attribute :my_string, String end # Somewhere else... model = MyFineModel.by_example name: "Johnny"rails g ashikawa:model NAME attribute attribute2:String
  16. 16. What can you do?• Define attributes via virtus• Validate attributes via aequitas• Find: all, by_example, find_by_aql…• Delete, reload, save, update_attributes…• More on rubydoc.info • Just search for ashikawa-ar
  17. 17. Contact @moonbeamlabs @arangodb triAGENS/ashikawa-core triAGENS/ashikawa-ar lucas@arangodb.org ashikawa@googlegroups.com…or just find us this weekend :)
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×