Summary: This document provides basic information about the extension providing MongoDB, Marklogic and Couchbase support for the JEE analyzer.
What's new:
Alpha 1
New rules added:
- When using compound indexes, avoid having different indexes
- Avoid having MongoDB databases access without authentication activated
Alpha
Initial version supporting MongoDB, Marklogic, Couchbase
Description
The NoSQL for Java provides support for MongoDB, Marrklogic and Couchbase for the JEE analyzer.
In what situation should you install this extension?
- If you need to analyze MongoDB, MarkLogic and CouchDB queries in Java client code.
- Function Points (transactions): a green tick indicates that OMG Function Point counting and Transaction Risk Index are supported
Function Points | Quality Rules | Security |
---|---|---|
CAST AIP release | Supported |
---|---|
8.3.x | |
8.2.x | |
8.1.x | |
8.0.x | |
7.3.x |
Supported DBMS servers used for CAST AIP schemas
This extension is compatible with the following DBMS servers used to host CAST AIP schemas:
CAST AIP release | CSS2 | Oracle | Microsoft |
---|---|---|---|
All supported releases |
Prerequisites
An installation of any compatible release of CAST AIP (see table above) |
Download and installation instructions
Please see:
The latest release status of this extension can be seen when downloading it from the CAST Extend server.
What results can you expect?
Once the analysis/snapshot generation has completed, you can view the results in the normal manner (for example via CAST Enlighten) - click to enlarge:
You can also use the CAST Management Studio option View Analysis Unit Content to see the objects that have been created following the analysis:
Rules
The following rules are added:
Quality Rules | |
---|---|
1. | When using compound indexes, avoid having different indexes |
2. | Avoid having MongoDB databases access without authentication activated |
Violations in the CAST Engineering Dashboard
Violations in CAST Enlighten
Objects
The following objects are displayed in CAST Enlighten:
Icon | Description |
---|---|
Java MongoDB connection | |
Java MongoDB database | |
Java MongoDB collection | |
Java unknown MongoDB database | |
Java unknown MongoDB collection | |
Java MarkLogic database | |
Java MarkLogic collection | |
Java unknown MarkLogic database | |
Java unknown MarkLogic collection | |
Java Couchbase connection | |
Java Couchbase database | |
Java Couchbase collection | |
Java unknown Couchbase connection | |
Java unknown Couchbase database | |
Java unknown Couchbase collection |
Note that:
- Objects and links are detected via parametrization and when parametization is not enough we parse the Java caller object or even the entire Java file:
- com.mongodb.MongoClient.MongoClient is mapped as a MongoDB connection
- com.mongodb.Mongo.getDB to MongoDB databases
- com.mongodb.DB.getCollection to MongoDB collections, .update, .updateMulti, .findAndModify and .save methods are mapped as useUpdateLinks.
- For MongoDB we resolve Jongo queries, via parametrization and also:
- org.jongo.Jongo.Jongo is mapped as a MongoDB connection
- org.jongo.Jongo.getCollection to a MongoDB collection
Links
Links are created for transaction and function point needs.
MongoDB
Link type | When is this created? |
---|---|
parentLink | The connection is the parent of database which is the parent of a collection. Connection's parent is the caller's project. |
useLink | Between the caller Java objects and connections, databases or collections. |
useSelectLink useUpdateLink useDeleteLink useInsertLink | Between the caller Java object and a database or a collection. |
MarkLogic
Link type | When is this created? |
---|---|
parentLink | The database is the parent of a collection. Database's parent is the caller's project. |
useLink | Between the caller Java objects and a database or a collection. |
useSelectLink useUpdateLink useDeleteLink useInsertLink | Between the caller Java object and a database or a collection. |
Couchbase
Link type | When is this created? |
---|---|
parentLink | The connection is the parent of database which is the parent of a collection. Connection's parent is the caller's project. |
useLink | Between the caller Java objects and connections, databases or collections. |
useSelectLink useUpdateLink useDeleteLink useInsertLink | Between the caller Java object and a database or a collection. |