Is there a way to turn off server-side JavaScript by Database rather than Cluster?

I’m sharing an Atlas Cluster with several other databases. I know that there’s a way to disable server-side JavaScript at the cluster level. Is it possible to disable server-side JavaScript at the individual database level? This would be convenient in case the other databases in the cluster need to use JavaScript.

Hi @Sam_Lanza and welcome to MongoDB community forums!!

Currently we do not have a feature to disable the server side JavaScript at the database level. The feature you mentioned applies to the entire cluster configuration.

As a workaround, you can look into using a proxy
proxy between the client and the server, which filters out the server-side operators that can be restricted to reach the server. This approach can help ensure that only the desired operators are allowed to reach the server.

If the above workaround does not help, could you share your use case which would help us to assist you further.

Nevertheless, we constantly strive to enhance our product and enhance its value for our users. If this feature would be useful for you and your use case, we kindly encourage you to share your thoughts with us via our MongoDB Feedback Engine.

We value your feedback, and our team will thoroughly consider it before implementing the feature.

Regards
Aasawari

1 Like

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.