summaryrefslogtreecommitdiffstats
path: root/openecomp-be/lib/openecomp-sdc-validation-lib
diff options
context:
space:
mode:
authorAbhai Singh <Abhai.Singh@amdocs.com>2017-12-28 19:13:06 +0530
committerVitaly Emporopulo <Vitaliy.Emporopulo@amdocs.com>2017-12-31 10:27:15 +0000
commit1577328de998d9b921e61ac9940a016ac1bbcecd (patch)
tree5e4adea01193e24f486eeddeed94f6e4a3007ac1 /openecomp-be/lib/openecomp-sdc-validation-lib
parent76d9fa786f28e4835c55895824028bc2bb757dfa (diff)
Fix Sonar violations - ValidationTestUtil
Fixed few reported sonar issues. One sonar issue related to exception handling is ignored as it would be fixed later Change-Id: I316868b2f6634e8858696e87604e73de7c8d5e40 Issue-ID: SDC-343 Signed-off-by: Abhai Singh <Abhai.Singh@amdocs.com>
Diffstat (limited to 'openecomp-be/lib/openecomp-sdc-validation-lib')
-rw-r--r--openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src/main/java/org/openecomp/sdc/validation/util/ValidationTestUtil.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src/main/java/org/openecomp/sdc/validation/util/ValidationTestUtil.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src/main/java/org/openecomp/sdc/validation/util/ValidationTestUtil.java
index 08a3548a7d..068e147874 100644
--- a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src/main/java/org/openecomp/sdc/validation/util/ValidationTestUtil.java
+++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src/main/java/org/openecomp/sdc/validation/util/ValidationTestUtil.java
@@ -26,7 +26,6 @@ import org.testng.Assert;
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
-import java.io.StringWriter;
import java.net.URL;
import java.util.Collection;
import java.util.HashMap;
@@ -38,9 +37,11 @@ import java.util.Objects;
*/
public class ValidationTestUtil {
- private final static Logger log = (Logger) LoggerFactory.getLogger(ValidationTestUtil.class
+ private static final Logger LOG = LoggerFactory.getLogger(ValidationTestUtil.class
.getName());
+ private ValidationTestUtil(){}
+
public static GlobalValidationContext createGlobalContextFromPath(String path) {
GlobalValidationContext globalValidationContext = new GlobalValidationContext();
Map<String, byte[]> contentMap = getContentMapByPath(path);
@@ -181,7 +182,7 @@ public class ValidationTestUtil {
CommonMethods.newInstance(validatorConf.getImplementationClass(), Validator.class);
validator.init(validatorConf.getProperties());
} catch (IllegalArgumentException iae) {
- log.debug("",iae);
+ LOG.debug("",iae);
return null;
}
return validator;
@@ -189,7 +190,6 @@ public class ValidationTestUtil {
public static Map<String, Object> getResourceMap(String configFileName) throws IOException {
URL mockResource = ValidationTestUtil.class.getResource(configFileName);
- StringWriter writer = new StringWriter();
String json = IOUtils.toString(mockResource.openStream(), "UTF-8");
return JsonUtil.json2Object(json, Map.class);
}
k */ .highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */ .highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */ .highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */ .highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */ .highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */ .highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */ .highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */ .highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */ }
# sdnc web image


## folder structure

| folder | description |
| ------ | ----------- |
| /opt/bitnami/nginx/conf/server_blocks/http(s)_site.conf | nginx config |
| /opt/bitnami/nginx/conf/server_blocks/location.rules | forwarding rules for nginx |
| /app/odlux | http content files (html, js, css, ...) |
| /app/odlux.application.list | application list file |
| /app/opm.py | Odlux package manager for install or uninstall apps |
| /app/init.d/ | autoinstall folder for opm |

## Default app order

| index | application |
| ----- | ----------- |
| 1 | connectApp |
| 10 | faultApp |
| 20 | maintenanceApp |
| 30 | configurationApp |
| 55 | performanceHistoryApp |
| 70 | inventoryApp |
| 75 | eventLogApp |
| 90 | mediatorApp |
| 200 | helpApp |


## usage

### auto installation

To auto install additional applications for odlux they can be easily injected before startup into the ```/app/init.d/``` folder. There are two options of file format allowed.

[1] The first fileformat is e.g. 55linkCalculationApp.jar but also .zip is allowed. The important thing is that a number is leading the app package to specify the order number where the menu item is ordered in the menu bar. So the linkCalculationApp would be located between performanceApp and inventoryApp.

[2] The second is the default jar format, like it would be installed into the opendaylight karaf environment, including a blueprint and the sources. There the filename is not important because application name and index will be detected by the blueprint information.


### manual method
```
opm install --name myApp --index 53 --file myarchive.zip
```
```
opm install --url https://link-to-my-odlux-application.jar
```

```
opm uninstall --name myApp
```

```
opm list
```