Indeed, SysML is currently defined as a standard
profile of UML, tailoring the more general language
for use within the more specific systems engineering
community. User-defined profiles are also often used
within organizations and teams to succinctly capture
modeling patterns and domain-specific concepts
commonly used within those groups.
Unfortunately, profiles in UML do not actually
provide a full language extension mechanism. In
particular, the lack of a formal semantic definition for
UML means that profiles cannot provide any precise
way to extend the semantics of the language. (While
Foundational UML and succeeding standards based
on it do provide precise execution semantics for a
subset of UML, this subset does not yet include a
precise semantics for profiling.) At best, profiles
provide a formal means for syntactic extension UML.
However, most UML modeling tools provide only
limited support for even syntactic tailoring of UML
using profiles, often with little more support of user
profiles in UML 2 than the basic stereotyping and
tagging capabilities of UML 1.
However, in 2017 OMG issued a request for
proposals (RFP) for version 2 of SysML that no
longer requires the language to be a profile of UML
(SysMLv2, 2017). But the RFP includes
requirements calling for the language to have a formal
semantic basis that could be truly extended by users.
In addition, even though SysML v2 no longer needs
to be based on UML, it would be desirable to continue
to have interoperability between software and
systems modeling in the context of today’s many
software-intensive cyber-physical systems.
In response, the cross-industry team currently
working on a submission to the RFP
6
has proposed a
language architecture in which the desired SysML v2
is based on a Kernel Modeling Language (KerML)
that acts as a general foundation for building
modeling languages. KerML moves a step beyond the
current OMG Meta Object Facility (MOF)
technology, which formalizes only the definition of
the abstract syntax of a modeling language, by also
providing a formal grounding for the definition of the
semantics of modeling languages built on it. And, as
with the metaobject protocol, the idea is that, just as
SysML v2 is based on KerML, users can, in the same
way, build their own more tailored domain-specific
language extensions, syntactically and semantically,
on SysML v2. However, in contrast to the inherently
object-oriented programming mechanism proposed
by Kitczales et al., this approach can be more
6
For public incremental pre-submission releases of
SysML v2 from the submission team, go to
http://openmbee.org/sysml-v2-release.
generally termed a metasemantic protocol for
modeling language extension.
This protocol can be summarized by the following
steps:
1. Define a model library that specifies the formal
semantic concepts needed in a language
extension.
2. Define the abstract syntax for the language
extension in terms of patterns of usage of the
model library that can be mapped back to the
abstract syntax of the language being extended.
3. Define a user-friendly surface syntax for the
language extension that maps to the extended
language abstract syntax.
The first two steps of the protocol have been
applied to UML and SysML in (Bock 2011) and
(Bock 2019). This paper gives an outline of how the
protocol is being further developed in the ongoing
work on SysML v2, and, in particular, examples of
the application of the third step. While the full SysML
v2 definition includes a complete abstract syntax as
well as both graphical and textual concrete surface
syntaxes, the presentation in this paper will focus on
the textual surface syntax, due to space limitations.
Section 2 presents an overview of basic structural
modeling in KerML and its model-library-based
approach to language extension. Section 3 describes
how the metasemantic protocol is used to build
SysML v2 on KerML, and Section 4 then discusses
how the same protocol can be used to build domain-
specific language extensions to SysML v2.
2 KERNEL MODELING
LANGUAGE
KerML provides a basic set of modeling capabilities
based on a formally defined semantic core. For the
purposes of this paper, we will discuss only some
simple structure modeling capabilities and only
describe the underlying core semantics informally.
The focus, in subsequent sections, will then be on
how successive layers of user-focused modeling
languages can be built, syntactically and
semantically, on this foundation.
UML and SysML are primarily graphical
languages, and SysML v2 will also define graphical
views of models, as SysML v1 does. However, unlike
UML and SysML v1, KerML and SysML v2 will also