Start-AzSynapseSparkSession
Starts a Synapse Analytics Spark session.
Syntax
CreateByNameParameterSet (Default)
Start-AzSynapseSparkSession
-WorkspaceName <String>
-SparkPoolName <String>
-Name <String>
-ExecutorCount <Int32>
-ExecutorSize <String>
[-Language <String>]
[-ReferenceFile <String[]>]
[-Configuration <Hashtable>]
[-AsJob]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
CreateByParentObjectParameterSet
Start-AzSynapseSparkSession
-SparkPoolObject <PSSynapseSparkPool>
-Name <String>
-ExecutorCount <Int32>
-ExecutorSize <String>
[-Language <String>]
[-ReferenceFile <String[]>]
[-Configuration <Hashtable>]
[-AsJob]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Start-AzSynapseSparkSession cmdlet starts a Synapse Analytics Spark session.
Examples
Example 1
Start-AzSynapseSparkSession -WorkspaceName ContosoWorkspace -SparkPoolName ContosoSparkPool -Name ContosoSessionName -ExecutorCount 3 -ExecutorSize Small
This command starts an Azure Synapse Analytics Spark session.
Example 2
$pool = Get-AzSynapseSparkPool -WorkspaceName ContosoWorkspace -Name ContosoSparkPool
$pool | Start-AzSynapseSparkSession -Name ContosoSessionName -ExecutorCount 3 -ExecutorSize Small
This command starts an Azure Synapse Analytics Spark session through pipeline.
Parameters
-AsJob
Run cmdlet in the background
Parameter properties
Type: SwitchParameter
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-Configuration
Spark configuration properties.
Parameter properties
Type: Hashtable
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-Confirm
Prompts you for confirmation before running the cmdlet.
Parameter properties
Type: SwitchParameter
Default value: None
Supports wildcards: False
DontShow: False
Aliases: cf
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-DefaultProfile
The credentials, account, tenant, and subscription used for communication with Azure.
Parameter properties
Type: IAzureContextContainer
Default value: None
Supports wildcards: False
DontShow: False
Aliases: AzContext, AzureRmContext, AzureCredential
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-ExecutorCount
Number of executors to be allocated in the specified Spark pool for the job.
Parameter properties
Type: Int32
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-ExecutorSize
Number of core and memory to be used for executors allocated in the specified Spark pool for the job.
Parameter properties
Type: String
Default value: None
Accepted values: Small, Medium, Large, XLarge, XXLarge, XXXLarge
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-Language
Language of the execution code.
Parameter properties
Type: String
Default value: None
Accepted values: Spark, Scala, PySpark, Python, SparkDotNet, CSharp, SQL
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-Name
Name of Spark session.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-ReferenceFile
Additional files used for reference in the main definition file. Comma-separated storage URI list. e.g. "abfss://filesystem@account.dfs.core.windows.net/file1.txt,abfss://filesystem@account.dfs.core.windows.net/result/"
Parameter properties
Type: String [ ]
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-SparkPoolName
Name of Synapse Spark pool.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
CreateByNameParameterSet
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-SparkPoolObject
Spark pool input object, usually passed through the pipeline.
Parameter properties
Parameter sets
CreateByParentObjectParameterSet
Position: Named
Mandatory: True
Value from pipeline: True
Value from pipeline by property name: False
Value from remaining arguments: False
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Parameter properties
Type: SwitchParameter
Default value: None
Supports wildcards: False
DontShow: False
Aliases: wi
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-WorkspaceName
Name of Synapse workspace.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
CreateByNameParameterSet
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable,
-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see
about_CommonParameters .
Outputs