CQL (Cortex Query Language) is at the core of virtually everything Cortex provides, from defining how Scorecards evaluate health and readiness to deciding which entities a plugin should show up on.
Some of the highlights of CQL functionality include:
- Strings support .split()
- Team entities support entity.children() and entity.parents(). With this, you can validate that your team hierarchy is set up as you expect.
- Support for getting the creation and last updated timestamps using entity.created(asTimestamp = true) and entity.lastUpdated(asTimestamp = true). Without the asTimestamp parameter, the result will return a Duration.
- Support for entity.isArchived() as well as isArchived to the dependency, children, and parent objects so that you can check whether an entity has any archived dependencies, children, or parents.
- For example, you can check whether an entity has archived dependencies using dependencies.out(includeArchived = true).any((dependency) => dependency.isArchived == true.
- You can measure information about incidents from PagerDuty, including how many were opened in the last month or how many took over 2 days to resolve.
- Support for pull requests from GitHub or GitLab to CQL, allowing you to check attributes about pull requests in Scorecards.
- git.branchProtection support for disableOverridingApproversPerMergeRequest, mergeRequestsAuthorApproval, requiredStatusChecks, and more for users with GitLab Ultimate. See the full branchProtection object in the CQL explorer.
- Metrics from SonarQube, including security_hotspots, security_rating, and more.
- K8s support k8s.clusters() allowing you to access all clusters and write expressions against them.
Comments
0 comments
Article is closed for comments.