Removing debug code

This commit is contained in:
Rick Falkvinge
2021-02-04 19:18:58 +01:00
parent a43bdb0874
commit 29e2867db3
2 changed files with 0 additions and 9 deletions
@@ -78,12 +78,7 @@ namespace Swarmops.Database
using (DbConnection connection = GetMySqlDbConnection())
{
Console.WriteLine("--------------------------------------------------------");
Console.WriteLine("DEBUG: " + connection.ConnectionString); // TODO/HACK: Temporary debug code
Console.WriteLine("--------------------------------------------------------");
Console.WriteLine("Before Open");
connection.Open();
Console.WriteLine("Between Open and GetDbCommand");
string sql = "SELECT " + backendServiceOrderFieldSequence +
ConstructWhereClause("BackendServiceOrders", conditions) +
@@ -93,17 +88,14 @@ namespace Swarmops.Database
// this ORDERBY + LIMIT gets the oldest first in a FIFO queue
DbCommand command = GetDbCommand(sql, connection);
Console.WriteLine("Between GetDbCommand and ExecuteReader");
using (DbDataReader reader = command.ExecuteReader())
{
Console.WriteLine("Between ExecuteReader and reader.Read");
while (reader.Read())
{
result.Add(ReadBackendServiceOrderFromDataReader(reader));
}
Console.WriteLine("Returning {0} records", result.Count);
return result.ToArray();
}
}
-1
View File
@@ -15,7 +15,6 @@ namespace Swarmops.Database
{
DbConnection connection = this.ProviderFactory.CreateConnection();
connection.ConnectionString = this.ConnectionString;
Console.WriteLine("DEBUG: " + this.ConnectionString); // debug
return connection;
}