Search Results

Search found 2 results on 1 pages for 'hiredis'.

Page 1/1 | 1 

  • Hiredis waiting for message

    - by Vivek Goel
    I am using hiredis C library to connect to redis server. I am not able to figure out how to wait for new messages after subscribing to new message. My code look like: signal(SIGPIPE, SIG_IGN ); struct event_base *base = event_base_new(); redisAsyncContext *c = redisAsyncConnect("127.0.0.1", 6379); if (c->err) { /* Let *c leak for now... */ printf("Error: %s\n", c->errstr); return 1; } redisLibeventAttach(c, base); redisAsyncSetConnectCallback(c, connectCallback); redisAsyncSetDisconnectCallback(c, disconnectCallback); redisAsyncCommand(c, NULL, NULL, "SET key %b", argv[argc - 1], strlen(argv[argc - 1])); redisAsyncCommand(c, getCallback, (char*) "end-1", "GET key"); redisAsyncCommand(c, getCallback, (char*) "end-1", "SUBSCRIBE foo"); Now how to tell hiredis to wait for message on channel ?

    Read the article

  • Is there or why not having a ruby technology specification similar to Java's JSR?

    - by romeu.hcf
    I think on a community portal where specifications are made, documented and specified to reference libraries and systems implementation. An example: A specification for Message Queue where redis clients, for instance, could implement it and where the libraries could be validated by the specification's test suite. Redic, redis-rb, hiredis, redis-connection-pool, redis-namespace should all implement this specification. This way, being easily replaced.

    Read the article

1