solomonHou / redis

Automatically exported from code.google.com/p/redis
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

[Feature Request] redis as embedded database #276

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Could be useful for small/desktop application if redis had the ability to run 
as embedded database like sqlite or berkeley db.

Regards
Andrea Corradi

Original issue reported on code.google.com by andrea.c...@gmail.com on 7 Jul 2010 at 8:06

GoogleCodeExporter commented 8 years ago
Indeed. Having Redis available as embedded DB opens up a lot of possibilities 
that are not possible with the server only version.

Original comment by mvolmaro@gmail.com on 30 Jul 2010 at 12:36

GoogleCodeExporter commented 8 years ago
I am unable for various reasons, some legitimate and some silly, to use redis 
as a separate server process for my production code.  The silly reasons include 
territorial issues with the dba group, and the UNIX engineering group.  
Legitimate concerns are the addition of another point of failure outside the 
production process and the problem of who would maintain a general service for 
a shared facility.

The first question I was asked when broaching the idea was "would this mean our 
server would be unable to function if the redis server were unavailable?"

An embedded version would allow me to include the library in my production 
service while owning the responsibility for maintenance of redis in our 
environment, eliminate it as an external point of failure, and depending on the 
implementation, eliminate much of the networking overhead.

Original comment by jimsile...@gmail.com on 23 Aug 2010 at 5:52

GoogleCodeExporter commented 8 years ago
Did this get traction?

Original comment by xia...@gmail.com on 3 Mar 2011 at 6:04

GoogleCodeExporter commented 8 years ago
It did not get traction. If you want to get something that behaves 
transparently like it was running in-process (and communicates over unix domain 
socket), you can fork your main process, then run one of the exec*() functions 
in the child to start Redis. The Redis process would then get the same PID as 
the child process, and would look more or less like an embedded database.

Original comment by josiah.c...@gmail.com on 3 Mar 2011 at 7:02

GoogleCodeExporter commented 8 years ago
Good point. 

Original comment by xia...@gmail.com on 3 Mar 2011 at 8:18

GoogleCodeExporter commented 8 years ago
I've just stumbled upon this looking for evidence of any K/V stores which are 
suitable for being embedded… it's a shame it's not possible - but the idea of 
forking a local copy is workable. I'm not sure about utility on Win32, but 
that's a whole other topic!

Original comment by lee.hamb...@gmail.com on 10 Dec 2011 at 5:53

GoogleCodeExporter commented 8 years ago
Would love to see an embeddable version of Redis. For the record, an embeddable 
Mongo can be started as:

MongodStarter runtime = MongodStarter.getDefaultInstance();
            mongodExe = runtime.prepare(new MongodConfigBuilder()
                    .version(Version.Main.PRODUCTION)
                    .net(new Net(MONGO_PORT, Network.localhostIsIPv6()))
                    .build());
            mongod = mongodExe.start();

Complete sample at: 
https://github.com/arun-gupta/javaee7-samples/tree/master/extra/mongo

Would love something similar and simpler for Redis.

Original comment by arun.gu...@gmail.com on 3 Oct 2013 at 7:04

GoogleCodeExporter commented 8 years ago
This tracker is no longer used. You can go to https://github.com/antirez/redis 
to actually file a bug. That said... embedded Redis isn't going to happen from 
Salvatore - there are far more users that are interested in Redis Cluster, 
Redis Sentinel, and the existing Redis ecosystem.

Original comment by josiah.c...@gmail.com on 5 Oct 2013 at 5:41