pg-redis-fdw / redis_fdw

A PostgreSQL foreign data wrapper for Redis
494 stars 68 forks source link

Redis Secondary Index module #16

Closed dvirsky closed 3 years ago

dvirsky commented 7 years ago

Hi guys. I'm working on a new redis module for secondary indexing with a minimal query language.

It's not ready yet, but I wanted to share the design of the API and see if you think we can collaborate on integrating this with the FDW somehow. Also, as people involved with PGSQL your input on this would be very valuable.

https://gist.github.com/dvirsky/3ef73143a6d8212f2b50096a8eb68018

A few things not mentioned in the document:

  1. The underlying engine is already sort-of-working and I'll open it up soon. It currently uses a skiplist to model the index, but I'm also considering a b+btree for more cache efficiency.
  2. I haven't dealt with doing this over a distributed redis cluster, but it will require a proxy for sure, which is also a place where I thought integrating with PGSQL might be an interesting direction.
  3. Redis 4.0 with modules should be in RC in about a month or two.

Dvir