소스 검색

Add specific server profile alias for Redis 2.6.

Daniele Alessandri 13 년 전
부모
커밋
626520b836
3개의 변경된 파일3개의 추가작업 그리고 2개의 파일을 삭제
  1. 1 1
      examples/MasterSlaveReplicationComplex.php
  2. 1 1
      examples/ServerSideScripting.php
  3. 1 0
      lib/Predis/Profiles/ServerProfile.php

+ 1 - 1
examples/MasterSlaveReplicationComplex.php

@@ -51,7 +51,7 @@ $parameters = array(
 
 
 $options = array(
 $options = array(
     'profile' => function($options) {
     'profile' => function($options) {
-        $profile = ServerProfile::get('dev');
+        $profile = ServerProfile::get('2.6');
         $profile->defineCommand('hmgetall', 'HashMultipleGetAll');
         $profile->defineCommand('hmgetall', 'HashMultipleGetAll');
 
 
         return $profile;
         return $profile;

+ 1 - 1
examples/ServerSideScripting.php

@@ -39,7 +39,7 @@ LUA;
     }
     }
 }
 }
 
 
-$client = new Predis\Client($single_server, 'dev');
+$client = new Predis\Client($single_server, '2.6');
 
 
 $client->getProfile()->defineCommand('increx', 'IncrementExistingKey');
 $client->getProfile()->defineCommand('increx', 'IncrementExistingKey');
 
 

+ 1 - 0
lib/Predis/Profiles/ServerProfile.php

@@ -76,6 +76,7 @@ abstract class ServerProfile implements IServerProfile, IProcessingSupport
             '2.0'     => 'Predis\Profiles\ServerVersion20',
             '2.0'     => 'Predis\Profiles\ServerVersion20',
             '2.2'     => 'Predis\Profiles\ServerVersion22',
             '2.2'     => 'Predis\Profiles\ServerVersion22',
             '2.4'     => 'Predis\Profiles\ServerVersion24',
             '2.4'     => 'Predis\Profiles\ServerVersion24',
+            '2.6'     => 'Predis\Profiles\ServerVersionNext',
             'default' => 'Predis\Profiles\ServerVersion24',
             'default' => 'Predis\Profiles\ServerVersion24',
             'dev'     => 'Predis\Profiles\ServerVersionNext',
             'dev'     => 'Predis\Profiles\ServerVersionNext',
         );
         );