Skip to main content
See also: Relationships | Navigation Directions | Cardinality
NameTypeDefaultDescription
linkRolestringNone (required)Polarion link role ID that implements the relationship. Must exactly match a link role defined in the Polarion project configuration. Required when storage is linkedWorkItems.
The linkRole value must exactly match a link role ID defined in your Polarion project under Administration > Work Item Link Roles. A mismatch causes the relationship to fail silently — no linked items will appear in the sheet, and no error is displayed to the user.
diagram The link role is the bridge between the domain model’s abstract relationship definition and Polarion’s concrete work item linking infrastructure. At runtime:
  • Read operations: Powersheet queries Polarion for work items connected via the specified link role, then populates the sheet with the results.
  • Write operations: When users create or remove links in the sheet, Powersheet uses the same link role to persist changes to Polarion.

Where linkRole Appears in Configuration

The linkRole property is specified on each entry in the relationships array of the domain model YAML. It sits alongside the structural properties (from, to, cardinality, storage) and the navigation direction definitions (direct, back).
relationships:
  - from: UserNeed
    to: Chapter
    cardinality: many-to-one
    storage: linkedWorkItems
    linkRole: parent
    direct:
      name: chapter
    back:
      name: userNeeds

Context Within the Relationship

PropertyTypeDefaultDescription
fromstringRequiredSource entity type name. Must match a key in domainModelTypes.
tostringRequiredTarget entity type name. Must match a key in domainModelTypes.
cardinalitystringRequiredRelationship multiplicity. See Cardinality.
storagestringRequiredMust be linkedWorkItems when using linkRole.
linkRolestringRequiredPolarion link role ID.
directobjectRequiredForward navigation property definition. See Navigation Directions.
direct.namestringRequiredName of the navigation property on the from entity.
backobjectOptionalReverse navigation property definition.
back.namestringRequired (if back provided)Name of the navigation property on the to entity.
A Polarion link role is inherently directional: it has a “from” side and a “to” side. The domain model’s from/to entity types and direct/back navigation properties align with this directionality.
Aspectdirect Directionback Direction
Navigation property placed onfrom entity typeto entity type
Traversal directionSource to targetTarget back to source
Polarion link sideForward linkReverse (backlink)
The isBacklink flag is managed internally by the system. When Powersheet processes a back direction, it internally flags the reverse traversal so that Polarion queries use the correct link direction.
A single linkRole value serves both the direct and back navigation properties. You do not need to define separate link roles for forward and reverse traversal. Powersheet handles the directionality automatically based on the direct/back configuration.
The linkRole itself does not encode cardinality — it is a simple identifier pointing to a Polarion link role. Cardinality is controlled separately by the cardinality property. However, the combination of linkRole and cardinality determines the runtime behavior:
CardinalityDirect PropertyBack PropertySource Expand PatternColumn Binding
many-to-oneScalar (single entity)Collection- name: chapterchapter, chapter.title
one-to-manyCollectionScalar- name: userNeedsuserNeeds (child rows)
many-to-manyCollection (via association)Collection (via association)Two levels: - name: systemRequirements then - name: systemRequirementsystemRequirements.systemRequirement
See Cardinality for the full reference on each value and its effects across model, source, and column layers. A single Polarion link role can appear in multiple relationships. This is common when the same semantic relationship type applies to different entity type pairs.
relationships:
  # decomposes links UserNeed to SystemRequirement
  - from: SystemRequirement
    to: UserNeed
    cardinality: many-to-many
    storage: linkedWorkItems
    linkRole: decomposes
    direct:
      name: userNeeds
    back:
      name: systemRequirements

  # decomposes also links SystemRequirement to DesignRequirement
  - from: DesignRequirement
    to: SystemRequirement
    cardinality: many-to-many
    storage: linkedWorkItems
    linkRole: decomposes
    direct:
      name: systemRequirements
    back:
      name: designRequirements
In this example, the decomposes link role is reused across two relationship definitions. Each relationship has its own from/to pairing and its own navigation property names, but they share the same underlying Polarion link role.
When reusing a link role across multiple relationships, ensure the navigation property names (direct.name and back.name) do not collide on the same entity type. Each entity type must have uniquely named navigation properties.

Permission Control on Relationships

Relationships support permission flags that control whether the link role’s operations are available through the sheet:
PropertyTypeDefaultDescription
createablebooleanSee applicationControls whether new links using this role can be created through the sheet.
readablebooleanSee applicationControls whether links using this role are visible in queries and the sheet UI.
Individual navigation properties (direct and back) can also have independent permission settings, allowing fine-grained control over which direction of a link role is editable or visible.
relationships:
  - from: UserNeed
    to: SystemRequirement
    cardinality: many-to-many
    storage: linkedWorkItems
    linkRole: decomposes
    direct:
      name: systemRequirements
    back:
      name: userNeeds
For detailed property-level permission configuration, see Permissions.

Validation Rules

Powersheet enforces specific rules when processing linkRole values:
RuleDetail
RequiredEvery relationship with storage: linkedWorkItems must have a linkRole value.
String matchThe value must exactly match a link role ID in the Polarion project configuration. The match is case-sensitive.
Entity type referencesThe from and to fields must reference entity type names defined in domainModelTypes, not Polarion work item type IDs.
Navigation property uniquenessWithin a single entity type, no two navigation properties can share the same name. This applies even when different link roles are used.
Link role IDs in Polarion are case-sensitive. A linkRole: Refines value will not match a Polarion link role with ID refines. Always verify the exact casing in Administration > Work Item Link Roles.

Complete YAML Example

A minimal domain model demonstrating linkRole across different relationship types:
domainModelTypes:
  Chapter:
    polarionType: heading

  UserNeed:
    polarionType: user_need
    properties:
      description:
      severity:

  SystemRequirement:
    polarionType: sys_req
    properties:
      description:
      severity:

  DesignRequirement:
    polarionType: des_req
    properties:
      description:

relationships:
  - from: UserNeed
    to: Chapter
    cardinality: many-to-one
    storage: linkedWorkItems
    linkRole: parent
    direct:
      name: chapter
    back:
      name: userNeeds

  - from: SystemRequirement
    to: UserNeed
    cardinality: many-to-many
    storage: linkedWorkItems
    linkRole: decomposes
    direct:
      name: userNeeds
    back:
      name: systemRequirements
This model demonstrates two different link roles:
  • parent for the hierarchical UserNeed to Chapter relationship (many-to-one)
  • decomposes for the traceability SystemRequirement to UserNeed relationship (many-to-many)
Each relationship uses storage: linkedWorkItems and defines both direct and back navigation properties for bidirectional traversal.
Authoritative ReferenceSource Code
  • Relationship.java
  • DomainModelV2.java