Remove Connection String Operation



Remove connection string

The following example removes a RavenDB Connection String.

var ravenConnectionString = new RavenConnectionString()
{
    // Note:
    // Only the 'Name' property of the connection string is needed for the remove operation.
    // Other properties are not considered.
    Name = "ravendb-connection-string-name"
};
               
// Define the remove connection string operation,
// pass the connection string to be removed.
var removeConStrOp
    = new RemoveConnectionStringOperation<RavenConnectionString>(ravenConnectionString);

// Execute the operation by passing it to Maintenance.Send
store.Maintenance.Send(removeConStrOp);

Syntax

public RemoveConnectionStringOperation(T connectionString)
Parameter Type Description
connectionString T Connection string to remove:
RavenConnectionString
SqlConnectionString
OlapConnectionString
ElasticSearchConnectionString
QueueConnectionString