Remove server from nessDB

49 views
Skip to first unread message

BohuTANG

unread,
Jan 29, 2012, 9:00:28 PM1/29/12
to nes...@googlegroups.com
HI, everyone

I removed 'server' from nessDB, thus, it's *ONLY* a storage engine NOW.

HOW TO USE
===========
a. OPEN
		struct nessdb *db = db_open(bufferpool-size, db-path, islog); //NOTICE: bufferpool-size is bytes

  b. ADD
  		struct slice sk, sv;
		sk.len = 3;
		sk.data = "key";
		sv.len = 5;
		sv.data = "value";
		db_add(db, &sk, &sv);

  c. DELETE
  		struct slice sk;
		sk.len = 3;
		sk.data = "key";
		db_remove(db, &sk);

  d. READ
  		struct slice sk, sv;
		sk.len = 3;
		sk.data = "key";
		int ret = db_read(db, &sk, &sv);
		if (ret) {
			printf("data is %s", sv.data);
			free(sv.data);
		} else
			print("Not found");

  e. CLOSE
  		db_close(db);

Thanks.
BohuTANG    
Message has been deleted

Bohu TANG

unread,
Jan 30, 2012, 3:52:57 AM1/30/12
to nes...@googlegroups.com
Hi,
   repost here from twitter:
   Because 'server' need more power,I want more time on the 'storage engine'. :)

 If you need it ,I will support it!

On Mon, Jan 30, 2012 at 4:48 PM, Olivier Goudron <olivier...@gmail.com> wrote:
Just one word : Why ?

Bests regards, Olivier Goudron



--
BohuTANG

"The great artist is the simplifier."--- Vincent Van Gogh

Olivier Goudron

unread,
Jan 30, 2012, 4:14:14 AM1/30/12
to nes...@googlegroups.com
I will continue here.

My project is based on redis and i would like to use nessdb for the keys best stored on disk for size / volume raisons.
The idea was to use redis for short term and index data and nessdb for long term data.

The use of the same protocol than redis was a great idea from my point of view.

Now, i do not understand what you mean by "need more power" and i would like to ask you to keep the redis protocol support but only if you think it's not too many work for you.

If you droped the server because you think nobody want to use it you are wrong. If you droped the server because you don't have enought time to support it you are right.

What you decision will be, thanks for sharing your work.

Bests regards, Olivier Goudron

Bohu TANG

unread,
Jan 30, 2012, 4:23:12 AM1/30/12
to nes...@googlegroups.com
Fine, I reset, to add it.
Thanks,
BohuTANG

Bohu TANG

unread,
Jan 30, 2012, 4:36:16 AM1/30/12
to nes...@googlegroups.com
So sorry, I am wrong.
I had reset it on github.
Next time I will post a message on this group when I will do a big deal about nessDB.
Now, welcome to ping me when you find bugs in 'server' ,and welcome everyone to join nessDB's group.


Thanks.

BohuTANG
Reply all
Reply to author
Forward
0 new messages