Skip to content

Commit 73c1e08

Browse files
committed
Move implemented position
1 parent b265dbf commit 73c1e08

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

ext/ilios/cluster.c

+8-8
Original file line numberDiff line numberDiff line change
@@ -135,35 +135,35 @@ static VALUE cluster_keyspace(VALUE self, VALUE keyspace)
135135
}
136136

137137
/**
138-
* Sets the timeout for connecting to a node.
139-
* Default is +5000+ milliseconds.
138+
* Sets the protocol version. The driver will automatically downgrade to the lowest supported protocol version.
139+
* Default is +PROTOCOL_VERSION_V4+.
140140
*
141141
* @param timeout_ms [Integer] A connect timeout in milliseconds.
142142
* @return [Cassandra::Cluster] self.
143143
*/
144-
static VALUE cluster_connect_timeout(VALUE self, VALUE timeout_ms)
144+
static VALUE cluster_protocol_version(VALUE self, VALUE version)
145145
{
146146
CassandraCluster *cassandra_cluster;
147147

148148
GET_CLUSTER(self, cassandra_cluster);
149-
cass_cluster_set_connect_timeout(cassandra_cluster->cluster, NUM2UINT(timeout_ms));
149+
cass_cluster_set_protocol_version(cassandra_cluster->cluster, NUM2INT(version));
150150

151151
return self;
152152
}
153153

154154
/**
155-
* Sets the protocol version. The driver will automatically downgrade to the lowest supported protocol version.
156-
* Default is +PROTOCOL_VERSION_V4+.
155+
* Sets the timeout for connecting to a node.
156+
* Default is +5000+ milliseconds.
157157
*
158158
* @param timeout_ms [Integer] A connect timeout in milliseconds.
159159
* @return [Cassandra::Cluster] self.
160160
*/
161-
static VALUE cluster_protocol_version(VALUE self, VALUE version)
161+
static VALUE cluster_connect_timeout(VALUE self, VALUE timeout_ms)
162162
{
163163
CassandraCluster *cassandra_cluster;
164164

165165
GET_CLUSTER(self, cassandra_cluster);
166-
cass_cluster_set_protocol_version(cassandra_cluster->cluster, NUM2INT(version));
166+
cass_cluster_set_connect_timeout(cassandra_cluster->cluster, NUM2UINT(timeout_ms));
167167

168168
return self;
169169
}

0 commit comments

Comments
 (0)