Skip to content

Commit 22dbd05

Browse files
add new documentation page
add new documentation page with section for mapping existing rules to example events and resulting aggregations.
1 parent e2c3ddb commit 22dbd05

File tree

6 files changed

+16
-4
lines changed

6 files changed

+16
-4
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,10 @@ Visit [Eiffel Community](https://eiffel-community.github.io) to get started and
4646
1. [**Understanding rules**](wiki/markdown/rules.md)
4747
- [**Introduction**](wiki/markdown/rules.md#Introduction)
4848
- [**Rule set up**](wiki/markdown/rules.md#Rule-set-up)
49-
- [**Existing rules files**](wiki/markdown/existing-rules-files.md)
5049
- [**MergeResolverRules**](wiki/markdown/merge-resolver-rules.md)
5150
- [**History Rules**](wiki/markdown/history-rules.md)
51+
- [**Existing rules files**](wiki/markdown/existing-rules-files.md)
52+
- [**Mapping Rules To Aggregations**](wiki/markdown/mapping-rules-to-aggregations.md)
5253
1. [**Step by Step Aggregation on Eiffel events**](wiki/markdown/step-by-step-aggregation.md)
5354
- [**ArtifactCreatedEvent Aggregation**](wiki/markdown/artifact-created-event-aggregation.md)
5455
- [**TestCaseTriggeredEvent Aggregation**](wiki/markdown/test-case-triggered-event-aggregation.md)

src/integrationtests/resources/features/SourceChangeFlowIT.feature

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
Feature: Source change flow integrationtest
2020
Scenario: Send eiffel events for source change flow and make sure EI is triggering on REST-POST subscriptions
2121
Given the rules "src/test/resources/SourceChangeObjectRules.json"
22-
And the events "src/test/resources/TestSourceChangeObject.json"
22+
And the events "src/test/resources/TestSourceChangeObjectEvents.json"
2323
And the upstream input "src/test/resources/UpstreamEventsForSourceChange.json"
2424
And the resulting aggregated object "src/test/resources/aggregatedSourceChangeObject.json";
2525
And the expected aggregated object ID is "sb6efi4n-25fb-4d77-b9fd-5f2xrrefe66de47"

src/test/java/com/ericsson/ei/flowtests/FlowSourceChangeObject.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,12 @@
4747
import com.fasterxml.jackson.databind.node.ObjectNode;
4848

4949
@RunWith(SpringJUnit4ClassRunner.class)
50-
@TestExecutionListeners(listeners = {DependencyInjectionTestExecutionListener.class, FlowSourceChangeObject.class})
50+
@TestExecutionListeners(listeners = { DependencyInjectionTestExecutionListener.class, FlowSourceChangeObject.class })
5151
@SpringBootTest(classes = App.class)
5252
public class FlowSourceChangeObject extends FlowTestBase {
5353

5454
private static final String RULES_FILE_PATH = "src/test/resources/SourceChangeObjectRules.json";
55-
private static final String EVENTS_FILE_PATH = "src/test/resources/TestSourceChangeObject.json";
55+
private static final String EVENTS_FILE_PATH = "src/test/resources/TestSourceChangeObjectEvents.json";
5656
private static final String AGGREGATED_OBJECT_FILE_PATH = "src/test/resources/aggregatedSourceChangeObject.json";
5757
private static final String AGGREGATED_OBJECT_ID = "sb6efi4n-25fb-4d77-b9fd-5f2xrrefe66de47";
5858
private static final String UPSTREAM_FILE = "UpstreamEventsForMockedSourceChange.json";
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
When writing subscriptions it is important that you know the structure of the aggregated object. In this section we present how example aggregated objects look like in relation to our existing rules.
2+
3+
4+
[**Artifact Rules**](https://github.com/eiffel-community/eiffel-intelligence/blob/master/src/main/resources/ArtifactRules.json) will result in an [**Artifact Object**](https://github.com/eiffel-community/eiffel-intelligence/blob/master/src/test/resources/AggregatedDocumentInternalCompositionLatestIT.json) based on following [**events**](https://github.com/eiffel-community/eiffel-intelligence/blob/master/src/test/resources/ArtifactFlowTestEvents.json) from message bus and following historical [**events**](https://github.com/eiffel-community/eiffel-intelligence/blob/master/src/test/resources/upStreamInput.json) from event repository.
5+
6+
7+
[**Source Change Rules**](https://github.com/eiffel-community/eiffel-intelligence/blob/master/src/main/resources/SourceChangeObjectRules.json) will result in [**Source Change Object**](https://github.com/eiffel-community/eiffel-intelligence/blob/master/src/test/resources/aggregatedSourceChangeObject.json) based on following [**events**](https://github.com/eiffel-community/eiffel-intelligence/blob/master/src/test/resources/TestSourceChangeObjectEvents.json) from message bus.
8+
9+
10+
[**Test Execution Rules**](https://github.com/eiffel-community/eiffel-intelligence/blob/master/src/main/resources/TestExecutionObjectRules.json) will result in [**Test Execution Object**](https://github.com/eiffel-community/eiffel-intelligence/blob/master/src/test/resources/aggregatedTestActivityObject.json) based on following [**events**](https://github.com/eiffel-community/eiffel-intelligence/blob/master/src/test/resources/TestExecutionTestEvents.json) from message bus.

wiki/site.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@
5151
<item name="Merge Resolver Rules" href="merge-resolver-rules.html" />
5252
<item name="History Rules" href="history-rules.html" />
5353
<item name="Existing Rules" href="existing-rules-files.html" />
54+
<item name="Mapping Rules To Aggregations" href="mapping-rules-to-aggregations.html" />
5455
</item>
5556
<item collapse="true" name="Step-by-step aggregation" href="step-by-step-aggregation.html">
5657
<item name="ArtifactCreatedEvent aggregation" href="artifact-created-event-aggregation.html" />

0 commit comments

Comments
 (0)