Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make Microsoft.Azure.Cosmos.ServiceInterop.dll native DLL loading optional again on Windows x64 #2366

Closed
ajdust opened this issue Apr 3, 2021 · 4 comments · Fixed by #3226
Labels
feature-request New feature or request QUERY

Comments

@ajdust
Copy link

ajdust commented Apr 3, 2021

Hi, I am developing a feature for a .NET application that cannot use native DLLs such as "Microsoft.Azure.Cosmos.ServiceInterop.dll". We're piloting using Cosmos. All documentation I've found implies that this is OK, Cosmos works with Windows/Mac/Linux so loading native code is not necessary.

However the code says otherwise. On Windows x64 the code always attempts to load a DLL, even if it is missing. The code in ServiceInteropWrapper.AssembliesExist appears to check for its existence, but then ServiceInteropWrapper.AssembliesExist = new Lazy<bool>(() => true); overrides that in CosmosClient. 0e2128586b878d90e9def62aa7ddc806c6395766.

Suggested you make loading the native DLL optional (even better, have Linux parity). Thanks for your consideration.

@j82w j82w added feature-request New feature or request QUERY labels Apr 5, 2021
@j82w
Copy link
Contributor

j82w commented Apr 5, 2021

Hi @ajdust, what is the reason you can not use the native DLL? The change was made to always attempt to load the file because even if you are Linux or Mac where it currently is not supported the file should still exist.

@ajdust
Copy link
Author

ajdust commented Apr 5, 2021

We have a plugin architecture wherein we provide .NET DLLs that are dynamically loaded into they system. Only .NET DLLs, and we do not control when and how the DLLs are loaded. The system ignores native DLLs.

@kirankumarkolli
Copy link
Member

@j82w lets please create a backlog item to address it.

@ealsur
Copy link
Member

ealsur commented Jun 2, 2022

Released in 3.27.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request New feature or request QUERY
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants