Open Closed

Cosmos DB with Encryption #9111


User avatar
0
DominaTang created

ABP framework 8.2.3 (going to upgrade to 9), Micro Services

In one of app micro service, we are going to change from Mongo Db to Azure Cosmos DB to use COSMOS Db's encryption feature.
https://devblogs.microsoft.com/cosmosdb/always-encrypted/
https://github.com/Azure/azure-cosmos-dotnet-v3/blob/master/Microsoft.Azure.Cosmos.Samples/Usage/Encryption/Program.cs

Do you think it is possible. I don't see any place I can inject Cosmos DB's encryption package.

Thank


4 Answer(s)
  • User Avatar
    0
    berkansasmaz created
    Support Team .NET Developer

    In one of app micro service, we are going to change from Mongo Db to Azure Cosmos DB to use COSMOS Db's encryption feature.

    Hello, I don't have much experience with CosmosDB, but there is a sample application on this subject.

    https://github.com/abpframework/abp-samples/tree/dc803d90f7335fdc7427a26b487e5b9d95de30b0/CosmosDBSample#how-to-use-cosmos-db-in-abp

    Have you seen this before, and will it work for you?

  • User Avatar
    0
    DominaTang created

    Switching to Cosmos DB (Mongo version) is very simply, just change connection string. the code seems working. Encryption seems not that easy.

  • User Avatar
    0
    EngincanV created
    Support Team .NET Developer

    Switching to Cosmos DB (Mongo version) is very simply, just change connection string. the code seems working. Encryption seems not that easy.

    Hi, as @berkansasmaz mentioned we don't have experience with CosmosDB much. But it should be possible because we are only abstracting some key points on the MongoDB side, everything you can do with a plain .NET application with MongoDB provider, you can do it with an ABP-based application.

    So, to better assist you, can you share what you've tried so far, what are your steps, and at which point you need our help? (please provide any information that think can help us to guide you better).

    Since, this is not an official provider provided by us, these information will help us answer better. Thanks for your understanding and waiting for details from you.

    Regards.

  • User Avatar
    0
    DominaTang created

    Switching to Cosmos DB (Mongo version) is very simply, just change connection string. the code seems working. Encryption seems not that easy.

    Hi, as @berkansasmaz mentioned we don't have experience with CosmosDB much. But it should be possible because we are only abstracting some key points on the MongoDB side, everything you can do with a plain .NET application with MongoDB provider, you can do it with an ABP-based application.

    So, to better assist you, can you share what you've tried so far, what are your steps, and at which point you need our help? (please provide any information that think can help us to guide you better).

    Since, this is not an official provider provided by us, these information will help us answer better. Thanks for your understanding and waiting for details from you.

    Regards.

    No worried, This is my understanding too. For the generic implementation that fit Mongo DB and Cosmos DB, there wouldn't have specific implementation for Cosmos DB's special feature. We can close this ticket.

Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
Do you need assistance from an ABP expert?
Schedule a Meeting
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v9.3.0-preview. Updated on April 11, 2025, 10:10