IBuildProvider?IBuildPlugin.ConstructProvider(string serialized) { var config = ParseConfig(serialized); if (config == null) { Log.Error().Message("Given data was no TfsConfiguration").Write(); return(null); } var connection = ConnectionPool.CreateConnection(config); if (connection == null) { return(null); } if (config.Project == null) { Log.Error().Message("ProjectId not given in connection data").Write(); return(null); } return(new TfsBuildProvider(connection, Guid.Parse(config.Project.Id))); }
public void CreateConnections(int x) { for (int i = 0; i < x; i++) { var connection = ConnectionPool .CreateConnection("Test"); connection.Close(); } }
public void CreateConnectionsAndChannels(int x) { for (int i = 0; i < x; i++) { var connection = ConnectionPool .CreateConnection("Test"); var channel = connection .CreateModel(); channel.Close(); connection.Close(); } }