Compartir a través de


Clase DeploymentContributorConfigurationStream

Represents a streamable version of a configuration file that is used by DacFx in the deployment and build processes. These streams enable deployment extensions to enhance and extend the design and deployment experience. Input configuration files can be defined in a .sqlproj file as part of the MSBuild process. The files are treated as streams, and will be passed to contributors via the EstablishDeploymentConfiguration(DeploymentContributorConfigurationSetup) method, where they can be copied as outputs that are stored in the generated dacpac. These streams will then be made available in the ApplyDeploymentConfiguration(DeploymentContributorContext, ICollectionDeploymentContributorConfigurationStream), where they can be consumed for configuration and data during deployment. At the end of the ApplyDeploymentConfiguration(DeploymentContributorContext, ICollectionDeploymentContributorConfigurationStream) method all streams will be disposed. Contributors that need to obtain data from the streams must read and cache the data during this method - attempts to read from the stream during the OnExecute(DeploymentPlanContributorContext) method will fail. Inside a .sqproj file, Deployment Configuration files are specified as follows:

<ItemGroup> <DeploymentExtensionConfiguration Include="MyContributorName.MyFileName1.sql" /> <DeploymentExtensionConfiguration Include="MyContributorName.MyFileName2.sql" /> </ItemGroup>

Note that configuration streams are accessible to all contributors. Contributors may employ a file naming pattern to identify which input files related to that contributor.

Jerarquía de herencia

System.Object
  Microsoft.SqlServer.Dac.Deployment.DeploymentContributorConfigurationStream

Espacio de nombres:  Microsoft.SqlServer.Dac.Deployment
Ensamblado:  Microsoft.SqlServer.Dac.Extensions (en Microsoft.SqlServer.Dac.Extensions.dll)

Sintaxis

'Declaración
Public NotInheritable Class DeploymentContributorConfigurationStream
'Uso
Dim instance As DeploymentContributorConfigurationStream
public sealed class DeploymentContributorConfigurationStream
public ref class DeploymentContributorConfigurationStream sealed
[<SealedAttribute>]
type DeploymentContributorConfigurationStream =  class end
public final class DeploymentContributorConfigurationStream

El tipo DeploymentContributorConfigurationStream expone los siguientes miembros.

Constructores

  Nombre Descripción
Método público DeploymentContributorConfigurationStream Creates an instance of the DeploymentContributorConfigurationStream

Arriba

Propiedades

  Nombre Descripción
Propiedad pública Filename The filename used to represent this stream

Arriba

Métodos

  Nombre Descripción
Método público Equals (Se hereda de Object.)
Método público GetHashCode (Se hereda de Object.)
Método público GetStream Gets the Stream
Método público GetType (Se hereda de Object.)
Método público ToString (Se hereda de Object.)

Arriba

Seguridad para subprocesos

Cualquier miembro público static (Shared en Visual Basic) de este tipo es seguro para subprocesos. No se garantiza que los miembros de instancia sean seguros para subprocesos.

Vea también

Referencia

Espacio de nombres Microsoft.SqlServer.Dac.Deployment