Skip to content

cures-hub/cures-condec-eclipse

Repository files navigation

cures-condec-eclipse

Continuous integration Codacy Badge Codecoverage GitHub contributors

The ConDec Eclipse plug-in enables the user to capture and explore decision knowledge in Eclipse. Decision knowledge covers knowledge about decisions, the problems they address, solution proposals, their context, and justifications (rationale). The user explores linked knowledge elements for code, such as requirements, work items, decision knowledge elements, and commits. The knowledge elements are extracted from the Jira and git projects associated to the Eclipse project. Trace links between code files and Jira issues are created via the Jira issue identifier in commit messages. The user (i.e. a software developer) captures decision knowledge in code comments and commit messages.

User Interface and Usage Description

Configuration

Before you can start using the plug-in, you need to configure the git repository and Jira project associated to your Eclipse project. Select Project -> Properties -> ConDec and add your configuration there.

Project Settings

Project Settings

Knowledge Graph View in Jira

The ConDec Eclipse plug-in enables to quickly navigate from the currently active code file to Jira, where decision knowledge and other knowledge elements are shown in various views on the knowledge graph (e.g. as a tree, graph, and matrix view). Knowledge Graph View in Jira Knowledge Graph View in Jira

To navigate to Jira and to explore linked knowledge elements for a specific code file, select a file in the Project Explorer and open the context menu. There, you find the new entry ConDec with different options for knowledge exploration:

Context Menu on a Code File Context Menu on a Code File

Knowledge Graph View in Eclipse

The knowledge graph consists of knowledge elements (i.e. decision knowledge elements but also other artifacts) and links (i.e. trace links). You can see the entire knowledge graph consisting of code files, commits, decision knowledge elements, and Jira issues (e.g. requirements, work items) for a project. The knowledge graph is interactive: You can create, update, and delete knowledge elements and links. The view provides various filters. However, we recommend to navigate to Jira and use the views there as they are much more advanced (see above).

Entire Knowledge Graph for a Project Entire Knowledge Graph for a Project

Textual Representation of Knowledge Graph in Eclipse

The plug-in offers two views for textual knowledge presentation. Go to Window -> Show View -> Other... and add the views KnowledgeExploration and ChangeImpactAnalysis. Then, select a file in the Project Explorer and open the context menu. There, you find the entry ConDec with the submenu Extract Knowledge.

Textual Knowledge Exploration Textual Knowledge Exploration

Installation

Prerequisites

The following prerequisites are necessary to compile the plug-in from source code:

Compilation via Terminal

The source code can be compiled via terminal. Navigate into the cures-condec-eclipse folder and run the following command:

mvn clean install

The cures-condec-eclipse.jar file is created in the de.uhd.ifi.se.decision.management.eclipse/target subfolder.

Download of Precompiled .jar-File

The precompiled .jar-File for the latest release can be found here: https://github.com/cures-hub/cures-condec-eclipse/releases/latest

Installation in Eclipse

  • Download or compile the cures-condec-eclipse.jar file.
  • Install Eclipse.
  • Navigate to the Eclipse installation folder and copy the cures-condec-eclipse.jar file into the dropins folder (or a similar folder depending on your operation system).
  • Open Eclipse. (Make sure that the eclipse.ini file points to Java 15 JDK.)

Develop in Eclipse

The following subsections are important if you want to contribute as a developer.

Prerequisites

Import the Plug-in

To evolve the ConDec Eclipse plug-in, it needs to be imported into Eclipse.

  • Import the project as an Existing Maven Project.
  • Run mvn clean install in the parent project (cures-condec-eclipse folder) to download the necessary dependendencies into the de.uhd.ifi.se.decision.management.eclipse/lib folder.
  • Configure the de.uhd.ifi.se.decision.management.eclipse project: Properties / Java Build Path / Libraries /
    • Add JARs... / select all jar-files in the lib folder (if not already included).
    • Add Library... / select the Plug-in Dependencies (if not already included).

Setting up Dependencies

The following steps might be necessary to correctly setup Eclipse, in particular, after you added a or updated an existing dependency:

  1. Update the pom.xml in the main/parent folder (add new dependency or update the version of an existing dependency, such as jira-rest-java-client-core from 4.0.0 to 5.2.2). Do not change the nested pom.xml files. (There are four pom.xml files in total.)
  2. Delete the contents of the de.uhd.ifi.se.decision.management.eclipse/lib folder
  3. Run mvn clean package -DskipTests which will refill the lib folder including the new or updated dependencies. (It might fail but the dependencies are copied into de.uhd.ifi.se.decision.management.eclipse/lib, that is fine.)
  4. Update the .classpath of the de.uhd.ifi.se.decision.management.eclipse project. Add all .jar-files in the lib folder and export them so that they can be found by the test project.
  5. Update the MANIFEST.MF and the build.properties using the Eclipse GUI. Navigate to Runtime and add all libraries as Exported Packages and make sure that the Classpath contains all .jar files.
  6. Make sure that the file MANIFEST.MF contains the entry Bundle-ClassPath: .,.

Runtime Tab Runtime Tab

Run as a second Eclipse Application

You can start a second Eclipse instance containing the plug-in from within your initial Eclipse by running the de.uhd.ifi.se.decision.management.eclipse project as an Eclipse Application.