Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join us at FabCon Vienna from September 15-18, 2025, for the ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM. Get registered

Reply
dbeavon3
Memorable Member
Memorable Member

Anyone try to use Spark context operations in Fabric ?

I'm having basic issues with spark context, that we never had on Synapse in Azure.


Eg the following fails:

spark.sparkContext.setCheckpointDir("tmp123")

... the purpose of that is to redirect the checkpoints to point at a custom location of our own choosing.  This allows checkpoints to be isolated from each other, and distinguished for future removal.  

A simple operation like this would work on Synapse.  But now we encounter unusual messages like so:

Py4JJavaError: An error occurred while calling o6614.setCheckpointDir. : Operation failed: "Bad Request", 400, PUT, http://onelake.dfs.fabric.microsoft.com/xxx-76a7-44e3-924a-9cd7a8d8ea24/user/trusted-service-user/tm..., BadRequest, "WorkspaceId and ArtifactId should be either valid Guids or valid Names"

 

 

 

 dbeavon3_0-1730383434216.png

 

 

 

 

Does anyone understand what the error means:

WorkspaceId and ArtifactId should be either valid Guids or valid Names

 

Any help would be appreciated.
 
1 ACCEPTED SOLUTION
richbenmintz
Resident Rockstar
Resident Rockstar

I assume you are running this from a Notebook I would try to reference a location in the Files area of the Lakehouse your Notebook is Bound to, something like, spark.sparkContext.setCheckpointDir("Files/tmp123"),  I tested in my environment and it seems to work correctly

 

richbenmintz_0-1730397708779.png

 



I hope this helps,
Richard

Did I answer your question? Mark my post as a solution! Kudos Appreciated!

Proud to be a Super User!


View solution in original post

3 REPLIES 3
richbenmintz
Resident Rockstar
Resident Rockstar

I assume you are running this from a Notebook I would try to reference a location in the Files area of the Lakehouse your Notebook is Bound to, something like, spark.sparkContext.setCheckpointDir("Files/tmp123"),  I tested in my environment and it seems to work correctly

 

richbenmintz_0-1730397708779.png

 



I hope this helps,
Richard

Did I answer your question? Mark my post as a solution! Kudos Appreciated!

Proud to be a Super User!


Anonymous
Not applicable

HI @dbeavon3,

This error message means this similar operation may not to be applied on fabric side due to this id and guid not valid.

AFAIK, fabric feature has referenced the azure synapse features, but they are not the same product, so the backend processing and verifications may not similar methods.
For your scenario, it means these requests obecjt not existed, or you can't operate with them.(they may not release to used)

Regards,

Xiaoxin Sheng

@Anonymous 

Thansk for the reply.  Have you tried using PySpark in Fabric?

As you may know, Microsoft is heavily marketing Fabric.  There are banners in the Synapse workspaces in the azure portal, and these banners tell customers to migrate to Fabric.

At a high level, can you tell me if there is any migration documentation that explains what gaps may exist between Spark on Synapse and Spark on Fabric?  This will not be a very smooth migration process, if something as simple as setCheckpointDir is not available.  I am only about 10 lines of code into the spark job, and there are already feature mismatches.

 

Back to my original question, why do I get the unusual message: 

WorkspaceId and ArtifactId should be either valid Guids or valid Names

 


I have not deliberately specified a workspaceId or artifactId.  Is there a place for me to do that?  If there is not a place, then where is the abfs library getting these properties from?  And why isn't the abfs library happy with those properties once it has gotten them. 

... Hopefully it goes without saying that these details should not be the rightful concern of the person calling "setCheckpointDir()".

 

 

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

May FBC25 Carousel

Fabric Monthly Update - May 2025

Check out the May 2025 Fabric update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.