Hacker News new | past | comments | ask | show | jobs | submit login
RedisGraph: a fast, queryable property graph database for Redis (redislabs.com)
135 points by arusahni 7 months ago | hide | past | web | favorite | 31 comments

Just a warning that this is one of the modules that's licensed under the controversial "Apache 2.0 with Commons Clause" license.

This motivated me to reread the commons clause again. I remain so disappointed in the naming and positioning of it. If you want to sell commercial modules that is totaly fine, but Apache 2 with commons doesn’t jump off the page as an unfree license (which prima facia it is). Should be called the ‘free for personal use’ email us for pricing clause instead.

I'm not a fan of combining licences - it's just confusing. They should come up with some new license like the "totally free if you're not reselling it as a service" license or something like that.

"The large print giveth, the small print taketh away".

> Should be called the ‘free for personal use’ email us for pricing clause instead

But this is a totally unfair characterization of the license, so they wouldn't call it this.

I think the license is interesting. I've been looking for a license that lets people tinker around with my software and use it in their commercial software, but protects me from getting my work or ideas stolen and resold...

More information about the Commons Clause can be found here [1].

TL;DR: May I create, distribute, offer as SaaS, and/or “sell” my products using Commons Clause licensed components? Yes. Is it open source? No.

[1] https://commonsclause.com

This is probably a dumb question, but can you explain what you mean by "it's not open source"? Is this not the complete source? https://github.com/RedisLabsModules/redis-graph/

Edit: Nevermind, it is answered in your link.

> Applying the Commons Clause to an open source project will mean the source code is available, and meets many of the elements of the Open Source Definition, such as free access to source code, freedom to modify, and freedom to re-distribute, but not all of them. So to avoid confusion, it is best not to call Commons Clause software “open source.”

Open source is not just the ability to see the source code. It must obey 10 rules - https://opensource.org/osd

1. Free Redistribution

The license shall not restrict any party from selling or giving away the software as a component of an aggregate software distribution containing programs from several different sources. The license shall not require a royalty or other fee for such sale.

2. Source Code

The program must include source code, and must allow distribution in source code as well as compiled form. Where some form of a product is not distributed with source code, there must be a well-publicized means of obtaining the source code for no more than a reasonable reproduction cost, preferably downloading via the Internet without charge. The source code must be the preferred form in which a programmer would modify the program. Deliberately obfuscated source code is not allowed. Intermediate forms such as the output of a preprocessor or translator are not allowed.

3. Derived Works

The license must allow modifications and derived works, and must allow them to be distributed under the same terms as the license of the original software.

4. Integrity of The Author's Source Code

The license may restrict source-code from being distributed in modified form only if the license allows the distribution of "patch files" with the source code for the purpose of modifying the program at build time. The license must explicitly permit distribution of software built from modified source code. The license may require derived works to carry a different name or version number from the original software.

5. No Discrimination Against Persons or Groups

The license must not discriminate against any person or group of persons.

6. No Discrimination Against Fields of Endeavor

The license must not restrict anyone from making use of the program in a specific field of endeavor. For example, it may not restrict the program from being used in a business, or from being used for genetic research.

7. Distribution of License

The rights attached to the program must apply to all to whom the program is redistributed without the need for execution of an additional license by those parties.

8. License Must Not Be Specific to a Product

The rights attached to the program must not depend on the program's being part of a particular software distribution. If the program is extracted from that distribution and used or distributed within the terms of the program's license, all parties to whom the program is redistributed should have the same rights as those that are granted in conjunction with the original software distribution.

9. License Must Not Restrict Other Software

The license must not place restrictions on other software that is distributed along with the licensed software. For example, the license must not insist that all other programs distributed on the same medium must be open-source software.

10. License Must Be Technology-Neutral

No provision of the license may be predicated on any individual technology or style of interface.

But it does not affect end users right?

Common Clause is a deceptive villainous virus spreading its way through the community.

If you want an graph DB alternative that is truly Open Source (MIT/ZLIB/Apache2) try ours ( https://github.com/amark/gun ).

Glad this was posted on HN because Roi's work is outstanding. I see there is a thread about the license here, you know my position. I think in short that:

* It makes sense for MongoDB / Redis Labs to change licenses of what they produce if they want / need.

* In the case however of the Redis core, it's BSD, no way it will be changed. But for modules produced by Redis Labs, it's their choice and there is something to do against the cloud providers exploit.

* I don't like the OSS license + Common Clause combo, but instead I like more to rename the sum of the two, like "Redis Labs Sharing License". We'll see if the company will move in that direction, I'm advising in that way.

* I don't like the attempt at getting things like SSPL OSI approved.

However, I want to ask if you would be more comfortable if RedisGraph would be licensed under SSPL instead of Apache 2 + Commons Clause. I don't have the power to change the license but I can advise, and for Redis Labs I suspect it is practically the same because the goal is to let users do what they want like-if-it-was-open-source, but stop cloud providers.

Yes, just change the license name, please! MongoDB, CockroachDB, and others are doing something similar and people aren't getting angry about it because they aren't calling it "Apache ...".

> * I don't like the attempt at getting things like SSPL OSI approved.


I had already issues with the GPL v2/3 concept of linking and the fact that the project linking to a GPL license should also be under a compatible license. To turn provisioning, that is just using normal system APIs, into a form of linking is IMHO wrong and no longer open source. I wrote a whole thread on Twitter with the details btw.

Yeah, no reason to not like that, since SSPL fits OSI own definition of open source.

I'm pretty uninformed on the subject, but I am interested to hear why an adjacency matrix is chosen over an adjacency list when it is sparse. My basic data structures and algorithms class would lead me to believe that an adjacency list would be better. Is this due to the nature of how the database is constructed?

I found this [1] comment useful, from a thread last month. It has some background and links to the state of the art of GraphBLAS, which applies linear algebra to graphs. This [2] page has a good summary:

> ... “But if we can view graphs as linear algebra problems—which have been central to science and engineering applications in high performance computing for decades—then we can immediately apply everything that we’ve learned from parallel supercomputing over the last 35 years to graphs.”

[1] https://news.ycombinator.com/item?id=18099520

[2] https://crd.lbl.gov/news-and-publications/news/2017/graphbla...

Another reason has to do with memory access and cache invalidation, when working with sparse matrices the entire graph structure is laid out in a contiguous block of memory which is ideal for CPU caching, unlike adjacency list where you have lots for small allocations scattered all over the memory space, this makes a huge difference when traversing the graph.

The main feature of the module is querying speed, which is achieved via matrix operations. You can't do the same with lists.

If I had to guess: redis is in general extremely predictable on both performance and memory use. A matrix is way more consistent in this.

Sparse matricies are represented as a sort of 2d linked list

The underlying representation is a sparse adjacency matrix. The graph that it is representing is not necessarily sparse.

True, although most "organic" graphs are sparse.

"Fast". Compared to what? How does it perform compared to Neo4j? How do you scale it?

Comparing RedisGraph (an in-memory db) to Neo4j, which does not need to hold the entire graph in-memory, is not really fair though.

Vertical scaling, I'd assume.

I really like how, just when I got interested in Graph Databases, this springs up.

I also really like the Cypher Syntax. I am definitely going to give Neoj4 and RedisGraph a go at some point.

Would be reeeal sweet for my use case if it supported finding shortest paths based on some link properties out of the box. That way I can get rid of neo4j.

Curious if this can work with a sharded redis cluster?


Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact