Thanks to visit codestin.com
Credit goes to github.com

Skip to content

add support for 'connect_timeout' option for redis arrays #347

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed

Conversation

MiketoString
Copy link

Add "connect_timeout" option to RedisArray constructor, and redis.arrays.connecttimeout php.ini setting.

Value is a double and specifies timeout in number of seconds when creating redis socket connections used in the RedisArray.

Sample Usage:

$redisArray = new RedisArray(
    array(
        "127.0.0.1:6379"
    ),

    array(
        'index' => true,
        'connect_timeout' => 1.5
    )
);

@davemoki
Copy link

Crucial addition -- thanks!

@svemir
Copy link

svemir commented Feb 23, 2014

We can not use this extension until connect_timeout is added. Is there a reason it is not merged yet? Thanks!

@michael-grunder
Copy link
Member

It's just not merged because I haven't gotten to it yet. I'll get it merged into develop after testing, etc. We're probably going to get a release out (so this gets into master) pretty soon as well.

Cheers,
Mike

michael-grunder added a commit that referenced this pull request Feb 23, 2014
Merge branch 'feature/ra_connect_timeout' into develop
@michael-grunder
Copy link
Member

This is up in our develop branch. Thanks to @MiketoString for the pull request. Apologies for the delay in getting it merged.

Like I mentioned above, we should be doing a release to get the various things in since 2.2.4 were out (SCAN, etc).

Cheers,
Mike

@amolrajoba
Copy link
Contributor

Thanks for great addition of connetion timeout 'connect_timeout', But it will be great help to community if this can be added in documentation with example here https://github.com/nicolasff/phpredis/blob/master/arrays.markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants