ECSEL Research and Innovation actions (RIA) AMASS Architecture-driven, Multi-concern and Seamless Assurance and Certification of Cyber-Physical Systems AMASS Platform – Prototype P1 Developers Guide Work Package: WP2: Reference Architecture and Integration Dissemination level: CO = Confidential, only for members of the consortium Status: Draft Date: November 06, 2017 Responsible partner: A. López (TECNALIA) Contact information: [email protected]Document reference: AMASS_PrototypeP1_DeveloperGuide_V1.0 PROPRIETARY RIGHTS STATEMENT This document contains information that is proprietary to the AMASS Consortium. Neither this document nor the information contained herein shall be used, duplicated or communicated by any means to any third party, in whole or in parts, except with prior written consent of the AMASS consortium.
42
Embed
ECSEL Research and Innovation actions (RIA) · Developers Guide: AMASS Platform - Prototype P1 H2020-JTI-ECSEL-2015 # 692474 Page 4 of 42 Executive Summary This document is a developer
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
ECSEL Research and Innovation actions (RIA)
AMASS Architecture-driven, Multi-concern and Seamless Assurance and
Certification of Cyber-Physical Systems
AMASS Platform – Prototype P1 Developers Guide
Work Package: WP2: Reference Architecture and Integration
Dissemination level: CO = Confidential, only for members of the consortium
PROPRIETARY RIGHTS STATEMENT This document contains information that is proprietary to the AMASS Consortium. Neither this document nor the information contained herein shall be used, duplicated or communicated by any means to any third party, in whole or in parts, except with prior written consent of the AMASS consortium.
2 Installation of PostgreSQL database for OpenCert .......................................................................... 7 2.1 Installation of PostgreSQL database on Windows machine .................................................... 7 2.2 Restoring OPENCERT database in PostgreSQL ......................................................................... 9
This document is a developer guide of the AMASS tool implementation. In this document, the developers can find the source code installing instructions, step by step, in order to set up their workspaces to improve and implement new functionalities to the OpenCert; CHESS, Papyrus, EPF client parts. This document has been elaborated as a Fast Developer Guide. Further questions must be directed to the AMASS implementation team.
OpenCert code uses the following naming convention for its plugins:
org.eclipse.opencert.[module].[plugin-name] where [module] can be one of the following modules: arg: argumentation editors chess: chess features related to assurance … ..
1.2.2 CHESS
CHESS code uses the following naming convention for its plugins: org.polarsys.CHESS.[module].[plugin-name]
where [module] can be one of the following modules:
• contracts: support for contract-based design and analysis
• fla: support for failure logic analysis
• sba: support for state based analysis APIs with visibility limited to the owning plugin should be stored in a package named as “xxx.internal.yyy” (e.g. org.polarsys.chess.service.internal.utils); an internal package should not be exported to external client (it should not appear in the runtime tab of the plugin.xml editor).
1.2.3 EPF Composer
EPF code uses the following naming convention for its plugins: org.eclipse.epf.[module].[plugin-name] where [module] can be one of the following modules: library: provides the UI and services to manage a method library Export/Import: provides the UI and services to export and import method plug-ins and configurations packaged in XMI files …
BVR code uses the following naming convention for its plugins: no.sintef.bvr.[module].[plugin-name] where [module] can be one of the following modules: constraints: provides support for constraint-based resolution. The logical operators such as implication, alternative, negation might be used. …
1.2.5 V&V Manager
V&V Manager code uses the following name for its plugin: eu.hon.eclipse.vavmanager
2 Installation of PostgreSQL database for OpenCert
OPENCERT platform tools use PostgreSQL database and the first step is to install it. For user convenience, PostgreSQL installation on Windows has been described in this chapter.
2.1 Installation of PostgreSQL database on Windows machine
1. Download PostgreSQL installer
a. Go to the download section for Windows
http://www.postgresql.org/download/windows/
b. Click on download installer from EnterpriseDB
c. Choose the 9.3.15 or 9.4.10 version and download it
2. Double click the installer file and follow the installation wizard.
3. Most important steps during the installation process are (among others):
a. Definition of a password for the database super-user (his login is “postgres”).
b. Definition of a port for PostgreSQL - the default 5432 is recommended.
c. If the installation wizard asks you to launch Stack Builder to install additional tools,
you may skip this step - no additional tools are needed.
d. The installation may take a few minutes to complete.
4. Verify the database installation
a. The quick way to verify the installation is to use pgAdmin application which has
been installed together with PostgreSQL server.
Please run “pgAdmin III”. The following GUI is displayed:
a. \WP-transversal\ImplementationTeam\PrototypeCore\Vaditation_Data\OpenCert\OpenCert1.backup Only has ISO 26262 Standard modelled and some assurance projects created in the SafeAdapt project which can be used as examples
5. In Restore Option #1 tab check “Don’t save” owner and “Privilege” and click Restore
6. Check the process ends with the message “Process returned exit code 0” and click done.
It is required to have installed (minimum) Java Environment 1.8. To install the full OPENCERT tool environment, follow the next steps:
1. Download Eclipse Neon 3 from https://www.eclipse.org/downloads/download.php?file=/technology/epp/downloads/release/neon/3/eclipse-modeling-neon-3-win32-x86_64.zip
3.1 Papyrus
1. Install Papyrus features from menu Help->Install Modelling components (if this should not work, try installing Papyrus from the Neon update site ‘http://download.eclipse.org/releases/neon’ from ‘Help-Install new software’ wizard, by having the ‘Contact all update sites during install to find required software’ feature enabled; Papyrus can be found under the Modeling category)
2. Restart Eclipse 3. Install MARTE and CDO Model Repository from menu Help->Install Papyrus Additional
1. Install XText SDK 2.12. It can be installed from the following Eclipse update site http://download.eclipse.org/modeling/tmf/xtext/updates/composite/releases/. To see the version 2.12 remember to uncheck the box “Show only the latest versions of available software”. Note that this will require to remove the EMF Parsley plugins.
2. Install Operational QVT, Acceleo, ATL features from menu Help->Install Modelling components
3. The plugins1 that provide the graphical representation of fault trees, require Sirius. To install Sirius go to the following update site (from Eclipse Help->Install new software):
http://download.eclipse.org/sirius/updates/releases/4.0.0/neon (select the Sirius Category)
4. CHESS plugins depend on a set of Eclipse plugins provided as external libraries but not implemented in the project. They can be installed from the following Eclipse update site http://es-static.fbk.eu/tools/devel_sde. Do not install Xtext Redistributable because is needed only to final users and not developers. The available plugins are: • eu.fbk.tools.editor.*: plugins provided by FBK that enrich a text area with content assist
for an LTL grammar. • eu.fbk.tools.adapter.*: plugins provided by FBK that enable the interaction with V&VTools
CHESS plugins, and related libraries, can be installed in the given Eclipse environment through update sites, or their source version can be imported in the current workspace; the latter option has to be preferred in case of CHESS plugins development. Otherwise, to avoid having too much plugins in the workspace, the first option can be adopted.
3.2.2.1 Install CHESS plugins via update site
To install CHESS plugins on the current Eclipse environment: 1. Install CHESS plugins from
3.2.2.2 Import CHESS plugins in the current workspace
CHESS plugins are currently available at the Polarsys GIT server: https://git.polarsys.org/c/chess/chess.git To import the CHESS plugins in the workspace the CHESS git repository has to be cloned first:
1. Install Git client for Eclipse (if the Git Team Provider feature selected in the figure below is not available, then it means that it is alredy available in the current environment,so you can skip this step)
9. Select all the plugins. IMPORTANT: org.polarsys.chess.instance.view will not compile due to some missing eclipse features that cannot be installed in the AMASS eclipse environment. Just do not care of this, you can close/remove this project in the workspace. Moreover, errors in the chess.fla plugins shown in the picture below are not an issue.
10. Go to “Window - Preferences - Plug-in Development - API baselines - Missing API baselines” and
The system requirements for running the EPF Composer are as follows:
• Microsoft Windows XP SP3, 2003 SP2 (or later), Windows 7, Windows 10
• Red Hat Enterprise Linux Release 4 Update 5, Release 5 or later, (note: compat-libstdc++ is needed
for RHEL5) SUSE Enterprise Linux v9 or v10
• Internet Explorer, Mozilla, or Firefox
• Java Runtime Environment 1.5, 1.6, 1.7, 1.8
For the development environment setup, the required software might be downloaded from the Neon software repository. Please locate the following URL as an update site (Help menu > Install new software) Neon - http://download.eclipse.org/releases/neon. After that, select the SDKs mentioned in below figure and complete the installation.
2. To apply installation changes and restart Eclipse click on the 'Yes' button.
3. After Eclipse restart You need to open the SVN perspective. Once you open this perspective you'll
see connectors discovery dialog which will allow you to install Subversive Connectors without registering connectors update site manually. Install the subversive Connector
5. Change the perspective to “Plugin Development” to see all the plugins in your workspace. Your workspace will have all the source code but with errors, now you have to install various eclipse Frameworks to solve them:
6. Install CDO from http://download.eclipse.org/modeling/emf/cdo/drops/R20160607-1209/ with the option selected in the screenshot below:
If the updatesite is down, try downloading from https://www.svnkit.com/org.tmatesoft.svn_1.3.8.eclipse.zip and using the downloaded local archive to install it. NOW all the should work. If not, please contacte me ([email protected]) for support. UPDATE: org.eclipse.opencert.chess.* depend on CHESS and Capra projects, so CHESS and Capra plugins must be available to be able to properly build the aforementioned org.eclipse.opencert.chess.* plugins. See following section about how to install Capra.
3.6 Capra
3.6.1 Required Features
• Install CDT for eclipse Neon: http://download.eclipse.org/tools/cdt/releases/9.2
1. Clone git repo available at https://github.com/SaschaBaumgart/TraceabilityManagement 2. Import all the available plugins
3.7 V&V Manager
The V&V Manager plugin works with the Eclipse NEON. It is required to have installed (minimum) Java Environment 1.8. The plugin depends on the following packages: javax.xml.xpath org.eclipse.core.commands org.eclipse.core.runtime org.eclipse.emf.common.command org.eclipse.emf.common.util org.eclipse.emf.ecore org.eclipse.emf.transaction.util org.eclipse.gmf.runtime.common.core.command org.eclipse.jface.dialogs org.eclipse.jface.resource org.eclipse.jface.text org.eclipse.papyrus.infra.emf.gmf.command org.eclipse.papyrus.infra.services.validation.commands org.eclipse.papyrus.infra.services.validation.handler org.eclipse.papyrus.infra.services.validation org.eclipse.swt.custom org.eclipse.swt.graphics org.eclipse.swt org.eclipse.swt.widgets org.eclipse.ui.part org.eclipse.ui org.eclipse.ui.plugin org.eclipse.uml2.uml org.eclipse.uml2.uml.internal.impl org.osgi.framework org.polarsys.chess.contracts.profile.chesscontract org.polarsys.chess.contracts.profile.chesscontract.impl
The procedure to create a bundle is the following: 1. Store in the same workspace all the code that will be included in the bundle. All the code must
compile with no errors. 2. Create a feature per tool: one for OpenCert, one for CHESS plus Papyrus, one for EPF … 3. Create a local updatesite including all the features 4. Download the eclipse platform version for Neon 5. In the new eclipse platform, add the sites for sites for downloading epsilon, ecoretools, svnkits and
cdo (but do not install anything yet) 6. Add the new updatesite created in step 3 and install it (it should find the dependencies) 7. Do not restart it, just close it. 8. We should substitute the customized dawn plugins. To do that we should copy in the
configuration folder from the eclipse platform, the “model” folder and the “epsilon” folder which are located in the assuranceproject.wizard plugin
9. Change the splash for the eclipse platform with the AMASS splash 10. Include –clean parameter when starting the eclipse.
1. Set more memory for running the code in option Run>Run Configurations
2. Run the CDO server from the code, for that, right click over the org.eclipse.opencert.storage.cdo > src > StandaloneCDOServer.java class an select Run As > Java Application option.
3. Check the Console messages to control the CDO server start process. If you get and error terminate the execution and modify the opencoss-properties.xml content according to your installation.
Configure properly the generated file in for windows user directory. <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd"> <properties>
<entry key="dbHost">localhost</entry> PostgreSQL host name or IP
<entry key="dbPort">5432</entry> PostgreSQL Port
<entry key="dbName">cdo_amass</entry> PostgreSQL database name <entry key="dbUser">postgres</entry> PostgreSQL database user name
<entry key="dbPassword">postgres</entry> PostgreSQL database user password
<entry key="serverAddress">localhost:2036</entry> CDO Server Host and Port </properties>
4. Right click over any plugin and select Debug As > Eclipse Application. The Target platform will be
loaded with all the code deployed.
5. Open the Repository Explorer view to see the CDO server contents and open models double