Skip to content

Commit

Permalink
Prepare project for public release.
Browse files Browse the repository at this point in the history
Update the gemspec, add a license, update the readme and extract some of
the data to separate files.
  • Loading branch information
namxam committed Oct 26, 2011
1 parent 7030152 commit f2fecaa
Show file tree
Hide file tree
Showing 7 changed files with 100 additions and 63 deletions.
4 changes: 2 additions & 2 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
architect4r (0.3)
architect4r (0.3.2)
activemodel (~> 3.0)
json (~> 1.5)
typhoeus (~> 0.2)
Expand All @@ -24,7 +24,7 @@ GEM
guard (>= 0.8.4)
i18n (0.6.0)
json (1.6.1)
mime-types (1.16)
mime-types (1.17.1)
multi_json (1.0.3)
rake (0.9.2)
rb-fsevent (0.4.3.1)
Expand Down
20 changes: 20 additions & 0 deletions License
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
Copyright (c) 2011 Maximilian Schulz

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
66 changes: 7 additions & 59 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,72 +40,20 @@ Quick Start
instrument.valid?
instrument.save

# Updating attributes
instrument.update_attributes(params[:instrument])

# Finding records
Instrument.find_by_id(123)

class Fanship < Architect4r::Model::Relationship
# All relationships need a unique descriptor
descriptor 'fanship' # if not set it is derived from the class name
# Properties
property :created_at, :cast_to => DateTime
property :reason, :cast_to => String
end

# Init a class based relationship
Fanship.new( @user, @instrument, { :reason => 'Because I like you' })

# Filter associations by relationship type (:incoming, :outgoing, :all)
instrument.links(:outgoing)

# Query by model or type
@user.links(:all, Fanship, 'studies')

# Create a custom relationship
relationship = Architect4r::Model::Relationship.create(start_node, end_note, 'CustomType', { :active => true })
# or
instrument.links(:incoming).create(:category, @other_node, { :created_at => DateTime.new, :active => true })
instrument.links(:incoming).create(CategoryRelation, @other_node, { :created_at => DateTime.new, :active => true })


# Updating attributes
instrument.update_attributes(params[:instrument])

# Finding records
Instrument.all
Instrument.find_by_id(123)
Instrument.find_by_name("Piano")
Instrument.find_by_name("Klavier", :de)
Instrument.find_by_cypher("start cat=(123) match (cat)--(x) return x limit 2")

Roadmap / Next Steps
--------------------

Check the release notes for info on previous versions

_Currectly working on_

* Add relationships
* Auto add class related nodes to a class root node for easy queries

_Planned upcoming features_
* Add node indexes
* Add relationship indexes
* Add auto indexing of node properties / nodes (not neo4j auto indexing)
* Add more node finders by using indexes
* Create a ORM (ActiveRecord) synced node
* Give the cypher plugin some more love
* Add more default queries
* Rake tasks for installing neo4j
* Rake tasks for test setup
* Make it compatible to paperclip and carrierwave
* Make it compatible to sunspot search
* Add basic authentication
* Add digest authentication
* Improve test case
* Versioning of nodes (update node but create a linked node with the old properties)
* Optimize, optimize, optimize

_sometime in the future_

* Allow batch execution by facilitating hydra's concurrency model
Fanship.new(@user, @instrument, { :reason => 'Because I like you' })

License
-------
Expand Down
17 changes: 17 additions & 0 deletions ReleaseNotes.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,28 @@
# Release Notes

## v0.3.2

* Support for carrierwave file upload mechanism

## v0.3.1

* Sync with ActiveModel records

In order to use neo4j in combination with other databases, we provide a
small extension which allows you to keep a node in sync with another's
datastore record.

## v0.3

This release marks the first public release. So I wont get into length
with its changes and new features. Let's just say it allows you to create
nodes and relationships between nodes. That's it!

* Nodes (create, update, destroy)
* Relationships (create, update, destroy)
* Querying neo4j by using cypher query language
* Callbacks and validations for nodes and relationships

## v0.2

Another internal release which was not ready for development or production.
Expand Down
31 changes: 31 additions & 0 deletions Roadmap.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Roadmap

_Check the release notes for info on previous versions_


There is no real roadmap for architect4r, as this project is only used in
a single project so far. If there is anything you miss, either fork the
project, implement the feature and send a pull request, or submit an issue.

The following items are kinda planned to be integrated in the future:

* Give the cypher plugin some more love
* Add more default queries
* Add tracking of dirty attributes
* Make it compatible to file uploaders such as paperclip and carrierwave
* Make it compatible to search engines such as sunspot, elastic search, sphinx, …
* Rake tasks for installing neo4j
* Rake tasks for test setup
* Versioning of nodes (update node but create a linked node with the old properties)
* Improve documentation
* Improve test cases

And there are a few features which might be integrated, but are not yet really planned:

* Accessible relationships as you know it from active record
* Support for indexes (nodes and relations)
* Add more finders by using indexes
* Add auto indexing of node properties / nodes (not neo4j auto indexing)
* Add basic authentication
* Add digest authentication
* Facilitate hydra's concurrency model
21 changes: 21 additions & 0 deletions Specs.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Specs

Some code which might define the future interface of the gem.

# Finding records
Instrument.all
Instrument.find_by_name("Piano")
Instrument.find_by_name("Klavier", :de)
Instrument.find_by_cypher("start cat=(123) match (cat)--(x) return x limit 2")

# Filter associations by relationship type (:incoming, :outgoing, :all)
instrument.links(:outgoing)

# Query by model or type
@user.links(:all, Fanship, 'studies')

# Create a custom relationship
relationship = Architect4r::Model::Relationship.create(start_node, end_note, 'CustomType', { :active => true })
# or
instrument.links(:incoming).create(:category, @other_node, { :created_at => DateTime.new, :active => true })
instrument.links(:incoming).create(CategoryRelation, @other_node, { :created_at => DateTime.new, :active => true })
4 changes: 2 additions & 2 deletions architect4r.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ Gem::Specification.new do |s|
s.name = "architect4r"
s.version = Architect4r::VERSION
s.authors = ["Maximilian Schulz"]
s.email = ["max@jungeelite.de"]
s.homepage = "http://max.jungeelite.de/"
s.email = ["m.schulz@kulturfluss.de"]
s.homepage = "http://www.kulturfluss.de/"
s.summary = %q{A gem for working with the neo4j REST interface.}
s.description = %q{This gem is intended for making a neo4j graph db accessible by providing a ruby wrapper for the REST API.}

Expand Down

0 comments on commit f2fecaa

Please sign in to comment.