Crate tosca_solver

Crate tosca_solver 

Source
Expand description

This crate infers the relationships between TOSCA node templates when given a set of node templates and their requirements.

Each TOSCA requirement found on the node templates is encoded as a set of constraints, including:

  • node and capability types
  • the relationship’s valid_target_types
  • node_filter constraints
  • node_filter match expressions

solve() will return the nodes that match the requirements associated with a given set of nodes. By default this crate is exposed as a Python extension module and is used by Unfurl, but it can be used by any TOSCA 1.3 processor.

Structs§

Field
Node field.
Node
A partial representations of a TOSCA node template (enough for solve())
ToscaValue
A TOSCA value. If a complex value or typed scalar, type_name will be set.

Enums§

Constraint
Constraints used in node filters
CriteriaTerm
Represents the match criteria for a requirement.
EntityRef
FieldValue
Value of a Node field.
QueryType
SimpleValue
Simple TOSCA value

Functions§

solve
Finds missing requirements for the given topology. (Main Python entry point)

Type Aliases§

Criteria
Set of CriteriaTerms
RequirementMatches
HashMap mapping (source node name, requirement name) pairs to a list of (target node name, capability name) pairs.
ToscaTypes
HashMap mapping tosca type names to a list of ancestor types it inherits (including itsself)