Permalink
Commits on May 31, 2012
  1. Merge pull request #2 from noahwilliamsson/master

    Handle integer replies, implement a connect timeout and dynamic config in VCL
    andreacampi committed May 31, 2012
  2. Fix typo in examples/example.vcl (redis.call -> redis.send)

    Signed-off-by: Noah Williamsson <noah.williamsson@gmail.com>
    noahwilliamsson committed May 31, 2012
  3. Provide a commented out example of redis.init_redis() in examples/exa…

    …mple.vcl
    
    Signed-off-by: Noah Williamsson <noah.williamsson@gmail.com>
    noahwilliamsson committed May 31, 2012
  4. Allow the Redis server and timeout to be set in VCL via redis.init_re…

    …dis()
    
    By default libvmod-redis attempts to connect to the Redis server
    at 127.0.0.1, port 6379 with a connect timeout of 200 ms.
    
    This patch allows the Redis hostname, port and timeout to be configured
    via VCL using redis.init_redis(hostname, port, timeout_ms);
    
    VCL example:
      import redis;
      sub vcl_init {
        redis.init_redis("localhost", 6379, 200);
      }
    
    Signed-off-by: Noah Williamsson <noah.williamsson@gmail.com>
    noahwilliamsson committed May 31, 2012
  5. Implement a connect timeout for connecting to Redis, defaulting to 200ms

    Use redisConnectWithTimeout() instead of redisConnect() to prevent
    hanging for minutes when the host is down (i.e, not responding).
    
    The default timeout is set to 200ms via REDIS_TIMEOUT_MS in vmod_redis.c.
    
    Signed-off-by: Noah Williamsson <noah.williamsson@gmail.com>
    noahwilliamsson committed May 31, 2012
  6. Initialize config (host, port) once per VCL instead of once every call

    Because the VCC specifies PRIV_CALL for vmod_send() and vmod_call(), the
    vmod_priv argument is NULL for every call to these functions. This causes
    the config struct to be re-allocated for every call.
    
    This patch changes PRIV_CALL to PRIV_VCL, making the vmod_priv argument shared
    between all calls to the module's functions within a given instance of a VCL.
    
    The allocation of the config struct is also moved from redis_common() to
    init_function().
    
    Signed-off-by: Noah Williamsson <noah.williamsson@gmail.com>
    noahwilliamsson committed May 31, 2012
  7. Handle REDIS_REPLY_INTEGER in vmod_call() and return it as a string

    Signed-off-by: Noah Williamsson <noah.williamsson@gmail.com>
    noahwilliamsson committed May 31, 2012
Commits on Dec 7, 2011
  1. Cleanup: check that the reply is NULL before looking for errors.

    This may not be strictly needed, but it's the documented API.
    andreacampi committed Dec 7, 2011
  2. Merge pull request #1 from Luit-IT/master

    Fix to make vmod_redis reconnect when redis-server has closed the connection, making hiredis fail with REDIS_ERR_EOF. 
    
    This makes libvmod-redis much more useful
    andreacampi committed Dec 7, 2011
Commits on Dec 5, 2011
  1. Made redis_common() gracefully recover from disconnect

    Fix to make vmod_redis reconnect when redis-server has closed the
    connection, making hiredis fail with REDIS_ERR_EOF. Connecting is tried
    once and the current command re-issued once per call of redis_common().
    Luit committed Dec 5, 2011
Commits on Jun 6, 2011
Commits on May 26, 2011
  1. Edited README.md via GitHub

    andreacampi committed May 26, 2011
Commits on May 25, 2011
  1. Documentation update.

    andreacampi committed May 25, 2011
  2. Fix the license.

    andreacampi committed May 25, 2011
  3. Cleanup: use macros to wrap logging to make it easier to swap them

    out for something better.
    andreacampi committed May 25, 2011
  4. Refactor: move common code to a static function, implement both a

    VCL function and a procedure so we don't have to resort to nasty
    tricks.
    andreacampi committed May 25, 2011
Commits on May 20, 2011
  1. Add licence information

    perbu committed May 20, 2011
Commits on May 4, 2011
Commits on Feb 10, 2011
  1. Fix new filename reference

    mbgrydeland committed Feb 10, 2011
  2. More file renames

    mbgrydeland committed Feb 10, 2011
  3. Some file renames

    mbgrydeland committed Feb 10, 2011
  4. Updated README

    mbgrydeland committed Feb 10, 2011
  5. Fixed typo

    mbgrydeland committed Feb 10, 2011
Commits on Feb 9, 2011
  1. Out-of-tree vmod skeleton

    mbgrydeland committed Feb 9, 2011