SysML Systems - Modeling - API - and - Services
SysML Systems - Modeling - API - and - Services
_______________________________________________________________________________
Normative:
https://www.omg.org/spec/SystemsModelingAPI/20240201/Systems-Modeling-API.xmi
https://www.omg.org/spec/SystemsModelingAPI/20240201/OpenAPI.json
https://www.omg.org/spec/SystemsModelingAPI/20240201/Schemas.json
https://www.omg.org/spec/SystemsModelingAPI/20240201/OSLC-Domain-Model.zip
Non-normative:
https://www.omg.org/spec/SystemsModelingAPI/20240201/API-Cookbook.zip
_______________________________________________________________________________
Copyright © 2019-2024, 88solutions Corporation
Copyright © 2019-2024, Airbus
Copyright © 2019-2024, Aras Corporation
Copyright © 2019-2024, Association of Universities for Research in Astronomy (AURA)
Copyright © 2019-2024, BigLever Software
Copyright © 2019-2024, Boeing
Copyright © 2022-2024, Budapest University of Technology and Economics
Copyright © 2021-2024, Commissariat à l'énergie atomique et aux énergies alternatives (CEA)
Copyright © 2019-2024, Contact Software GmbH
Copyright © 2019-2024, Dassault Systèmes (No Magic)
Copyright © 2020-2024, DEKonsult
Copyright © 2020-2024, Delligatti Associates, LLC
Copyright © 2019-2024, DSC Corporation
Copyright © 2019-2024, The Charles Stark Draper Laboratory, Inc.
Copyright © 2020-2024, ESTACA
Copyright © 2022-2024, Galois
Copyright © 2019-2024, GfSE e.V.
Copyright © 2019-2024, George Mason University
Copyright © 2019-2024, IBM
Copyright © 2019-2024, Idaho National Laboratory
Copyright © 2019-2024, INCOSE
Copyright © 2019-2024, Intercax LLC
Copyright © 2019-2024, Jet Propulsion Laboratory (California Institute of Technology)
Copyright © 2019-2024, Kenntnis LLC
Copyright © 2020-2024, Kungliga Tekniska högskolon (KTH)
Copyright © 2019-2024, LightStreet Consulting LLC
Copyright © 2019-2024, Lockheed Martin Corporation
Copyright © 2019-2024, Maplesoft
Copyright © 2021-2024, MID GmbH
Copyright © 2020-2024, MITRE
Copyright © 2019-2024, Model Alchemy Consulting
Copyright © 2019-2024, Model Driven Solutions, Inc.
Copyright © 2019-2024, Model Foundry Pty. Ltd.
Copyright © 2023-2024, Object Management Group, Inc.
Copyright © 2019-2024, On-Line Application Research Corporation (OAC)
Copyright © 2019-2024, oose Innovative Informatik eG
Copyright © 2019-2024, Østfold University College
Copyright © 2019-2024, PTC
Copyright © 2020-2024, Qualtech Systems, Inc.
Copyright © 2019-2024, SAF Consulting
Copyright © 2019-2024, Simula Research Laboratory AS
Copyright © 2019-2024, System Strategy, Inc.
Copyright © 2019-2024, Thematix
Copyright © 2019-2024, Tom Sawyer
Copyright © 2022-2024, Tucson Embedded Systems, Inc.
Copyright © 2019-2024, Universidad de Cantabria
Copyright © 2019-2024, University of Alabama in Huntsville
Copyright © 2019-2024, University of Detroit Mercy
Copyright © 2019-2024, University of Kaiserslauten
Copyright © 2020-2024, Willert Software Tools GmbH (SodiusWillert)
USE OF SPECIFICATION - TERMS, CONDITIONS & NOTICES
The material in this document details an Object Management Group specification in accordance with the
terms, conditions and notices set forth below. This document does not represent a commitment to
implement any portion of this specification in any companys products. The information contained in this
document is subject to change without notice.
LICENSES
The companies listed above have granted to the Object Management Group, Inc. (OMG) a nonexclusive,
royalty-free, paid up, worldwide license to copy and distribute this document and to modify this document
and distribute copies of the modified version. Each of the copyright holders listed above has agreed that
no person shall be deemed to have infringed the copyright in the included material of any such copyright
holder by reason of having used the specification set forth herein or having conformed any computer
software to the specification.
Subject to all of the terms and conditions below, the owners of the copyright in this specification hereby
grant you a fully-paid up, non-exclusive, nontransferable, perpetual, worldwide license (without the right to
sublicense), to use this specification to create and distribute software and special purpose specifications
that are based upon this specification, and to use, copy, and distribute this specification as provided
under the Copyright Act; provided that: (1) both the copyright notice identified above and this permission
notice appear on any copies of this specification; (2) the use of the specifications is for informational
purposes and will not be copied or posted on any network computer or broadcast in any media and will
not be otherwise resold or transferred for commercial purposes; and (3) no modifications are made to this
specification. This limited permission automatically terminates without notice if you breach any of these
terms or conditions. Upon termination, you will destroy immediately any copies of the specifications in
your possession or control.
PATENTS
The attention of adopters is directed to the possibility that compliance with or adoption of OMG
specifications may require use of an invention covered by patent rights. OMG shall not be responsible for
identifying patents for which a license may be required by any OMG specification, or for conducting legal
inquiries into the legal validity or scope of those patents that are brought to its attention. OMG
specifications are prospective and advisory only. Prospective users are responsible for protecting
themselves against liability for infringement of patents.
Any unauthorized use of this specification may violate copyright laws, trademark laws, and
communications regulations and statutes. This document contains information which is protected by
copyright. All Rights Reserved. No part of this work covered by copyright herein may be reproduced or
used in any form or by any means--graphic, electronic, or mechanical, including photocopying, recording,
taping, or information storage and retrieval systems--without permission of the copyright owner.
DISCLAIMER OF WARRANTY
WHILE THIS PUBLICATION IS BELIEVED TO BE ACCURATE, IT IS PROVIDED "AS IS" AND MAY
CONTAIN ERRORS OR MISPRINTS. THE OBJECT MANAGEMENT GROUP AND THE COMPANIES
LISTED ABOVE MAKE NO WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, WITH REGARD TO
THIS PUBLICATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTY OF TITLE OR
OWNERSHIP, IMPLIED WARRANTY OF MERCHANTABILITY OR WARRANTY OF FITNESS FOR A
PARTICULAR PURPOSE OR USE. IN NO EVENT SHALL THE OBJECT MANAGEMENT GROUP OR
ANY OF THE COMPANIES LISTED ABOVE BE LIABLE FOR ERRORS CONTAINED HEREIN OR FOR
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, CONSEQUENTIAL, RELIANCE OR COVER DAMAGES,
INCLUDING LOSS OF PROFITS, REVENUE, DATA OR USE, INCURRED BY ANY USER OR ANY
THIRD PARTY IN CONNECTION WITH THE FURNISHING, PERFORMANCE, OR USE OF THIS
MATERIAL, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
The entire risk as to the quality and performance of software developed using this specification is borne
by you. This disclaimer of warranty constitutes an essential part of the license granted to you to use this
specification.
Use, duplication or disclosure by the U.S. Government is subject to the restrictions set forth in
subparagraph (c) (1) (ii) of The Rights in Technical Data and Computer Software Clause at DFARS
252.227-7013 or in subparagraph (c)(1) and (2) of the Commercial Computer Software - Restricted Rights
clauses at 48 C.F.R. 52.227-19 or as specified in 48 C.F.R. 227-7202-2 of the DoD F.A.R. Supplement
and its successors, or as specified in 48 C.F.R. 12.212 of the Federal Acquisition Regulations and its
successors, as applicable. The specification copyright owners are as indicated above and may be
contacted through the Object Management Group, 9C Medway Road, PMB 274, Milford, MA 01757,
U.S.A.
TRADEMARKS
CORBA®, CORBA logos®, FIBO®, Financial Industry Business Ontology®, Financial Instrument Global
Identifier®, IIOP®, IMM®, Model Driven Architecture®, MDA®, Object Management Group®, OMG®, OMG
Logo®, SoaML®, SOAML®, SysML®, UAF®, Unified Modeling Language™, UML®, UML Cube Logo®,
VSIPL®, and XMI® are registered trademarks of the Object Management Group, Inc.
COMPLIANCE
The copyright holders listed above acknowledge that the Object Management Group (acting itself or
through its designees) is and shall at all times be the sole entity that may authorize developers, suppliers
and sellers of computer software to use certification marks, trademarks or other special designations to
indicate compliance with these materials.
Software developed under the terms of this license may claim compliance or conformance with this
specification if and only if the software compliance is of a nature fully matching the applicable compliance
points as stated in the specification. Software developed only partially matching the applicable
compliance points may claim only that the software was based on this specification, but may not claim
compliance or conformance with this specification. In the event that testing suites are implemented or
approved by Object Management Group, Inc., software developed using this specification may claim
compliance or conformance with the specification only if the software satisfactorily completes the testing
suites.
OMG’S ISSUE REPORTING PROCEDURE
All OMG specifications are subject to continuous review and improvement. As part of this process we
encourage readers to report any ambiguities, inconsistencies, or inaccuracies they may find by
completing the Issue Reporting Form listed on the main web page https://www.omg.org, under
Documents, Report a Bug/Issue.
Table of Contents
0 Preface...............................................................................................................................................................................................3
1 Scope.................................................................................................................................................................................................1
2 Conformance.....................................................................................................................................................................................3
3 Normative References.......................................................................................................................................................................5
4 Terms and Definitions.......................................................................................................................................................................7
5 Symbols ............................................................................................................................................................................................9
6 Introduction.....................................................................................................................................................................................11
6.1 API and Services Architecture............................................................................................................................................11
6.2 Document Conventions.......................................................................................................................................................12
6.3 Document Organization ......................................................................................................................................................13
6.4 Acknowledgements.............................................................................................................................................................13
7 Platform Independent Model (PIM)................................................................................................................................................15
7.1 API Model...........................................................................................................................................................................15
7.1.1 Record .....................................................................................................................................................................15
7.1.2 Project Data Versioning ..........................................................................................................................................16
7.1.3 ExternalData and ExternalRelationship ..................................................................................................................19
7.1.4 Query ......................................................................................................................................................................20
7.2 API Services........................................................................................................................................................................21
7.2.1 ProjectService .........................................................................................................................................................21
7.2.2 ElementNavigationService......................................................................................................................................22
7.2.3 ProjectDataVersioningService ................................................................................................................................23
7.2.4 QueryService...........................................................................................................................................................27
7.2.5 ExternalRelationshipService ...................................................................................................................................28
7.2.6 ProjectUsageService ...............................................................................................................................................28
8 Platform Specific Models (PSMs) ..................................................................................................................................................31
8.1 REST/HTTP PSM...............................................................................................................................................................31
8.1.1 Overview .................................................................................................................................................................31
8.1.2 PIM API Model - REST/HTTP PSM Model Mapping...........................................................................................31
8.1.3 PIM API Services - REST/HTTP PSM Endpoints Mapping..................................................................................31
8.2 OSLC 3.0 PSM ...................................................................................................................................................................38
8.2.1 Overview .................................................................................................................................................................38
8.2.2 OSLC Nomenclature...............................................................................................................................................39
8.2.3 PIM API Model – OSLC PSM Resource Mapping ................................................................................................40
8.2.4 PIM API Services – OSLC PSM Service Mapping ................................................................................................41
A Annex: Conformance Test Suite ....................................................................................................................................................51
A.1 Project Service Conformance Test Cases ..........................................................................................................................51
A.2 Element Navigation Service Conformance Test Cases......................................................................................................53
A.3 Project and Data Versioning Service Conformance Test Cases ........................................................................................58
A.4 Query Service Conformance Test Cases............................................................................................................................69
A.5 External Relationship Service Conformance Test Cases ...................................................................................................71
A.6 Project Usage Service Conformance Test Cases ...............................................................................................................71
A.7 Cross-Cutting Conformance Test Cases ............................................................................................................................71
B Annex: API and Services Examples...............................................................................................................................................79
Founded in 1989, the Object Management Group, Inc. (OMG) is an open membership, not-for-profit computer
industry standards consortium that produces and maintains computer industry specifications for interoperable,
portable, and reusable enterprise applications in distributed, heterogeneous environments. Membership includes
Information Technology vendors, end users, government agencies, and academia.
OMG member companies write, adopt, and maintain its specifications following a mature, open process. OMG’s
specifications implement the Model Driven Architecture® (MDA®), maximizing ROI through a full-lifecycle
approach to enterprise integration that covers multiple operating systems, programming languages, middleware and
networking infrastructures, and software development environments. OMG’s specifications include: UML®
(Unified Modeling Language™); CORBA® (Common Object Request Broker Architecture); CWM™ (Common
Warehouse Metamodel); and industry-specific standards for dozens of vertical markets.
OMG Specifications
As noted, OMG specifications address middleware, modeling, and vertical domain frameworks. All OMG
Specifications are available from the OMG website at: https://www.omg.org/spec
All of OMG’s formal specifications may be downloaded without charge from our website. (Products implementing
OMG specifications are available from individual suppliers.) Copies of specifications, available in PostScript and
PDF format, may be obtained from the Specifications Catalog cited above or by contacting the Object Management
Group, Inc. at:
OMG Headquarters
9C Medway Road, PMB 274
Milford, MA 01757
USA
Tel: +1-781-444-0404
Fax: +1-781-444-0320
Email: [email protected]
Certain OMG specifications are also available as ISO standards. Please consult https://www.iso.org
Issues
All OMG specifications are subject to continuous review and improvement. As part of this process we encourage
readers to report any ambiguities, inconsistencies, or inaccuracies they may find by completing the Issue Reporting
Form listed on the main web page https://www.omg.org, under Specifications, Report an Issue.
The Systems Modeling API and Services specifies the types and details of the requests that can be made and
responses that can be received by software applications that are consuming the services to software applications that
are providing the services.
The Systems Modeling API and Services specification includes the Platform Independent Model (PIM) - see Clause
7 - and two Platform Specific Models (PSMs) - see Clause 8 : REST/HTTP PSM and OSLC PSM.
A Systems Modeling API and Services Provider is a software application that provides the services defined in this
specification.
A Systems Modeling API and Services Consumer is a software application that consumes the services defined in
this specification and provided by the Service Provider.
Consumers send requests to Providers and receive responses with results, as illustrated in Fig. 1 below.
For brevity, this specification uses the phrase Service Provider for Systems Modeling API and Services Provider,
and the term Service Consumer for Systems Modeling API and Services Consumer.
A Service Provider can conform to this specification at the PSM or PIM level.
A Service Provider tool must demonstrate conformance to one or more services, as described below.
1. ProjectService Conformance - A Service Provider must implement all the operations in the
ProjectService, and demonstrate that the implementation successfully passes all the Project Service
Conformance Test Cases (see A.1 ) and Cross-Cutting Conformance Test Cases (see A.7 ).
2. ElementNavigationService Conformance - A Service Provider must implement all the operations in the
ElementNavigationService, and demonstrate that the implementation successfully passes all the Element
(1) Platform-Independent Model (PIM) provides a service specification independent of any platform or
technology. This specification defines each of the services and their operations with inputs and outputs. The PIM
serves as the logical API model.
(2) Platform-Specific Models (PSMs) are bindings of the PIM using a particular technology, such as REST/HTTP,
SOAP, Java, and .NET. Multiple platform-specific models can exist for a given PIM. Two PSMs are provided in this
specification:
• REST/HTTP PSM - a binding of the PIM as a REST/HTTP API using OpenAPI specification.
• OSLC PSM - a binding of the PIM as services based on the OSLC standard.
For each PSM, a mapping is defined. This mapping is used to generate the PSM from the PIM.
Fig. 2 illustrates the PIM, PSMs, Service Providers that implement API PSMs, and Service Consumers that
consume the API PSMs from multiple Providers.
Service specifications in the PIM do not prescribe or constrain the architecture of the Service Providers. For
example, Service Providers with file-based, 3-tier application-based, or federated microservices-based architectures
can all implement one or more PSMs derived from the same service specifications (PIM).
Service Consumers that use a specific PSM should be interoperable across multiple Service Providers that
implement that PSM without requiring any modification in the consumer.
Fig. 3 illustrates the role of PIM and PSMs in the context of Systems Modeling API and Services providers and
consumers. The Systems Modeling API and Services, version 1.0, includes two PSMs, specifically the REST/HTTP
PSM and OSLC 3.0 PSM.
A System Modeling API and Services provider implements either or both the PSMs using its native technology
stack, such as databases and web-service frameworks. Service consumers, such as those used for programmatic,
graphical, or textual authoring, navigation, and querying data use the PSMs (e.g. REST/HTTP API), agnostic of the
native technology stack of the providers.
The choice of REST/HTTP PSM is key. Most modern programming languages provide libraries for consuming
REST/HTTP APIs. Enterprise applications, written in any modern programming language, can consume the
standard Systems Modeling API and Services, and interoperate with multiple providers.
Service definitions
1. Names of classes representing services start with an uppercase letter and use the camel case notation, such
as ElementNavigationService.
2. Names of operations representing the API calls available for each service start with a lowercase letter and
are italicized, such as getElementById
1. Names of classes representing data that is the input or output of services start with an uppercase letter,
such as Project and Data
2. Names of attributes representing the details of the data that is the input or output of services start with a
lowercase letter and are italicized, such as identifier
The services and operations in the PIM are presented using class diagrams and tables with descriptions of each
operation.
• Clause 7 - Platform Independent Model (PIM) of the Systems Modeling API and Services
• Clause 8 - Platform Specific Models (PSMs) of the Systems Modeling API and Services
◦ 8.1 - REST/HTTP PSM
◦ 8.2 - OSLC PSM
• Annex A defines the suite of conformance tests that must be used to demonstrate the conformance of
Service Providers to this specification - see Clause 2 .
• Annex B includes the following.
◦ Examples of requests and responses for the REST/HTTP API endpoints, and
◦ Cookbook with a collection of recipes, as Jupyter notebooks, demonstrating patterns and
examples for using the Systems Modeling API and Services
6.4 Acknowledgements
The primary authors of this specification document, the PIM, and the REST/HTTP PSM are:
The specification was formally submitted for standardization by the following organizations:
• 88Solutions Corporation
• Dassault Systèmes
• GfSE e.V.
• IBM
• INCOSE
• Intercax LLC
• Lockheed Martin Corporation
• Model Driven Solutions, Inc.
• PTC
• Simula Research Laboratory AS
However, work on the specification was also supported by over 200 people in 80 organizations that participated in
the SysML v2 Submission Team (SST). The following individuals had leadership roles in the SST:
The specification was prepared using CATIA No Magic modeling tools and the OpenMBEE system for model
publication (http://www.openmbee.org), with the invaluable support of the following individuals:
The following individuals made significant contributions to the API and Services pilot implementation developed by
the SST in conjunction with the development of this specification:
Record
attributes
+id : UUID{readOnly}
+resourceIdentifier : IRI [0..1]
+alias : String [1..*]{readOnly}
+humanIdentifier : String{readOnly,subsets alias}
+description : String
Tag Branch
Record - A Record represents any data that is consumed (input) or produced (output) by the Systems Modeling API
and Services. A Record is an abstract concept from which other concrete concepts inherit. A Record has the
following attributes:
DataVersion
DataIdentity
Data
identity version version payload operations
1 0..1 +getId() : UUID
1 1..*
/project 1
+branches Branch
{subsets 1..*
commitReferences}
1 +defaultBranch Tag
{subsets
branches} +tags
{subsets 0..*
commitReferences}
The class diagram above presents concepts related to Project and Data Versioning Service.
Data - Data represents any entity that can be created, updated, deleted, and queried by the Systems Modeling API
and Services. In the PIM, Data is represented as an Interface that is realized by the following concepts in the scope
of Systems Modeling API and Services.
Each realization of Data must implement the getId() operation that provides a valid UUID.
Data Identity - Data Identity is a subclass of Record that represents a unique, version-independent representation of
Data through its lifecycle. A Data Identity is associated with 1 or more Data Version records that represent different
versions of the same Data. A Data Identity record has the following additional attributes:
• createdAt is a derived attribute that references the Commit in a project in which the given Data was
created
• deletedAt is a derived attribute that references the Commit in a project in which the given Data was
deleted
Data Version - Data Version is a subclass of Record that represents Data at a specific version in its lifecycle. A
Data Version record is associated with up to one (0..1) Data Identity record. Data Version serves as a wrapper for
Data (payload) in the context of a Commit in a Project; associating the data identity with the state of the Data
(payload) in the specific (range of) Commits, or no payload if no Data element with the given identifier is present at
• One (1) Data Identity record is created for all versions of the same Data, where Data Identity.id returns the
same UUID value as Data.getId()
• A Data Version record is created for each version of Data (and, if needed, also for a Commit where no
Data exists for the given identity), where:
◦ Data Version.payload is set to Data if exists in the commit, null otherwise.
◦ Data Version.identity is set to the Data Identity common to all versions of the same Data.
◦ Data Version.id is set to a new, randomly generated UUID for the specific Data Version record.
• commit: project commit at which the wrapped data (payload) was created, modified, or deleted.
• /project: derived attribute referencing the owning project
Project - Project is a subclass of Record that represents a container for other Records and an entry point for version
management and data navigation. The Project record has the following attributes:
• identifiedData is a derived attribute that is the set of Data Identity records corresponding to the Data
contained in the project
• commit is the set of all commits in the Project
• commitReference is the set of all commit references in the Project
• branch is the set of all the branches in the Project and a subset of commitReference
• defaultBranch is the default branch in the Project and a subset of branch
• tag is the set of all the tags in the Project and a subset of commitReference
• usage is the set of Project Usage records representing all other Projects being used by the given Project
(Project Usage.usedProject)
• queries is the set of Query records owned by the project. Each Query record represents a saved query for
the given project. See Query for details.
• created is the creation timestamp for the project, in ISO8601DateTIme format.
A project also represents a permission target at which access and authorization controls may be applied to teams
associated with a project.
Project Usage - Project Usage is a subclass of Record that represents the use of a Project in the context of another
Project. Project Usage is represented as a realization of Data, and has the following attributes:
Commit - Commit is a subclass of Record that represents the changes made to a Project at a specific point in time in
its lifecycle, such as the creation, update, or deletion of data in a Project. A Project has 0 or more Commits. A
Commit has the following attributes:
• Commit.versionedData must indicate only the Data records that actually exist at the given Commit; all
listed DataVersion records must have their payload attribute set to a non-null Data record.
Commits are immutable. For a given Commit record, the value of Commit.change cannot be modified after a
Commit has been created. If a modification is required, a new Commit record can be created with a different value
of Commit.change.
Commits are not destructible1. A Commit record cannot be deleted during normal end-user operation. Commits
represent the history and evolution of a Project. Deleting and mutating Commit records must be disabled for the
normal end-user operations to preserve Project history.
1
Note: A provider tool may provide administrative functions to repair the Commit graph of a Project but this is not
considered a normal end-user operation.
Commit Reference - Commit Reference is an abstract subclass of Record that references a specific Commit
(Commit Reference.referencedCommit). Project.commit is the set of all the Commit records for a given Project.
Project.commitRefererence identifies specific Commit records in a Project that provide the context for navigating the
Data in a Project. Two special types of Commit Reference are Branch and Tag, as described below.
Branch - Branch is an indirect subclass of Record (via CommitReference) that represents an independent line of
development in a project. A Project can have 1 or more branches. When a Project is created, a default branch is also
created. The default branch of a project can be changed, and a project can have only 1 default branch.
A Branch is a type of Commit Reference. A Branch is a pointer to a commit (Branch.head). The commit history of a
Project on a given branch can be computed by recursively navigating Commit.previousCommit, starting from the
head commit of the branch (Branch.head). A Branch has the following additional attributes:
Branches are immutable. Since a Branch is a pointer to a Commit, it can be updated to point to a different Commit.
If a new Commit is created on a Project Branch, the value of Branch.head refers to that new Commit.
Branches are destructible under normal end-user operation. Branches can be deleted and merged with other
branches.
Tag - Tag is an indirect subclass of Record (via Commit Reference) used for annotating specific commits-of-interest
during Project development, such as for representing Project milestones, releases, baselines, or snapshots. A Project
can have 0 or more tags.
Tags are immutable. Tag.taggedCommit cannot be modified after a Tag record has been created. If
Tag.taggedCommit needs to be modified to refer to a different Commit record, then the existing Tag can be deleted
and a new Tag can be created with the same name and description.
The table below summarizes the Mutability and Destruction semantics for Commit, Branch, and Tag.
Data
operations
+getId() : UUID
elementEnd
ExternalRelationship Element
attributes
specification : String [0..1] ExternalData
language : String [0..1] externalDataEnd attributes
resourceIdentifier : IRI
• specification is the formal representation of the semantics of the ExternalRelationship. The specification
can be a collection of mathematical expressions. For example, an ExternalRelationship can be defined to
map the attributes of a KerML Element to the attributes of an ExternalData. In this case, the specification
would contain mathematical expressions, such as equations, representing the mapping. This is an optional
attribute.
• language is the name of the expression language used for the specification. This is an optional attribute.
ExternalData - ExternalData is a realization of Data, and represents a resource external to a given tool or
repository. ExternalData is defined only for the purpose of defining an ExternalRelationship. An ExternalData has
the following additional attributes.
Record
attributes
+id : UUID{readOnly}
+resourceIdentifier : IRI [0..1]
+alias : String [1..*]{readOnly}
+humanIdentifier : String{readOnly,subsets alias}
+description : String
Query
Project +project +queries attributes
+name : String
1 0..*
select : String [0..*]
scope : Data [0..*]
orderBy : String [0..*]
where
Constraint 2..*
+constraint
PrimitiveConstraint CompositeConstraint
attributes
inverse : Boolean
property : String
value : String [1..*]
operator
operator
JoinOperator
Operator
and
instanceOf
or
=
<
<=
>
>=
in
The class diagram above presents concepts related to the Query service.
Query - Query is a subclass of Record that represents a precise and language-independent request for information
retrieval using the Systems Modeling API and Services. Query can be mapped to commonly used query languages,
such as SQL, Gremlin, GraphQL, and SPARQL.
Constraint - Constraint is an abstract concept that represents conditions that must be satisfied by Data objects in the
query response.
PrimitiveConstraint is a concrete subtype of Constraint that represents simple conditions that can be modeled using
the property-operator-value tuple, e.g. mass <= 4 kg., or type instanceOf Generalization. A PrimitiveConstraint has
the following attributes:
CompositeConstraint is a concrete subtype of Constraint that represents complex conditions composed of two or
more Constraints using logical AND or OR operator. CompositeConstraint has the following attributes:
ProjectService
operations
getProjects() : Project [0..*]
getProjectById( projectId : UUID ) : Project [0..1]
createProject( name : String, description : String [0..1] ) : Project
updateProject( projectId : UUID, name : String [0..1], description : String [0..1], defaultBranch : Branch [0..1] ) : Project
deleteProject( projectId : UUID ) : Project
ElementNavigationService
operations
getElements( project : Project, commit : Commit ) : Element [0..*]
getElementById( project : Project, commit : Commit, elementId : UUID ) : Element [0..1]
getRelationshipsByRelatedElement( project : Project, commit : Commit, elementId : UUID, direction : Direction ) : Relationship [0..*]
getRootElements( project : Project, commit : Commit ) : Element [0..*]
«enumeration»
Direction
in
out
both
Element is the root metaclass in the KerML abstract syntax [KerML]. Relationship is a subtype of Element. Both
Element and Relationship realize the Data interface defined in the API Model (refer to 7.1.2 - Project Data
Versioning).
Table 2. Operations
Name Documentation
Get all the root elements in the given project at the
getRootElements given commit.
ProjectDataVersioningService
operations
getCommits( project : Project ) : Commit [0..*]
getHeadCommit( project : Project, branch : Branch [0..1] ) : Commit
getCommitById( project : Project, commitId : UUID ) : Commit [0..1]
createCommit( change : DataVersion [1..*], branch : Branch [0..1], previousCommits : Commit [0..*], project : Project ) : Commit
getCommitChange( project : Project, commit : Commit ) : DataVersion [1..*]
getCommitChangeById( project : Project, commit : Commit, changeId : UUID ) : DataVersion
getBranches( project : Project ) : Branch [1..*]
getBranchById( project : Project, branchId : UUID ) : Branch [0..1]
getDefaultBranch( project : Project ) : Branch [1]
setDefaultBranch( project : Project, branchId : UUID ) : Project [1]
createBranch( project : Project, branchName : String, head : Commit ) : Branch [1]
deleteBranch( project : Project, branchId : UUID ) : Branch [0..1]
getTags( project : Project ) : Tag [1..*]
getTagById( project : Project, tagId : UUID ) : Tag
getTaggedCommit( project : Project, tag : Tag ) : Commit
createTag( project : Project, tagName : String, taggedCommit : Commit ) : Tag [1]
deleteTag( project : Project, tagId : UUID ) : Tag [0..1]
mergeIntoBranch( baseBranch : Branch, commitsToMerge : Commit [1..*], resolution : Data [0..*], description : String [0..1] ) : MergeResult
diffCommits( baseCommit : Commit, compareCommit : Commit ) : DataDifference [0..*]
getTagById Get the tag with the given id (tagId) in the given project.
7.2.4 QueryService
QueryService
operations
getQueries( project : Project ) : Query [0..*]
getQueryById( project : Project ) : Query [0..1]
createQuery( name : String, project : Project, select : String [0..*], scope : Data [0..*], where : Constraint, orderBy : String [0..*] ) : Query
updateQuery( project : Project, updateQuery : Query ) : Query
deleteQuery( project : Project, queryId : UUID ) : Query
executeQueryById( queryId : UUID, commit : Commit [0..1] ) : Data [0..*]
executeQuery( query : Query, commit : Commit [0..1] ) : Data [0..*]
7.2.5 ExternalRelationshipService
ExternalRelationshipService
operations
getExternalRelationships( project : Project, commit : Commit ) : ExternalRelationship [0..*]
getExternalRelationshipsByElement( project : Project, commit : Commit, elementId : UUID ) : ExternalRelationship [0..*]
getExternalRelationshipById( project : Project, commit : Commit, externalRelationshipId : UUID ) : ExternalRelationship [0..1]
7.2.6 ProjectUsageService
ProjectUsageService
operations
getProjectUsages( project : Project, commit : Commit ) : ProjectUsage [0..*]
createProjectUsage( project : Project, branch : Branch [0..1], projectUsage : ProjectUsage ) : Commit
deleteProjectUsage( project : Project, branch : Branch [0..1], projectUsageId : UUID ) : Commit
• PIM API Model - REST/HTTP PSM Model Mapping: This section presents the mapping from the PIM
API Model concepts to the JSON Models in the REST/HTTP PSM (OpenAPI specification).
• PIM API Services - REST/HTTP PSM Endpoints Mapping: This section presents the mapping from
the PIM API Service definitions and operations to the API endpoints in the REST/HTTP PSM (OpenAPI
specification).
ElementNavigationService
getElements GET/projects/{projectId}/commits/{commitId}/elements
getElementById GET /projects/{projectId}/commits/{commitId}/elements/{elementId}
GET
/projects/{projectId}/commits/{commitId}/elements/{relatedElementId}/
relationships
getRelationshipsByRelatedElement
• direction query parameter with allowable values {in, out, both}
ProjectDataVersioningService
getCommits GET /projects/{projectId}/commits
• PUT /projects/{projectId}
• The body of the PUT request is a ProjectRequest. Set the ID of
setDefaultBranch
the new default branch as ProjectRequest.defaultBranch in the
body.
QueryService
getQueries GET /projects/{projectId}/queries
getQueryById GET /projects/{projectId}/queries/{queryId}
createQuery POST /projects/{projectId}/queries
updateQuery PUT /projects/{projectId}/queries/{queryId}
deleteQuery DELETE /projects/{projectId}/queries/{queryId}
executeQueryById GET /projects/{projectId}/queries/{queryId}/results
GET /projects/{projectId}/query-results
POST /projects/{projectId}/query-results
executeQuery Either the GET or the POST endpoint may be used. The POST endpoint is
provided for compatibility with clients that don't support GET requests with
a body
ExternalRelationshipService
Pagination
The REST/HTTP PSM uses a Cursor-based pagination strategy for the responses received from the GET requests.
The following 3 query parameters can be specified in any GET request that returns a collection of records.
1. page[size] specifies the maximum number of records that will be returned per page in the response
2. page[before] specifies the URL of the page succeeding the page being requested
3. and page[after] specifies the URL of a page preceding the page being requested
If neither page[before] nor page[after] is specified, the first page is returned with the same number of records as
specified in the page[size] query parameter. If the page[size] parameter is not specified, then a default page size is
used, which can be set by the API provider.
The Link header in the response includes links (URLs) to the previous page and the next page, if any, for the given
page in the response. The specification of these links is conformant to the IETF Web Linking standard. As an
example, the value of the Link response header is shown below. The rel value associated with each page link
specifies the type of relationship the linked page has with the page returned in the response. Page link specified with
<http://sysml2-api-host:9000/projects?
page[after]=MTYxODg2MTQ5NjYzMnwyMDEwOWY0MC00ODI1LTQxNmEtODZmNi03NTA4YWM0MmEwMjE&
page[size]=3>; rel="next",
<http://sysml2-api-host:9000/projects?
page[before]=MTYxODg2MTQ5NjYzMnwxMDg2MDFjMS1iNzk1LTRkMGEtYTFiYy1lZjEyYmMwNTU5ZjI&
page[size]=3>; rel="prev"
Example
An example demonstrating the Cursor-based paginated responses received from GET requests to the /projects
endpoint is presented here. The term "User" in the example scenario presented below refers to an API user that
could be a human user or a software program.
Step 1 - User makes a GET request to the /projects endpoint with page[size] query parameter set to 3. If successful,
this request will return the first page with a maximum of 3 project records. The URL for this GET request is shown
below.
http://sysml2-api-host:9000/projects?page[size]=3
Step 2 - If there are more than 3 projects in the provider repository, the Link header in the response will provide the
URL for the next page with rel value equal to next. The User gathers the link to the next page.
<http://sysml2-api-host:9000/projects?
page[after]=MTYxODg2MjE2NTMxNXwwOGY0MzNkYi1iNmQ0LTQxYjgtOTAyMC1lODIwZWJjNDE3YmU&
page[size]=3>; rel="next"
Step 3 - User makes a GET request to the URL for the next page gathered from Step 2. The Link header in the
response will provide the URL for the next page with rel value equal to next. Additionally, the Link header will
include the URL for the previous page with rel value equal to prev.
<http://sysml2-dev.intercax.com:9000/projects?
page[after]=MTYxODg2MjY4OTYxNHwyMDEwOWY0MC00ODI1LTQxNmEtODZmNi03NTA4YWM0MmEwMjE&
page[size]=3>; rel="next",
<http://sysml2-dev.intercax.com:9000/projects?
page[before]=MTYxODg2MjY4OTYxNHwxMDg2MDFjMS1iNzk1LTRkMGEtYTFiYy1lZjEyYmMwNTU5ZjI&
page[size]=3>; rel="prev"
Step 4 - User continues Step 3 until the Link header in the response does not include the URL for the next page (rel
value as next).
Note that the URLs listed in the OpenAPI Specification are provided as examples only. With OSLC, all URLs are
implementation-specific. A OSLC client typically relies on the OSLC discovery mechanism (https://docs.oasis-
open-projects.org/oslc-op/core/v3.0/ps01/discovery.html), to determine what services are provided by an OSLC
server, as well as the necessary information (such as a service URL) to be able to consume any such service. At the
least, an OSLC client requires a discovery URL to bootstrap this discovery for any particular server. The various
approaches for bootstrapping and discovery are further detailed in the OSLC standard.
An OSLC implementation may typically need to realize a broader set of services than those defined by the PIM for
full integration with other OSLC-compliant systems. Services such as Delegated UI for Selection and Creation,
resource UI Preview, authentication, and support for arbitrary queries (beyond those defined in the PIM).
Open Services for Lifecycle Collaboration (OSLC) is an open community creating specifications for integrating
tools. OSLC specifications allow conforming independent software and product lifecycle tools to integrate their data
and workflows in support of end-to-end lifecycle processes. OSLC is based on the W3C Linked Data and the use of
RDF to represent artifacts using common vocabularies, and HTTP to discover, create, read, update, and delete such
artifacts. For a more comprehensive introduction, see the OSLC Primer and the OSLC specifications at https://open-
services.net/specifications/.
1. Creation factories for creating a resource of some RDF type associated with the factory. For example, a
client might create a new change request by an HTTP POST including the RDF representation of the
change request to be created to the URI of a change request creation factory.
2. REST services to read, update, and/or delete resources at the resource's URI.
3. Query capabilities that allow OSLC clients to query for resources of an RDF type associated with the
query capability. For example, a client might query for change requests by an HTTP GET or POST to the
query base URI of a query capability for change requests. See OSLC Query Version 3.0 for further details.
4. Creation dialog that allows some other application to embed it in an iFrame of an application dialog that
allows a user to fill in information and create a resource of some type associated with the creation dialog.
5. Selection dialog that allows an application to display it to select a resource of some type associated with
the dialog in order to create and persist a link to that resource in the application.
6. Resource preview, such as a pop-up display, that is shown as a rich hover when a user hovers over a link
to a resource managed by the OSLC server.
OSLC Discovery
OSLC clients and other servers discover the OSLC capabilities offered by a server through OSLC discovery. This
allows clients to discover the URIs of creation factories, query capabilities, creation dialogs, and selection dialogs
without the need for hard coding or constructing URIs for them. Discovery starts with a known URI for an OSLC
Service Provider Catalog. That service provider catalog may reference zero, one, or many service providers. Servers
that support the concept of project as a container of resources, often for access control, often define a service
provider for each such container. A service provider may declare one or many services, each of which may define
the creation factories, query capabilities, creation dialogs, and selection dialogs supported by that service. For more
details, see OSLC Core Version 3.0. Part 2: Discovery.
1. Start with a known OSLC service provider catalog URI, perform HTTP GET.
2. Get the URIs of service providers from the response.
3. For each service provider, perform HTTP GET.
4. From the response, look for services described in the response data, that declare a creation factory for the
RDF type.
5. Get the URI of the creation factory.
Resource shapes specify a standard way (using RDF) of describing resources of specific RDF types and their
properties. For more details, see OSLC Core Version 3.0. Part 6: Resource Shape. Resource shapes may be
discovered in a number of ways:
1. The definition of a creation factory may reference a resource shape that describes the properties that might
be included in the RDF content POSTed to that creation factory.
2. The definition of a query capability may reference a resource shape that describes the properties of the
query results and references a shape that describes the properties that might be queried as a condition, or
selected to be included in the results.
3. A resource may reference an instance shape that describes the properties of that resource.
Linked Data Platform Containers (LDPC) are a way of representing containers as an RDF resource. OSLC
specifications specify LPDCs as a container representation. See W3C Linked Data Platform 1.0 for further
information.
A "global" service provider will contain one or more services that cross all systems modeling projects. A service
provider will be declared for each systems modeling project that provides capabilities specific to that project.
OSLC recommends that servers support RDF/XML (application/rdf+xml), Turtle (text/turtle, application/x-turtle),
and JSON-LD ( application/ld+json).
1. Mapping from the KerML and SysML abstract syntax (Element and subtypes) to OSLC resource shapes
and vocabulary. The package containing the resulting OSLC resource shapes and vocabulary is included
with this specification - see OSLC_Systems_Modeling_Resource_Shapes_and_Vocabulary.zip.
2. Mapping from the API Model concepts to resource types in other OSLC specifications, such as OSLC
Configuration Management specification and OSLC Query specification. This mapping is shown in the
table below. References to the OSLC specifications mentioned in the table below are as follows.
1. OSLC Configuration Management refers to OSLC Configuration Management Version 1.0
available at https://oslc-op.github.io/oslc-specs/specs/config/oslc-config-mgt.html.
2. OSLC Query refers to OSLC Query Version 3.0 available at https://docs.oasis-open-
projects.org/oslc-op/query/v3.0/os/oslc-query.html
Component (oslc_config:Component)
Project PIM project id
(OSLC Configuration Management)
Stream (oslc_config:Stream)
Branch PIM branch id
(OSLC Configuration Management)
Baseline (oslc_config:Baseline)
Tag PIM tag id
(OSLC Configuration Management)
Commit Not supported by OSLC Configuration Management. PIM commit id
Concept resource
DataIdentity PIM Data Identity id
(OSLC Configuration Management)
Version resource (oslc_config:VersionResource)
DataVersion PIM Data Version id
(OSLC Configuration Management)
OSLC Query
Query
(OSLC Query)
oslc.where in OSLC Query
PrimitiveConstraint
(OSLC Query)
oslc.where in OSLC Query
CompositeConstraint
(OSLC Query)
Not Available.
ProjectUsage PIM Project concept is mapped to OSLC Component
but OSLC does not define Component Usage.
DataDifference Not Available
MergeResult Not Available
Example: Query for components with identifier 123, returning all properties.
GET queryBaseUri?
oslc.where=dcterms%3Aidentifier%3D%22123%22&
oslc.select=*
Example:
POST creationFactoryUri
Execute an HTTP PUT with the revised content of the component. The RDF content
should be compliant with the instance resource shape of the Component, and this
updateProject should be compatible with the resource shape for Component as described in the
OSLC specification (see https://docs.oasis-open-projects.org/oslc-op/config/v1.0/
ps01/config-resources.html#ComponentShape)
ElementNavigation
Service
1. Discover a query capability for elements (an API-specific RDF type) for
the specified project. See OSLC Discovery section.
2. Perform a GET on the query base, specifying which properties, if any, of
the commit should be returned in the query result using an oslc.select query
parameter.
getElements
Example: Query for elements returning name (dcterms:title) and identifier
(dcterms:identifier).
GET queryBaseUri?
oslc.select=dcterms%3Atitle%2Cdcterms%3Aidentifier
1. Discover a query capability for elements (an API-specific RDF type) for
the specified project. See OSLC Discovery section.
2. Perform a GET on the query base, specifying a query for the
getElementById dcterms:identifier in a oslc.where query parameter, and specifying which
properties, if any, of the commit should be returned in the query result
using an oslc.select query parameter.
Example: Query for elements with identifier 123, returning all properties.
GET queryBaseUri?
oslc.where=dcterms%3Aidentifier%3D%22123%22&
oslc.select=*
1. Discover the query capability for Elements for the particular project (and
its specific commit). See OSLC Discovery section.
2. Perform a GET on the query base, setting the oslc.where query parameter
to:
1. sysml:out = URI of the subject element to get all the outgoing
Relationships from that element
2. sysml:in = URI of the subject element to get all the incoming
Relationships to the element
For Direction equal to both: perform and merge the separate queries on in and out
values.
Not Available.
getRootElements OSLC Query does not currently support the ability to search for resources, where
certain properties (owner in this case) are not set.
ProjectDataVersioning
Service
Example: Query for streams with identifier 123, returning all properties.
GET queryBaseUri?
oslc.where=dcterms%3Aidentifier%3D%22123%22&
oslc.select=*
Example: Query for baselines with identifier 123, returning all properties.
GET queryBaseUri?
oslc.where=dcterms%3Aidentifier%3D%22123%22&
oslc.select=*
Not available. The OSLC Configuration Management specification does not define
getCommits
any notion of a commit. Versions of specific resources may be fetched.
Note that this only supports a new commit along a branch with the previous latest
commit being its previous commit. If a client wants to commit from an earlier
createCommit
version, they must first create a stream (branch) from that earlier baseline (commit)
and then use a PUT with that new stream.
The OSLC Configuration Management specification does not currently define any
mechanisms for creating new versions of multiple versioned resources in a single
REST operation.
Example 1:
PUT conceptResourceUri?
oslc_config.context=urlEncodedStreamUri
Example 2:
Headers: Configuration-Context=streamUri
PUT conceptResourceUri
1. Discover a query capability for commits (a API-specific RDF type) for the
specified project. See OSLC Discovery section.
2. Perform a GET on the query base, specifying a query for the
dcterms:identifier in a oslc.where query parameter, and specifying which
properties, if any, of the commit should be returned in the query result
getCommitById using an oslc.select query parameter.
Example: Query for commits with identifier 123, returning all properties.
GET queryBaseUri?
oslc.where=dcterms%3Aidentifier%3D%22123%22&
oslc.select=*
Not available. The OSLC Configuration Management specification does not define
any notion of a commit. New versions may be created in the context of a stream or
getCommitChange change set. However, the OSLC Configuration Management specification does not
define any means to commit a change set or deliver the changes in a stream or change
set to another stream.
Not available. The OSLC Configuration Management specification does not define
any notion of a commit. New versions may be created in the context of a stream or
getCommitChangeById change set. However, the OSLC Configuration Management specification does not
define any means to commit a change set or deliver the changes in a stream or change
set to another stream.
Example:
createBranch POST creationFactoryUri
or
B) Use the streams LDPC of a component
1. Get the URI of the streams LDPC from the RDF of a component.
2. POST the RDF content describing the stream (with a Content-Type header
set to an RDF media type supported by the server) to the LDPC. The RDF
content should be compatible with the resource shape for Stream as
described in the specification (see https://docs.oasis-open-projects.org/oslc-
op/config/v1.0/ps01/config-resources.html#StreamShape)
Example:
POST streamsLdpcUri
QueryService
Not Available
getQueryById OSLC does not provide any RDF representation or persistence mechanisms of OSLC
queries.
Not Available
getQueries OSLC does not provide any RDF representation or persistence mechanisms of OSLC
queries.
Not Available
executeQueryById OSLC does not provide any RDF representation or persistence mechanisms of OSLC
queries.
Not Available
createQuery OSLC does not provide any RDF representation or persistence mechanisms of OSLC
queries.
1. Discover a query capability for the specified project. See OSLC Discovery
section.
2. Perform a GET on the query base, specifying the following. See OSLC
executeQuery Query Capability in OSLC Nomenclature
1. The oslc.where query parameter to filter for the desired elements
2. The oslc.select query parameter, to define the element properties
that should be returned in the query result.
ProjectUsageService
Not available. The OSLC Configuration Management specification does not define
createProjectUsage
any notion of component usage.
Not available. The OSLC Configuration Management specification does not define
deleteProjectUsage
any notion of component usage.
Not available. The OSLC Configuration Management specification does not define
getProjectUsages
any notion of component usage.
Operation create_project
PIM-PS-001
Description Create Project - success
1. _description : String[0..1]
Input
2. _name : String[1]
Scenario
Operation get_projects
PIM-PS-002
Description Get Projects - success
Input None
Scenario
Precondition (OCL)
Execute operation get_projects() :
Steps
Project[0..*]
PIM-PS-004
Description Get Project by ID - does not exist
1. _project : Project[1]
Input
2. _commit : Commit[1]
Project.allInstances()->includes(_project)
Precondition (OCL) Commit.allInstance()->includes(_commit)
_commit.owningProject = _project
Operation get_element_by_id
PIM-EN-002
Description Get Element by ID - success
Project.allInstances()->includes(_project)
Commit.allInstance()->includes(_commit)
Precondition (OCL) _commit.owningProject = _project
let _element : Element = _commit.version->select(identity
_element.size() = 1
PIM-EN-003
Description Get Element by ID - does not exist at Commit
Project.allInstances()->includes(_project)
Commit.allInstance()->includes(_commit)
Precondition (OCL) _commit.owningProject = _project
_commit.version->select(identity.id = _elementId and data
Operation get_relationships_by_source
PIM-EN-004
Description Get Relationships by source (Element) - success
Project.allInstances()->includes(_project)
Commit.allInstance()->includes(_commit)
Precondition (OCL) _commit.owningProject = _project
let _element : Element = _commit.version->select(identity
_element.size() = 1
Execute operation
get_relationships_by_source(project =
Steps
_project, commit = _commit, elementId =
_elementId) : Relationship[0..*]
Operation get_relationships_by_target
PIM-EN-005
Description Get Relationships by target (Element) - success
Project.allInstances()->includes(_project)
Commit.allInstance()->includes(_commit)
Precondition (OCL) _commit.owningProject = _project
let _element : Element = _commit.version->select(identity
_element.size() = 1
Execute operation
get_relationships_by_target(project =
Steps
_project, commit = _commit, elementId =
_elementId) : Relationship[0..*]
Operation create_branch
PIM-PCB-001
Description Create Branch - success
Project.allInstances()->includes(_project)
Commit.allInstance()->includes(_head)
Precondition (OCL) _head.owningProject = _project
let _record : Record = Record.allInstances()
Operation get_branches
PIM-PCB-002
Description Get Branches - success
Operation get_branch_by_id
PIM-PCB-003
Description Get Branch by ID - success
1. _project : Project[1]
Input
2. _branchId : UUID[1]
Project.allInstances()->includes(_project)
Precondition (OCL) let _branch : Branch = _project.branch->select(id = _bran
_branch.size() = 1
PIM-PCB-004
Description Get Branch by ID - does not exist in Project
Project.allInstances()->includes(_project)
Precondition (OCL) _project.branch->select(id = _branchId)->isEmpty()
Operation delete_branch
PIM-PCB-005
Description Delete Branch - success
1. _project : Project[1]
Input
2. _branchId : UUID[1]
Project.allInstances()->includes(_project)
Precondition (OCL) let _branch : Branch = _project.branch->select(id = _bran
_branch.size() = 1
PIM-PCB-006
Description Delete Branch - does not exist in Project
1. _project : Project[1]
Input
2. _branchId : UUID[1]
Project.allInstances()->includes(_project)
Precondition (OCL) _project.branch->select(id = _branchId)->isEmpty()
Operation get_default_branch
PIM-PCB-007
Description Get default Branch - success
Operation set_default_branch
PIM-PCB-008
Description Set default Branch - success
1. _project : Project[1]
Input
2. _branchId : UUID[1]
Project.allInstances()->includes(_project)
Precondition (OCL) let _branch : Branch = _project.branch->select(id = _bran
_branch.size() = 1
PIM-PCB-009
Description Set default Branch - does not exist in Project
1. _project : Project[1]
Input
2. _branchId : UUID[1]
Project.allInstances()->includes(_project)
Precondition (OCL) _project.branch->select(id = _branchId)->isEmpty()
let _defaultBranch : Branch = _project.defaultBranch
1. _project : Project[1]
2. _change : DataVersion[1..*]
Input
3. _branch : Branch[0..1]
4. _previousCommit : Commit[0..*]
Project.allInstances()->includes(_project)
_branch->isEmpty() or _project.branch->includes(_branch)
Precondition (OCL) _previousCommit->isEmpty() or _previousCommit->forAll(own
let _record : Record = Record.allInstances()
let _head : Commit = _branch.head
Operation get_commit_by_id
PIM-PCB-011
Description Get commit by ID - success
1. _project : Project[1]
Input
2. _commitId : UUID[1]
Project.allInstances()->includes(_project)
Precondition (OCL) let _commit : Commit = _project.commit->select(id = _comm
_commit.size() = 1
PIM-PCB-012
Description Get commit by ID - does not exist in Project
1. _project : Project[1]
Input
2. _commitId : UUID[1]
Project.allInstances()->includes(_project)
Precondition (OCL) _project.commit->select(id = _commitId)->isEmpty()
Operation get_head
PIM-PCB-013
Description Get head Commit of Branch - success
Project.allInstances()->includes(_project)
Precondition (OCL) Branch.allInstance()->includes(_branch)
_branch.owningProject = _project
PIM-PCB-014
Description Get head Commit of Branch - Branch does not exist
1. _project : Project[1]
Input
2. _branch : Branch[1]
Project.allInstances()->includes(_project)
Precondition (OCL) Branch.allInstance()->excludes(_branch)
PIM-PCB-015
Description Get head Commit of Branch - Branch not in Project
1. _project : Project[1]
Input
2. _branch : Branch[1]
Project.allInstances()->includes(_project)
Precondition (OCL) Branch.allInstance()->includes(_branch)
_branch.owningProject <> _project
Operation create_query
PIM-QS-001
Description Create Query - success
Project.allInstances()->includes(_project)
Precondition (OCL) let _record : Record = Record.allInstances()
1. _query : Query[1]
Input
2. _commit : Commit[1]
Query.allInstances()->includes(_query)
Precondition (OCL) Commit.allInstances()->includes(_commit)
_query.owningProject = _commit.owningProject
Scenario
• get_elements(project = _project,
…)
• get_element_by_id(project =
_project, …)
• get_relationships_by_source(project
= _project, …)
• get_relationships_by_target(project
= _project, …)
• create_branch(project = _project,
…)
• get_branches(project = _project)
• get_branch_by_id(project =
Steps
_project, …)
• delete_branch(project = _project,
…)
• get_default_branch(project =
_project)
• set_default_branch(project =
_project, …)
• create_commit(project = _project,
…)
• get_commit_by_id(project =
_project, …)
• get_head(project = _project, …)
• create_query(project = _project,
…)
PIM-CC-002
Description Execute operation - missing Commit input
Scenario
Precondition (OCL)
PIM-CC-003
Description Execute operation - Project input does not exist
• get_elements(project = _project,
…)
• get_element_by_id(project =
_project, …)
• get_relationships_by_source(project
= _project, …)
• get_relationships_by_target(project
= _project, …)
• create_branch(project = _project,
…)
• get_branches(project = _project)
• get_branch_by_id(project =
Steps
_project, …)
• delete_branch(project = _project,
…)
• get_default_branch(project =
_project)
• set_default_branch(project =
_project, …)
• create_commit(project = _project,
…)
• get_commit_by_id(project =
_project, …)
• get_head(project = _project, …)
• create_query(project = _project,
…)
PIM-CC-004
Description Execute operation - Commit input does not exist
PIM-CC-005
Execute operation - Commit input is not owned by
Description
Project input
1. _project : Project[1]
Input
2. _commit : Commit[1]
Project.allInstances()->includes(_project)
Precondition (OCL) Commit.allInstances()->includes(_commit)
_commit.owningProject <> _project
• get_elements(project = _project,
commit = _commit)
• get_element_by_id(project =
Steps _project, commit = _commit, …)
• get_relationships_by_source(project
= _project, commit = _commit, …)
• get_relationships_by_target(project
= _project, commit = _commit, …)
• create_branch(project = _project,
head = _commit, …)
PIM-CC-006
Description Execute operation - missing name input
Scenario
Precondition (OCL)
Execute any of the following operations, defined as
x(name : String[1], …) : OclAny:
Steps
• create_project(name = _name, …)
• create_branch(…, name = _name, …)
Scenario
Precondition (OCL)
Execute any of the following operations, defined as
x(id : UUID[1], …) : OclAny:
• get_project_by_id(projectId = _id)
• get_element_by_id(…, elementId =
_id)
• get_relationships_by_source(…,
elementId = _id)
• get_relationships_by_target(…,
Steps
elementId = _id)
• get_branch_by_id(…, branchId =
_id)
• delete_branch(…, branchId = _id)
• set_default_branch(…, branchId =
_id)
• get_commit_by_id(…, commitId =
_id)