Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/angeloashmore/hanami-rethinkdb
RethinkDB adapter for Hanami::Model
https://github.com/angeloashmore/hanami-rethinkdb
Last synced: about 2 months ago
JSON representation
RethinkDB adapter for Hanami::Model
- Host: GitHub
- URL: https://github.com/angeloashmore/hanami-rethinkdb
- Owner: angeloashmore
- License: mit
- Created: 2015-01-04T19:56:20.000Z (almost 10 years ago)
- Default Branch: master
- Last Pushed: 2016-05-13T21:51:19.000Z (over 8 years ago)
- Last Synced: 2024-05-20T20:32:36.786Z (7 months ago)
- Language: Ruby
- Homepage:
- Size: 42 KB
- Stars: 6
- Watchers: 2
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
- awesome-hanami - hanami-rethinkdb - RethinkDB adapter for Hanami::Model (Hanami Gem List / Database)
README
# Hanami::Model RethinkDB Adapter
This adapter implements a [Hanami::Model](https://github.com/hanami/model) persistence layer for [RethinkDB](http://rethinkdb.com).
## Status
[![Gem Version](https://badge.fury.io/rb/hanami-rethinkdb.svg)](http://badge.fury.io/rb/hanami-rethinkdb)
[![Build Status](https://secure.travis-ci.org/angeloashmore/hanami-rethinkdb.svg?branch=master)](http://travis-ci.org/angeloashmore/hanami-rethinkdb?branch=master)
[![Coverage Status](https://img.shields.io/coveralls/angeloashmore/hanami-rethinkdb.svg)](https://coveralls.io/r/angeloashmore/hanami-rethinkdb)
[![Code Climate](https://codeclimate.com/github/angeloashmore/hanami-rethinkdb/badges/gpa.svg)](https://codeclimate.com/github/angeloashmore/hanami-rethinkdb)
[![Inline docs](http://inch-ci.org/github/angeloashmore/hanami-rethinkdb.svg?branch=master&style=flat)](http://inch-ci.org/github/angeloashmore/hanami-rethinkdb)## Links
* API Doc: [http://rdoc.info/gems/hanami-rethinkdb](http://rdoc.info/gems/hanami-rethinkdb)
* Bugs/Issues: [https://github.com/angeloashmore/hanami-rethinkdb/issues](https://github.com/angeloashmore/hanami-rethinkdb/issues)## Installation
Add this line to your application's Gemfile:
```ruby
gem 'hanami-rethinkdb'
```And then execute:
$ bundle
Or install it yourself as:
$ gem install hanami-rethinkdb
## Usage
Please refer to the [Hanami::Model](https://github.com/hanami/model#usage) docs for any details related to Entity, Repository, Data Mapper and Adapter.
### Repository methods
See the [complete list](https://github.com/hanami/model#repositories) of Repository methods provided by ```Hanami::Model```.
Following methods are not supported since it's incompatible with RethinkDB:
* first
* last### Query methods
Generic query methods supported by the RethinkDB adapter:
* [all](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#all-instance_method)
* [where](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#where-instance_method)
* [limit](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#limit-instance_method)
* [order](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#order-instance_method) (alias: ```asc```)
* [desc](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#desc-instance_method)
* [sum](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#dum-instance_method)
* [average](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#average-instance_method) (alias: ```avg```)
* [max](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#max-instance_method)
* [min](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#min-instance_method)
* [count](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#count-instance_method)RethinkDB-specific methods:
* [pluck](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#pluck-instance_method)
* [has_fields](http://rubydoc.info/gems/hanami-rethinkdb/Hanami/Model/Adapters/Rethinkdb/Query#has_fields-instance_method)## Contributing
1. Fork it ( https://github.com/angeloashmore/hanami-rethinkdb/fork )
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create a new Pull Request