diff options
author | GuangrongFu <fu.guangrong@zte.com.cn> | 2018-08-24 14:05:41 +0800 |
---|---|---|
committer | GuangrongFu <fu.guangrong@zte.com.cn> | 2018-08-24 14:05:41 +0800 |
commit | 6a237c08f158ccbfdf13b44cbb62b3bcd2b97d2a (patch) | |
tree | 65e3648ea9ad57eb881cec05c6505eb428e46f9c /rules/ccvnp-rule.drl | |
parent | 78f3a322be51b30674968ad241a00d566e1fc179 (diff) |
Added Service Instance ID to the CL Event
Change-Id: Ibed23ac96483f97e0b93384716925806bf672d5b
Issue-ID: HOLMES-162
Signed-off-by: GuangrongFu <fu.guangrong@zte.com.cn>
Diffstat (limited to 'rules/ccvnp-rule.drl')
-rw-r--r-- | rules/ccvnp-rule.drl | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/rules/ccvnp-rule.drl b/rules/ccvnp-rule.drl index e1bfc8a..9de2491 100644 --- a/rules/ccvnp-rule.drl +++ b/rules/ccvnp-rule.drl @@ -72,14 +72,18 @@ function Map<String, Object> getAdditionalResourceInfo(String networkId, String Map<String, Object> ret = new HashMap<String, Object>(); - StringBuilder sb = new StringBuilder(); + StringBuilder sbn = new StringBuilder(); + StringBuilder sbi = new StringBuilder(); for(int i = 0; i < instances.size(); ++i) { JSONObject o = instances.getJSONObject(i); String name = o.getString("service-instance-name"); + String id = o.getString("service-instance-id"); ret.put(name + ".input-parameters", o.getString("input-parameters")); - sb.append(name).append(","); + sbn.append(name).append(","); + sbi.append(id).append(","); } - ret.put("service-instance.service-instance-name", sb.substring(0, sb.length() -1).toString()); + ret.put("service-instance.service-instance-name", sbn.substring(0, sbn.length() -1).toString()); + ret.put("service-instance.service-instance-id", sbi.substring(0, sbi.length() -1).toString()); ret.put("vserver.vserver-name", "TBD"); ret.put("globalSubscriberId", instances.getJSONObject(0).getString("globalSubscriberId")); ret.put("serviceType", instances.getJSONObject(0).getString("serviceType")); |