Giter VIP home page Giter VIP logo

archimedes's People

Contributors

m0smith avatar michaelklishin avatar ray-metail avatar ray1729 avatar zmaril avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

archimedes's Issues

Support storing properties where the value is a vector to TinkerPop

Make it possible to store clojure vectors as values of vertices.

As the Gremlin javadocs says about properties:

The key of a property is always a String and the value of a property is an arbitrary Java object. Each underlying graph engine will typically have constraints on what Java objects are allowed to be used as values.

And https://tinkerpop.apache.org/javadocs/current/core/org/apache/tinkerpop/gremlin/structure/VertexProperty.Cardinality.html indicates that a property may contain a single value, a list of values, or a set of values. Currently we call flatten which destroys any collection here

(apply assoc! (cons elem (flatten (into [] d)))))

Decouple Ogre from Archimedes

Refactor edge/edges-between to just use vertex queries. Shouldn't be all that hard and will make development easier.

Refactor to not use var

Due to complications with dynamic vars, it is very hard to get Titanium to use the latest version of Archimedes. Additionally, best practices dictate that it is more useful to have methods that take the database connection as an argument instead of dynamically reassigning the graph. Thus something like (add-vertex) would become (add-vertex graph). This isn't too hard to implement, mostly just boxing text around.

The main issue is making sure that transactions are implemented properly. My initial reaction is to provide a transaction function that takes in a graph and a function to execute.

Some pseudo code:

(defn transact! [graph f]
  (let [t (.newTransaction graph)]
    (try (let [results (f t)]
           (.commit t)
           results)
         (catch Exception e (.rollback t)))))
(transact! graph (fn [graph] (add-vertex graph)))
;= Vertex[1]     

I'd like to make it not hard to use laziness inside the transactions. Right now, with something like the above, a map in the provided function could potentially execute after the transactions has been committed. That's the main blocking point for me right now, making the transactions work with lazy sequences properly.

Support has-not

query ns should add has-not function, wrapping com.tinkerpop.blueprints.Query/hasNot

connect! fails with No matching method found: addEdge

in alpha5, edge/connect! fails using TinkerGraph
topoged.data.blueprints> (e/connect! (first v) :dummy (second v))
IllegalArgumentException No matching method found: addEdge for class com.tinkerpop.blueprints.impls.tg.TinkerGraph
clojure.lang.Reflector.invokeMatchingMethod (Reflector.java:53)

but edge/connect-with-id! works

topoged.data.blueprints> (e/connect-with-id! "id" (first v) :dummy (second v))

<TinkerEdge e[id][18-dummy->19]>

Provide a way to print "Eureka" to stdout

I'd expect from a library with such a name to provide a way to shout "Eureka!" one way or another. According to the legend, Archimedes rushed home from a bath after discovering the way to measure volume of irregular objects. I therefore propose the function do something just
as awkward: just print "Eureka" to stdout, in all capital letters.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.