Add component and resource type trends

Rename common_relationships => relationship_types

Signed-off-by: Byron Ruth <b@devel.io>
Add defaults for neo4j.Client URI

Signed-off-by: Byron Ruth <b@devel.io>
Toggle debug Neo4j with config, remove events handler

Signed-off-by: Byron Ruth <b@devel.io>
Add collection endpoints to service root

Signed-off-by: Byron Ruth <b@devel.io>
Reset transaction queue and depth on autocommit close

This caused a nasty side effect when reusing the same transaction
instance and resulted in sending previously queued statements that would
ultimately fail.

Signed-off-by: Byron Ruth <b@devel.io>
[fixup] trends

Signed-off-by: Byron Ruth <b@devel.io>
Account for transaction closing within a context block

The depth was being decremented below zero due to being reset to zero
prior to the __exit__ call. This caused the commit statement to not be
called since the depth was not zero.

Signed-off-by: Byron Ruth <b@devel.io>
Use requests.Session() for slight performance boost

This keeps an open TCP connection to the server for those that support
Keep-Alive (which the Neo4j REST endpoint does).

Signed-off-by: Byron Ruth <b@devel.io>
Add self link to Origins service root

Signed-off-by: Byron Ruth <b@devel.io>
Tweak CORS behavior of service

A wildcard is no longer sent for the allowed hosts, but now sends the
explicit host in the header. Although credentials are not supported by
the service, the flag was enabled in case clients uses the
`withCredentais` flag on XMLHttpRequest.

Signed-off-by: Byron Ruth <b@devel.io>
Transparently encode/decode nested dicts in attributes

This is a bit of a hack, however it is a temporary solution until
storage backends are supported.

Signed-off-by: Byron Ruth <b@devel.io>
Support optional validation across graph API

This is an optimization for bulk loading data that performs
validation prior to performing write operations to the graph. In
addition, the sync now performs pre-validation of attributes prior to
accessing the datbase.

Signed-off-by: Byron Ruth <b@devel.io>
Implement "omni"-search resource

This currently supports resources, components, and relationships.

Signed-off-by: Byron Ruth <b@devel.io>