cancel
Showing results for 
Search instead for 
Did you mean: 
Community Discussions
cancel
Showing results for 
Search instead for 
Did you mean: 

Method public void org.apache.spark.sql.internal.CatalogImpl.clearCache() is not whitelisted on clas

jensen22
Contributor

I'm executing a notebook and failed with this error:

Screenshot 2024-04-03 at 21.49.46.png

 

Sometime, when i execute some function in spark and also failed with the error 'this class is not whitelist'. 

Could everyone help me check on this?

Thanks for your help!

2 REPLIES 2

Ayushi_Suthar
Honored Contributor
Honored Contributor

Hi @jensen22 , Hope you are doing well! 

Can you please confirm which cluster access mode you are using to run the above notebook command? 

As per the error details in the screenshot, I am assuming you are using catalog.clear_cache on the Shared Cluster mode and currently, the "catalog.clear_cache" feature does not support shared cluster mode and is only applicable for single-user mode or no isolation shared mode. This limitation is due to the current design of shared clusters in Databricks. 

So in case you are using the shared cluster mode, could you please try to run the commands on the Single User or no-isolation shared access mode?

Please let me know if this helps and leave a like if this information is useful, followups are appreciated.
Kudos
Ayushi

jensen22
Contributor

Thanks for your feedback, actually my cluster is shared cluster, and then I change to single cluster then can run that method/

Welcome to Databricks Community: Lets learn, network and celebrate together

Join our fast-growing data practitioner and expert community of 80K+ members, ready to discover, help and collaborate together while making meaningful connections. 

Click here to register and join today! 

Engage in exciting technical discussions, join a group with your peers and meet our Featured Members.