ContentDeploymentJob.Test method (String)
Performs a test run for the content deployment job.
Namespace: Microsoft.SharePoint.Publishing.Administration
Assembly: Microsoft.SharePoint.Publishing (in Microsoft.SharePoint.Publishing.dll)
Syntax
'Declaration
Public Sub Test ( _
sourceContentDBSnapshotName As String _
)
'Usage
Dim instance As ContentDeploymentJob
Dim sourceContentDBSnapshotName As String
instance.Test(sourceContentDBSnapshotName)
public void Test(
string sourceContentDBSnapshotName
)
Parameters
sourceContentDBSnapshotName
Type: System.StringSpecifies a name of a SQL snapshot to be used for export operation.
Exceptions
Exception | Condition |
---|---|
ContentDeploymentException | A specific reason is better described by the actual exception's message. Some common ones can include:
|
SPException | Can be propagated from underlying Windows SharePoint Services 3.0 (WSS) layers. |
Remarks
The test run includes the export phase of the content deployment job only.
The method executes the content deployment job synchronously. That is, it will not return until the execution of the content deployment job is complete. In this case that means that the export phase of the job will run in the current process.
The execution of the content deployment job propagates content to the target normally as determined by the value of the ExportMethod property of the job.
If sourceContentDBSnapshotName is null or Empty, the use of SQL snapshot for export during the execution of the content deployment job is determined by the value of the SqlSnapshotSetting property (see SqlSnapshotSetting for more information). Otherwise, the execution of the content deployment job will use SQL snapshot specified by sourceContentDBSnapshotName for export. In this case, if the SQL Server snapshot specified by sourceContentDBSnapshotName does not exist or if the SQL Server being used does not support SQL snapshots, the execution of the job will fail.
If an attempt is made to execute a job that is already running or is in a timed out state (LastStatus property), the execution of the job will fail.