Skip to content

Commit a45a494

Browse files
authored
Merge pull request #265 from Open-MBEE/release/6.0.0
Release/6.0.0
2 parents 3f0592a + 824c999 commit a45a494

File tree

380 files changed

+26672
-18277
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

380 files changed

+26672
-18277
lines changed

.circleci/config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ version: 2.1
33
executors:
44
openjdk_executor:
55
docker:
6-
- image: circleci/openjdk@sha256:012843a8f91da1ea5e22e142bb5cb8c999a7457e03b8c79ab45d5fcb68043383
6+
- image: cimg/openjdk:11.0
77
environment:
88
_JAVA_OPTIONS: "-Xmx3g"
99
GRADLE_OPTS: "-Dorg.gradle.daemon=false"
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: ''
5+
labels: bug
6+
assignees: ''
7+
8+
---
9+
10+
**Describe the bug**
11+
A clear and concise description of what the bug is.
12+
13+
**To Reproduce**
14+
Steps to reproduce the behavior:
15+
1. Go to '...'
16+
2. Click on '....'
17+
3. Scroll down to '....'
18+
4. See error
19+
20+
**Expected behavior**
21+
A clear and concise description of what you expected to happen.
22+
23+
**Screenshots**
24+
If applicable, add screenshots to help explain your problem.
25+
26+
**Environment:**
27+
- MDK version:
28+
- VE version:
29+
- MMS Version:
30+
- MagicDraw or Cameo Systems Modeler Version:
31+
- Operating system: [e.g., Windows 10, macOS Mojave]
32+
33+
34+
**Additional context**
35+
Add any other context about the problem here.

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,5 @@ rebel.xml
1919
venv/*
2020
!venv/bin/
2121
*.groovy
22-
libz
22+
libz
23+
mddocs

.run/mdk-2021x-runJava.run.xml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<component name="ProjectRunConfigurationManager">
2+
<configuration default="false" name="mdk-2021x [runJava]" type="GradleRunConfiguration" factoryName="Gradle">
3+
<ExternalSystemSettings>
4+
<option name="executionName" />
5+
<option name="externalProjectPath" value="$PROJECT_DIR$" />
6+
<option name="externalSystemIdString" value="GRADLE" />
7+
<option name="scriptParameters" value="-PbuildProfile=internal-2021x --info --stacktrace --build-cache" />
8+
<option name="taskDescriptions">
9+
<list />
10+
</option>
11+
<option name="taskNames">
12+
<list>
13+
<option value="runJava" />
14+
</list>
15+
</option>
16+
<option name="vmOptions" value="" />
17+
</ExternalSystemSettings>
18+
<GradleScriptDebugEnabled>true</GradleScriptDebugEnabled>
19+
<method v="2" />
20+
</configuration>
21+
</component>

.run/mdk-runJava.run.xml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<component name="ProjectRunConfigurationManager">
2+
<configuration default="false" name="mdk [runJava]" type="GradleRunConfiguration" factoryName="Gradle">
3+
<ExternalSystemSettings>
4+
<option name="executionName" />
5+
<option name="externalProjectPath" value="$PROJECT_DIR$" />
6+
<option name="externalSystemIdString" value="GRADLE" />
7+
<option name="scriptParameters" value="-PbuildProfile=internal --info --stacktrace --build-cache" />
8+
<option name="taskDescriptions">
9+
<list />
10+
</option>
11+
<option name="taskNames">
12+
<list>
13+
<option value="runJava" />
14+
</list>
15+
</option>
16+
<option name="vmOptions" value="" />
17+
</ExternalSystemSettings>
18+
<GradleScriptDebugEnabled>true</GradleScriptDebugEnabled>
19+
<method v="2" />
20+
</configuration>
21+
</component>

build.gradle

Lines changed: 47 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,17 @@ buildscript {
1313
}
1414
dependencies {
1515
classpath "io.github.gradle-nexus:publish-plugin:1.0.0"
16+
classpath group: 'org.openjfx', name: 'javafx-plugin', version: '0.0.14'
1617
}
1718
}
1819

20+
1921
plugins {
2022
id 'idea'
2123
id 'eclipse'
2224
id 'java'
2325
id 'distribution'
26+
id 'org.openjfx.javafxplugin' version '0.0.14'
2427
}
2528

2629
String buildProfile = project.getProperties().getOrDefault('buildProfile', 'opensource')
@@ -63,14 +66,10 @@ else {
6366
String docbookNameVersion = 'docbook-xsl-1.79.1'
6467
String fopNameVersion = 'fop-1.1'
6568

66-
java {
67-
sourceCompatibility = 'VERSION_1_8'
68-
targetCompatibility = 'VERSION_1_8'
69-
}
70-
71-
7269
// In this section you declare where to find the dependencies of your project
7370
repositories {
71+
mavenCentral()
72+
flatDir { dirs "libz" } //Put Cameo no-install and plugin zips here
7473
ivy {
7574
url "https://sourceforge.net/projects/docbook/files/docbook-xsl/"
7675
patternLayout {
@@ -91,7 +90,6 @@ repositories {
9190

9291
//url 'https://mirror.nodesdirect.com/apache/xmlgraphics/fop/binaries/' for newer version
9392
}
94-
mavenCentral()
9593
maven {
9694
url 'https://repo.gradle.org/gradle/libs-releases-local/'
9795
}
@@ -135,6 +133,7 @@ if (profiles['repositories'] != null) {
135133

136134
configurations {
137135
preImplementation
136+
distribution
138137
testPublish
139138
}
140139

@@ -152,7 +151,7 @@ dependencies {
152151
implementation group: 'org.jsoup', name: 'jsoup', version: '1.6.1'
153152
// implementation group: 'org.jsoup', name: 'jsoup', version: '1.9.1+'
154153

155-
// JGraphT
154+
// JGraphT
156155
implementation group: 'net.sf.jgrapht', name: 'jgrapht', version: '0.8.3'
157156
// implementation group: 'org.jgrapht', name: 'jgrapht', version: '1.0.0+'
158157

@@ -168,8 +167,8 @@ dependencies {
168167
implementation group: 'net.sf.opencsv', name: 'opencsv', version: '2.3'
169168
// implementation group: 'com.opencsv', name: 'opencsv', version: '3.8+'
170169

171-
// ActiveMQ
172-
implementation group: 'org.apache.activemq', name: 'activemq-all', version: '5.9.1'
170+
// ActiveMQ
171+
//implementation group: 'org.apache.activemq', name: 'activemq-all', version: '5.9.1'
173172
// implementation group: 'org.apache.activemq', name: 'activemq-all', version: '5.14.0+'
174173

175174
// Jackson
@@ -187,10 +186,10 @@ dependencies {
187186
implementation group: 'org.apache.httpcomponents', name: 'httpmime', version: '4.5.2'
188187

189188
// Apache Commons CLI
190-
implementation group: 'commons-cli', name: 'commons-cli', version: '1.2'
189+
implementation group: 'commons-cli', name: 'commons-cli', version: '1.4'
191190

192191
//OpenMBEE MMS Java Client
193-
implementation group: 'org.openmbee.mms', name: 'mms-java-client', version: '3.4.2'
192+
//implementation group: 'org.openmbee.mms', name: 'mms-java-client', version: '3.4.2'
194193

195194
implementation group: 'com.beust', name: 'jcommander', version: '1.72'
196195

@@ -216,14 +215,19 @@ dependencies {
216215
}
217216
}
218217
else {
219-
preImplementation group: 'com.nomagic', name: 'demomagicdraw', version: '190sp3', classifier: 'MagicDraw_Demo_190_sp3_no_install', ext: 'zip'
220-
preImplementation group: 'com.nomagic', name: 'sysml', version: '190sp3', classifier: 'SysML_Plugin_190_sp3_bundle', ext: 'zip'
221-
preImplementation group: 'com.nomagic', name: 'cst', version: '190sp3', classifier: 'Cameo_Simulation_Toolkit_Plugin_190_sp3', ext: 'zip'
218+
preImplementation group: 'com.nomagic', name: 'democsm', version: '2022xRefresh1', classifier: 'Cameo_Systems_Modeler_2022x_Refresh1_HF1_no_install', ext: 'zip'
219+
// preCompile group: 'com.nomagic', name: 'sysml', version: '2021x', classifier: 'SysML_Plugin_2021x', ext: 'zip'
220+
// preCompile group: 'com.nomagic', name: 'cst', version: '2021x', classifier: 'Cameo_Simulation_Toolkit_Plugin_2021x', ext: 'zip'
222221
}
223222

224223
preImplementation group: 'org.apache.fop', name: 'fop', version: '1.1', classifier: fopNameVersion + '-bin', ext: 'zip'
225224
preImplementation group: 'net.sourceforge.docbook', name: 'docbook-xsl', version: '1.79.1', classifier: docbookNameVersion, ext: 'zip'
226225

226+
// JavaFX
227+
//preImplementation group: 'org.openjfx', name: 'javafx-fxml', version: '11.0.2'
228+
//preImplementation group: 'org.openjfx', name: 'javafx-controls', version: '11.0.2'
229+
//preImplementation group: 'org.openjfx', name: 'javafx-swing', version: '11.0.2'
230+
227231
// This ensures classpath load order to match the MagicDraw provided order and then includes extras needed for non-OpenAPI stuff.
228232
// This was necessary because of the Application class stubbing that was done in the chromium libraries.
229233
implementation files(classpathLibraries.collect { 'build/dependency-cache/extracted/magicdraw/' + it })
@@ -236,9 +240,19 @@ dependencies {
236240
implementation files(it)
237241
}
238242
}
243+
else {
244+
implementation files('build/dependency-cache/extracted/fop/jars/fop-1.1.jar', 'build/dependency-cache/extracted/fop/jars/xmlgraphics-commons-1.5.jar')
245+
}
239246

240247
}
241248

249+
javafx {
250+
version = "11.0.2"
251+
modules = [ 'javafx.controls', 'javafx.fxml', 'javafx.swing' ]
252+
platform = 'win'
253+
configurations = ['preImplementation']
254+
}
255+
242256
task extractDependencies {
243257
configurations.preImplementation.resolvedConfiguration.resolvedArtifacts.each { artifact ->
244258
inputs.file artifact.file
@@ -278,6 +292,12 @@ task extractDependencies {
278292
into 'build/dependency-cache/extracted/docbook'
279293
}
280294
}
295+
else if (archive.getName().startsWith('javafx')) {
296+
copy {
297+
from archive.getAbsoluteFile()
298+
into 'build/dependency-cache/extracted/javafx'
299+
}
300+
}
281301
else {
282302
copy {
283303
from zipTree(archive)
@@ -316,7 +336,7 @@ task testsJar(type: Jar, dependsOn: testClasses) {
316336
archiveClassifier = 'tests'
317337
from sourceSets.test.output
318338

319-
exclude 'gov/nasa/jpl/mbee/mdk/test/framework/**'
339+
exclude 'org/openmbee/mdk/test/framework/**'
320340
exclude 'org/**'
321341
exclude 'worker/**'
322342
//include 'gov/nasa/jpl/mbee/mdk/test/tests/**'
@@ -326,14 +346,14 @@ task testsHackJar(type: Jar, dependsOn: testClasses) {
326346
archiveClassifier = 'tests-hack'
327347
from sourceSets.test.output
328348

329-
include 'gov/nasa/jpl/mbee/mdk/test/framework/**'
349+
include 'org/openmbee/mdk/test/framework/**'
330350
include 'org/**'
331351
include 'worker/**'
332352
//exclude 'gov/nasa/jpl/mbee/mdk/test/tests/**'
333353

334354
manifest {
335355
attributes(
336-
'Main-Class': 'gov.nasa.jpl.mbee.mdk.test.framework.GradleMagicDrawLauncher'
356+
'Main-Class': 'org.openmbee.mdk.test.framework.GradleMagicDrawLauncher'
337357
)
338358
}
339359
}
@@ -382,6 +402,10 @@ abstract class PreDist extends DefaultTask {
382402
from project.jar
383403
into "${outputDir}/plugins/${groupName}"
384404
}
405+
project.copy {
406+
from "${extractedCache}/javafx"
407+
into "${outputDir}/plugins/${groupName}/javafx"
408+
}
385409
project.copy {
386410
from project.getTasks().getByName('javadocZip')
387411
into "${outputDir}/plugins/${groupName}/javadoc"
@@ -491,7 +515,6 @@ distZip {
491515
eachFile { file ->
492516
file.setPath(path.substring(path.indexOf("/") + 1, path.length()))
493517
}
494-
495518
}
496519

497520
distZip.dependsOn preDist
@@ -593,8 +616,8 @@ task runJava(type: JavaExec) {
593616
if (profiles["executablePath"] != null) {
594617
executable = profiles["executablePath"]
595618
}
596-
main = 'com.nomagic.osgi.launcher.ProductionFrameworkLauncher'
597-
jvmArgs = ['-Xmx8192M', '-Xss512M', '-DLOCALCONFIG=true', '-DWINCONFIG=true', '-Djsse.enableSNIExtension=true', '-Djava.net.preferIPv4Stack=true', '-Dcom.sun.media.imageio.disableCodecLib=true', '-noverify', '-Dlocal.config.dir.ext=-dev', '-splash:data/splash.png', '-Dmd.class.path=$java.class.path', '-Dcom.nomagic.osgi.config.dir=configuration', '-Desi.system.config=data/application.conf', '-Dlogback.configurationFile=data/logback.xml', '-Dsun.locale.formatasdefault=true', '-Dorg.osgi.framework.bundle.parent=ext']
619+
main = 'com.nomagic.magicdraw.Main'
620+
jvmArgs = ['--module-path', 'plugins/org.openmbee.mdk/javafx', '--add-modules', 'javafx.controls,javafx.swing,javafx.fxml', '-Xmx8192M', '-Xss512M', '-DLOCALCONFIG=true', '-DWINCONFIG=true', '-Djsse.enableSNIExtension=true', '-Djava.net.preferIPv4Stack=true', '-Dcom.sun.media.imageio.disableCodecLib=true', '-noverify', '-Dlocal.config.dir.ext=-dev', '-splash:data/splash.png', '-Dmd.class.path=$java.class.path', '-Desi.system.config=data/application.conf', '-Dlogback.configurationFile=data/logback.xml', '-Dsun.locale.formatasdefault=true', '-Djdk.attach.allowAttachSelf=true']
598621
// arguments to pass to the application
599622
args 'DEVELOPER'
600623
}
@@ -611,8 +634,8 @@ task testAVG(type: JavaExec) {
611634
standardOutput = System.out
612635
errorOutput = System.err
613636

614-
main = 'com.nomagic.osgi.launcher.ProductionFrameworkLauncher'
615-
jvmArgs = ['-Xmx8192M', '-Xss512M', '-DLOCALCONFIG=true', '-DWINCONFIG=true', '-Djsse.enableSNIExtension=true', '-Djava.net.preferIPv4Stack=true', '-Dcom.sun.media.imageio.disableCodecLib=true', '-noverify', '-Dlocal.config.dir.ext=-dev', '-splash:data/splash.png', '-Dmd.class.path=$java.class.path', '-Dcom.nomagic.osgi.config.dir=configuration', '-Desi.system.config=data/application.conf', '-Dlogback.configurationFile=data/logback.xml', '-Dsun.locale.formatasdefault=true', '-Dorg.osgi.framework.bundle.parent=ext', '-Dcom.nomagic.magicdraw.launcher=com.nomagic.magicdraw.commandline.CommandLineActionLauncher', '-Dcom.nomagic.magicdraw.commandline.action=gov.nasa.jpl.mbee.pma.cli.AutomatedViewGenerator']
637+
main = 'com.nomagic.magicdraw.Main'
638+
jvmArgs = ['-Xmx8192M', '-Xss512M', '-DLOCALCONFIG=true', '-DWINCONFIG=true', '-Djsse.enableSNIExtension=true', '-Djava.net.preferIPv4Stack=true', '-Dcom.sun.media.imageio.disableCodecLib=true', '-noverify', '-Dlocal.config.dir.ext=-dev', '-splash:data/splash.png', '-Dmd.class.path=$java.class.path', '-Desi.system.config=data/application.conf', '-Dlogback.configurationFile=data/logback.xml', '-Dsun.locale.formatasdefault=true', '-Dcom.nomagic.magicdraw.launcher=com.nomagic.magicdraw.commandline.CommandLineActionLauncher', '-Dcom.nomagic.magicdraw.commandline.action=org.openmbee.pma.cli.AutomatedViewGenerator']
616639
}
617640

618641
testAVG.dependsOn installDist
@@ -665,6 +688,7 @@ test {
665688
* Example command: .../java -Dcom.nomagic.osgi.config.dir=configuration -Desi.system.config=data/application.conf -Djava.security.manager=worker.org.gradle.process.internal.worker.child.BootstrapSecurityManager -Dlogback.configurationFile=data/logback.xml -Dmd.class.path=$java.class.path -jar /Users/igomes/mdk/build/libs/mdk-*-tests-hack.jar -cp ... -Dfile.encoding=UTF-8 -Duser.country=US -Duser.language=en -Duser.variant -ea -cp .../.gradle/caches/.../workerMain/gradle-worker.jar worker.org.gradle.process.internal.worker.GradleWorkerMain 'Gradle Test Executor 1'
666689
*
667690
* @author igomes
691+
* TODO 2021x refresh 1 removed osgi
668692
*/
669693
classpath = files()
670694
doFirst {

0 commit comments

Comments
 (0)