Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

The ConnectionDefault setting was confusing for CqlVersion so now

ull is just being used instead to imply ConnectionDefault
  • Loading branch information...
commit 4fa9572fc5b95fefad4ebff844db9e518fd733b2 1 parent d5d1b4b
Nick Berardi nberardi authored
6 src/CassandraContext.cs
View
@@ -323,7 +323,7 @@ public void SaveChanges(IFluentRecord record, bool atomic = true)
///
/// </summary>
/// <param name="cqlQuery"></param>
- public IEnumerable<ICqlRow> ExecuteQuery(UTF8Type cqlQuery, string cqlVersion = CqlVersion.ConnectionDefault)
+ public IEnumerable<ICqlRow> ExecuteQuery(UTF8Type cqlQuery, string cqlVersion = null)
{
var op = new ExecuteCqlQuery(cqlQuery, cqlVersion);
return ExecuteOperation(op);
@@ -333,7 +333,7 @@ public IEnumerable<ICqlRow> ExecuteQuery(UTF8Type cqlQuery, string cqlVersion =
///
/// </summary>
/// <param name="cqlQuery"></param>
- public void TryExecuteNonQuery(UTF8Type cqlQuery, string cqlVersion = CqlVersion.ConnectionDefault)
+ public void TryExecuteNonQuery(UTF8Type cqlQuery, string cqlVersion = null)
{
try {
ExecuteNonQuery(cqlQuery, cqlVersion);
@@ -346,7 +346,7 @@ public void TryExecuteNonQuery(UTF8Type cqlQuery, string cqlVersion = CqlVersion
///
/// </summary>
/// <param name="cqlQuery"></param>
- public void ExecuteNonQuery(UTF8Type cqlQuery, string cqlVersion = CqlVersion.ConnectionDefault)
+ public void ExecuteNonQuery(UTF8Type cqlQuery, string cqlVersion = null)
{
var op = new ExecuteCqlNonQuery(cqlQuery, cqlVersion);
ExecuteOperation(op);
4 src/Connections/ConnectionBuilder.cs
View
@@ -14,7 +14,7 @@ public class ConnectionBuilder : FluentCassandra.Connections.IConnectionBuilder
/// <param name="host"></param>
/// <param name="port"></param>
/// <param name="timeout"></param>
- public ConnectionBuilder(string keyspace, string host, int port = Server.DefaultPort, int connectionTimeout = Server.DefaultTimeout, bool pooling = false, int minPoolSize = 0, int maxPoolSize = 100, int maxRetries = 0, int serverPollingInterval = 30, int connectionLifetime = 0, ConnectionType connectionType = ConnectionType.Framed, int bufferSize = 1024, ConsistencyLevel read = ConsistencyLevel.QUORUM, ConsistencyLevel write = ConsistencyLevel.QUORUM, string cqlVersion = FluentCassandra.Connections.CqlVersion.ConnectionDefault , bool compressCqlQueries = true, string username = null, string password = null)
+ public ConnectionBuilder(string keyspace, string host, int port = Server.DefaultPort, int connectionTimeout = Server.DefaultTimeout, bool pooling = false, int minPoolSize = 0, int maxPoolSize = 100, int maxRetries = 0, int serverPollingInterval = 30, int connectionLifetime = 0, ConnectionType connectionType = ConnectionType.Framed, int bufferSize = 1024, ConsistencyLevel read = ConsistencyLevel.QUORUM, ConsistencyLevel write = ConsistencyLevel.QUORUM, string cqlVersion = FluentCassandra.Connections.CqlVersion.Edge , bool compressCqlQueries = true, string username = null, string password = null)
{
Keyspace = keyspace;
Servers = new List<Server>() { new Server(host, port) };
@@ -37,7 +37,7 @@ public ConnectionBuilder(string keyspace, string host, int port = Server.Default
ConnectionString = GetConnectionString();
}
- public ConnectionBuilder(string keyspace, Server server, bool pooling = false, int minPoolSize = 0, int maxPoolSize = 100, int maxRetries = 0, int serverPollingInterval = 30, int connectionLifetime = 0, ConnectionType connectionType = ConnectionType.Framed, int bufferSize = 1024, ConsistencyLevel read = ConsistencyLevel.QUORUM, ConsistencyLevel write = ConsistencyLevel.QUORUM, string cqlVersion = FluentCassandra.Connections.CqlVersion.ConnectionDefault, bool compressCqlQueries = true, string username = null, string password = null)
+ public ConnectionBuilder(string keyspace, Server server, bool pooling = false, int minPoolSize = 0, int maxPoolSize = 100, int maxRetries = 0, int serverPollingInterval = 30, int connectionLifetime = 0, ConnectionType connectionType = ConnectionType.Framed, int bufferSize = 1024, ConsistencyLevel read = ConsistencyLevel.QUORUM, ConsistencyLevel write = ConsistencyLevel.QUORUM, string cqlVersion = FluentCassandra.Connections.CqlVersion.Edge, bool compressCqlQueries = true, string username = null, string password = null)
{
Keyspace = keyspace;
Servers = new List<Server>() { server };
1  src/Connections/CqlVersion.cs
View
@@ -8,7 +8,6 @@ public static class CqlVersion
public const string Cql = "2.0.0";
public const string Cql3 = "3.0.0";
public const string Edge = Cql3;
- public const string ConnectionDefault = null;
[Obsolete("This is no longer supported, please use ConnectionDefault", error: true)]
public const string ServerDefault = null;
2  src/Operations/ExecuteCqlNonQuery.cs
View
@@ -20,7 +20,7 @@ public override Void Execute()
if (isCqlQueryCompressed)
query = Helper.ZlibCompress(query);
- if (CqlVersion == FluentCassandra.Connections.CqlVersion.ConnectionDefault)
+ if (CqlVersion == null)
CqlVersion = Session.ConnectionBuilder.CqlVersion;
var client = Session.GetClient();
2  src/Operations/ExecuteCqlQuery.cs
View
@@ -40,7 +40,7 @@ public override IEnumerable<ICqlRow> Execute()
if (isCqlQueryCompressed)
query = Helper.ZlibCompress(query);
- if (CqlVersion == FluentCassandra.Connections.CqlVersion.ConnectionDefault)
+ if (CqlVersion == null)
CqlVersion = Session.ConnectionBuilder.CqlVersion;
var client = Session.GetClient();
Please sign in to comment.
Something went wrong with that request. Please try again.