summaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorSaryu Shah <ss3917@att.com>2017-11-09 02:13:25 +0000
committerSaryu Shah <ss3917@att.com>2017-11-09 17:31:43 +0000
commit1dbf351b7b2b047f4478b538b8e0811489aed0ae (patch)
tree01c2536a1af24efe12dca9bebfb8bf99849b955b /docs
parent0a9a9ba8afe11d0566b092c22f22918cdcb876ab (diff)
Documentation - Feature: Test Transaction
Documentation - Feature: Test Transaction and release note update --------------------------------------------------------------- Change-Id: I100e15411e5366d40e32fc3c682724413b9409b4 Issue-Id: POLICY-439 Signed-off-by: Saryu Shah <ss3917@att.com>
Diffstat (limited to 'docs')
-rw-r--r--docs/platform/feature_testtransaction.rst106
-rw-r--r--docs/platform/index.rst2
-rw-r--r--docs/release-notes.rst61
3 files changed, 116 insertions, 53 deletions
diff --git a/docs/platform/feature_testtransaction.rst b/docs/platform/feature_testtransaction.rst
new file mode 100644
index 000000000..488ee1a50
--- /dev/null
+++ b/docs/platform/feature_testtransaction.rst
@@ -0,0 +1,106 @@
+
+.. This work is licensed under a Creative Commons Attribution 4.0 International License.
+.. http://creativecommons.org/licenses/by/4.0
+
+*************************
+Feature: Test Transaction
+*************************
+
+.. contents::
+ :depth: 3
+
+Summary
+^^^^^^^
+
+The Test Transaction feature provides a mechanism by which the health of drools policy controllers can be tested.
+
+When enabled, the feature functions by injecting an event object (identified by a UUID) into the drools session of each policy controller that is active in the system. Only an object with this UUID can trigger the Test Transaction-specific drools logic to execute.
+
+The injection of the event triggers the "TT" rule (see *TestTransactionTemplate.drl* below) to fire. The "TT" rule simply increments a ForwardProgress counter object, thereby confirming that the drools session for this particular controller is active and firing its rules accordingly. This cycle repeats at 20 second intervals.
+
+If it is ever the case that a drools controller does not have the "TT" rule present in its *.drl*, or that the forward progress counter is not incremented, the Test Transaction thread for that particular drools session (i.e. controller) is terminated and a message is logged to *error.log*.
+
+Usage
+^^^^^
+
+Prior to being enabled, the following drools rules need to be appended to the rules templates of any use-case that is to be monitored by the feature.
+
+ .. code-block:: java
+ :caption: TestTransactionTemplate.drl
+ :linenos:
+
+ /*
+ * ============LICENSE_START=======================================================
+ * feature-test-transaction
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+ package org.onap.policy.drools.rules;
+
+ import java.util.EventObject;
+
+ declare ForwardProgress
+ counter : Long
+ end
+
+ rule "TT.SETUP"
+ when
+ then
+ ForwardProgress fp = new ForwardProgress();
+ fp.setCounter(0L);
+ insert(fp);
+ end
+
+ rule "TT"
+ when
+ $fp : ForwardProgress()
+ $tt : EventObject(source == "43868e59-d1f3-43c2-bd6f-86f89a61eea5")
+ then
+ $fp.setCounter($fp.getCounter() + 1);
+ retract($tt);
+ end
+ query "TT.FPC"
+ ForwardProgress(counter >= 0, $ttc : counter)
+ end
+
+Once the proper artifacts are built and deployed with the addition of the TestTransactionTemplate rules, the feature can then be enabled by entering the following commands:
+
+ .. code-block:: bash
+ :caption: PDPD Features Command
+
+ policy@hyperion-4:/opt/app/policy$ policy stop
+ [drools-pdp-controllers]
+ L []: Stopping Policy Management... Policy Management (pid=354) is stopping... Policy Management has stopped.
+ policy@hyperion-4:/opt/app/policy$ features enable test-transaction
+ name version status
+ ---- ------- ------
+ controlloop-utils 1.1.0-SNAPSHOT disabled
+ healthcheck 1.1.0-SNAPSHOT disabled
+ test-transaction 1.1.0-SNAPSHOT enabled
+ eelf 1.1.0-SNAPSHOT disabled
+ state-management 1.1.0-SNAPSHOT disabled
+ active-standby-management 1.1.0-SNAPSHOT disabled
+ session-persistence 1.1.0-SNAPSHOT disabled
+
+The output of the enable command will indicate whether or not the feature was enabled successfully.
+
+Policy engine can then be started as usual.
+
+
+End of Document
+
+.. SSNote: Wiki page ref. https://wiki.onap.org/display/DW/Feature+Test+Transaction
diff --git a/docs/platform/index.rst b/docs/platform/index.rst
index fcdfcaca4..740ce5939 100644
--- a/docs/platform/index.rst
+++ b/docs/platform/index.rst
@@ -15,4 +15,6 @@ Policy Engine Platform
guardpdp.rst
tutorial_vDNS.rst
tutorial_VOLTE.rst
+ feature_testtransaction.rst
+
diff --git a/docs/release-notes.rst b/docs/release-notes.rst
index 7c3c1ee88..8b15232c6 100644
--- a/docs/release-notes.rst
+++ b/docs/release-notes.rst
@@ -3,9 +3,6 @@
Policy Release Notes
====================
-.. contents::
- :depth: 3
-
.. note
.. * This Release Notes must be updated each time the team decides to Release new artifacts.
.. * The scope of these Release Notes are for ONAP POLICY. In other words, each ONAP component has its Release Notes.
@@ -20,12 +17,9 @@ Version: 1.2.0
:Release Date: 2017-11-16 (Amsterdam Release)
-New Features
-^^^^^^^^^^^^
-
-The Amsterdam release continued evolving the design driven architecture of and functionality for POLICY. The following is a list of Epics and Stories delivered with the release.
+**New Features**
- **Epic List**
+The Amsterdam release continued evolving the design driven architecture of and functionality for POLICY. The following is a list of Epics delivered with the release. For a full list of stories and tasks delivered in the Amsterdam release, refer to `JiraPolicyReleaseNotes`_.
* [POLICY-31] - Stabilization of Seed Code
* [POLICY-33] - This epic covers the body of work involved in deploying the Policy Platform components
@@ -38,57 +32,18 @@ The Amsterdam release continued evolving the design driven architecture of and f
* [POLICY-76] - This epic covers the body of work involved in supporting R1 Amsterdam Milestone Release Planning Milestone Tasks.
- **Story List**
-
- * [POLICY-25] - Replace any remaining openecomp reference by onap
- * [POLICY-32] - JUnit test code coverage
- * [POLICY-40] - MSB Integration
- * [POLICY-41] - OOM Integration
- * [POLICY-43] - Amsterdam Use Case Template
- * [POLICY-48] - CLAMP Configuration and Operation Policies for vCPE Use Case
- * [POLICY-51] - Runtime Policy Update Support
- * [POLICY-57] - VF-C Actor code development
- * [POLICY-59] - vCPE Use Case - Runtime
- * [POLICY-60] - VOLTE Use Case - Runtime
- * [POLICY-61] - vFW Use Case - Runtime
- * [POLICY-62] - vDNS Use Case - Runtime
- * [POLICY-63] - CLAMP Configuration and Operation Policies for VOLTE Use Case
- * [POLICY-64] - CLAMP Configuration and Operation Policies for vFW Use Case
- * [POLICY-65] - CLAMP Configuration and Operation Policies for vDNS Use Case
- * [POLICY-66] - PDP-D Feature mechanism enhancements
- * [POLICY-67] - Rainy Day Decision Policy
- * [POLICY-68] - TOSCA Parsing for nested objects for Microservice Policies
- * [POLICY-77] - Functional Test case definition for Control Loops
- * [POLICY-93] - Notification API
- * [POLICY-119] - PDP-D: noop sinks
- * [POLICY-121] - Update POM to inherit from oparent
- * [POLICY-124] - Integration with oparent
- * [POLICY-158] - policy/engine: SQL injection Mitigation
- * [POLICY-161] - Security Event Logging
- * [POLICY-173] - Deployment of Operational Policies Documentation
- * [POLICY-210] - Independent Versioning and Release Process
- * [POLICY-316] - vCPE Use Case - Runtime Testing
- * [POLICY-320] - VOLTE Use Case - Runtime Testing
- * [POLICY-324] - vFW Use Case - Runtime Testing
- * [POLICY-328] - vDNS Use Case - Runtime Testing
- * [POLICY-387] - Deliver the released policy artifacts
-
-Bug Fixes
-^^^^^^^^^
- - This is technically the first release of POLICY, previous release was the seed code contribution. As such, the defects fixed in this release were raised during the course of the release. Anything not closed is captured below under Known Issues. For a list of defects fixed in the Amsterdam release, refer to `PolicyReleaseNotes`_.
+**Bug Fixes**
+ - This is technically the first release of POLICY, previous release was the seed code contribution. As such, the defects fixed in this release were raised during the course of the release. Anything not closed is captured below under Known Issues. For a list of defects fixed in the Amsterdam release, refer to `JiraPolicyReleaseNotes`_.
-.. _PolicyReleaseNotes: https://jira.onap.org/secure/ReleaseNote.jspa?projectId=10106&version=10300
+.. _JiraPolicyReleaseNotes: https://jira.onap.org/secure/ReleaseNote.jspa?projectId=10106&version=10300
-Known Issues
-^^^^^^^^^^^^
+**Known Issues**
- None at this time
-Security Issues
-^^^^^^^^^^^^^^^
+**Security Issues**
- None at this time
-Other
-^^^^^
+**Other**
- None at this time
End of Release Notes