summaryrefslogtreecommitdiffstats
path: root/dcae-policy/README.md
diff options
context:
space:
mode:
authorAlex Shatov <alexs@att.com>2018-03-27 17:12:31 -0400
committerAlex Shatov <alexs@att.com>2018-03-27 17:12:31 -0400
commit768c68b6fa25ab2faa9f7dbffdae2cbb2bd6e218 (patch)
treecef25ca671633f9e4e2d6b784cd5ad8b1970d0dd /dcae-policy/README.md
parent342c2890e9b46b483244773b2337c8f56ae9bd0d (diff)
2.2.1 dcaepolicyplugin and data types
- trying to avoid changing code for k8s deployment of policy-handler with unknown url to MSB or policy-handler at the moment - expecting optional manual population of the consul-kv with config data for dcaepolicyplugin - when not found service for policy-handler in consul -- try finding config for "dcaepolicyplugin" in consul-kv -- the config structure is expected to contain url to policy_handler - example of config value for key=dcaepolicyplugin: { "dcaepolicyplugin" : { "policy_handler" : { "url" : "http://policy-handler:25577" } } } - still drop down to hardcoded default when this config not found in consul-kv - added and refactored unit tests for discovery -- coverage 78% - making code more PEP8 compliant Change-Id: Ia176b54ed62631baa30d614785d1937023408ddf Signed-off-by: Alex Shatov <alexs@att.com> Issue-ID: DCAEGEN2-419
Diffstat (limited to 'dcae-policy/README.md')
-rw-r--r--dcae-policy/README.md21
1 files changed, 20 insertions, 1 deletions
diff --git a/dcae-policy/README.md b/dcae-policy/README.md
index 042a550..2b06519 100644
--- a/dcae-policy/README.md
+++ b/dcae-policy/README.md
@@ -8,6 +8,25 @@
- node type for dcae.nodes.policy
+- node type for dcae.nodes.policies
+
+---
+
+## discovery of policy-handler
+
+- dcaepolicyplugin will first try finding the record of ```policy_handler``` in consul services.
+
+- if failed, it will try finding config for "dcaepolicyplugin" in consul-kv
+
+ -- the config structure is expected to contain url to policy_handler
+ -- example of config value for key=```dcaepolicyplugin```:
+
+```json
+{ "dcaepolicyplugin" : { "policy_handler" : { "url" : "http://policy-handler:25577" } } }
+```
+
+- if still not found, it will default to hardcoded url of ```http://policy-handler```
+
---
## Usage
@@ -16,7 +35,7 @@ import the dcaepolicy-node-type.yaml into your blueprint to use the dcae.nodes.t
```yaml
imports:
- - https://YOUR_NEXUS_RAW_SERVER/type_files/dcaepolicy/2.1.0/node-type.yaml
+ - https://YOUR_NEXUS_RAW_SERVER/type_files/dcaepolicy/2.2.1/node-type.yaml
```
provide the value for policy_id property