https://github.com/tarilabs/kjar-cep-archetype
A basic kjar template with CEP, JUnit 4 and Eclipse org.eclipse.m2e lifecycle-mapping plug-in settings
https://github.com/tarilabs/kjar-cep-archetype
Last synced: about 2 months ago
JSON representation
A basic kjar template with CEP, JUnit 4 and Eclipse org.eclipse.m2e lifecycle-mapping plug-in settings
- Host: GitHub
- URL: https://github.com/tarilabs/kjar-cep-archetype
- Owner: tarilabs
- License: apache-2.0
- Created: 2014-09-07T12:37:48.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2014-09-08T20:20:27.000Z (over 10 years ago)
- Last Synced: 2025-02-12T04:16:55.300Z (3 months ago)
- Language: Java
- Size: 133 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
A basic kjar template with CEP, JUnit 4 and Eclipse org.eclipse.m2e lifecycle-mapping plug-in settings.
## Installation
Clone this git project and Eclipse > Import as "Existing Maven project".
Right click on project in workspace, Run As > Maven install.
## Usage
Create new Maven Project in Eclipse, the archetype will be available in the catalog.
## Background
I found myself creating many times a single-use, disposable, simple template project for testing new rules or new concepts in isolation.
However the creation of this kind of project in Eclipse, usually required performing manually the following steps:
* Create new Maven project with archetype quickstart
* Set-up the new project's pom:
* Change Java version to 1.6 or greater, by including the maven-compiler-plugin
* Add Drools dependencies
* Change JUnit dependencies to version 4
* Add kie-maven-plugin
* Add plug-in org.eclipse.m2e/lifecycle-mapping settings, to avoid Eclipse ERROR at the pom.xml line defining the kie-maven-plugin
* Set packaging to 'kjar'
* Creation of an initial .drl file in src/main/resources
* Creation of minimal kmodule.xml in src/main/resources/META-INF directory
* Create a simple JUnit test for:
* Creation of KieBase with STREAM option for CEP features
* Creation of KieSession with pseudo-clock
* Advance / Insert / Fire template
* ... and other verification/output patterns
* Include SLF4J and LOG4J binding for logging, including a log4j.properties file in src/test/resourcesThis archetype automate the above steps.