CAST supports Azure Cosmos DB via its NoSQL for Java extension. Details about the support provided for Java source code is explained below.
Supported Client Libraries
|Azure Cosmos DB Java SDK for SQL API||Interface com.microsoft.azure.documentdb.DocumentClient|
|Azure Cosmos DB Async Java SDK for SQL API||Interface com.microsoft.azure.cosmosdb.rx.AsyncDocumentClient|
Above mentioned methods are supported for both Synchronous and Asynchronous clients.
Java CosmosDB Database
|Java CosmosDB Collection|
|Java Unknown CosmosDB Database|
|Java Unknown CosmosDB Collection|
Links are created for transaction and function point needs:
|Link type||Source and destination of link||Methods Supported|
Between CosmosDB Database object and CosmosDB Collection
|useLink||Between the caller Java Method objects and CosmosDB Collection|
What results can you expect?
Once the analysis/snapshot generation is completed, you can view the results in the normal manner (for example via CAST Enlighten). Some examples are shown below.
Cosmos DB Client Creation
Insert Data Operation
Support for Collection based methods are provided, for example:
All corresponding methods are represented and results are very similar to its Synchronous counterpart:
No support for Cassandra API, MongoDB API, Gremlin API, Table API or other APIs built by Microsoft for accessing an Azure Cosmos DB service. See the API reference here:
Database and collection names are resolved as known objects when a connection string is passed to the client directly
Example: This connection string is passed to client - "/dbs/familydb/colls/familycoll"
Database and collection are marked as Unknown when Database Collection and document objects are passed as an argument in CRUD methods.
Runtime Ambiguities are not resolved
Example: Different databases are accessed in if/else cases based on some conditions