Skip to content

Conversation

@eli-darkly
Copy link
Contributor

@eli-darkly eli-darkly commented Jul 31, 2021

This adds a unit test for the same kind of behavior mentioned in launchdarkly/php-server-sdk#151; even though that PR is for the phpredis integration, not the Predis one, both have a similar "use an existing client" option. We've already added an equivalent test in PHP SDK 3.x where the database integrations are still in the main SDK package, so this is the version for the separate package for use with PHP SDK 4.x.

$factory = Redis::featureRequester();
return $factory('', '', ['redis_prefix' => $prefix]);
$factory = Redis::featureRequester(['redis_prefix' => $prefix]);
return $factory('', '', []);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change just makes it so we are using the preferred way of configuring the Redis integration, where you put the Redis-specific options in the call to featureRequester. The other way, where those options are mixed in with the rest of the SDK options (the 3rd parameter in the call to $factory would be the SDK options), is deprecated.

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.

3 participants