diff options
Diffstat (limited to 'ONAP-PDP-REST')
-rw-r--r-- | ONAP-PDP-REST/pom.xml | 344 | ||||
-rw-r--r-- | ONAP-PDP-REST/src/test/java/org/onap/policy/pdp/rest/jmx/ServerContextImpl.java | 674 |
2 files changed, 529 insertions, 489 deletions
diff --git a/ONAP-PDP-REST/pom.xml b/ONAP-PDP-REST/pom.xml index a301c1952..aa54f1b4b 100644 --- a/ONAP-PDP-REST/pom.xml +++ b/ONAP-PDP-REST/pom.xml @@ -18,181 +18,179 @@ limitations under the License. ============LICENSE_END========================================================= --> -<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> - <modelVersion>4.0.0</modelVersion> - <parent> - <groupId>org.onap.policy.engine</groupId> - <artifactId>PolicyEngineSuite</artifactId> - <version>1.3.0-SNAPSHOT</version> - </parent> - <artifactId>ONAP-PDP-REST</artifactId> - <description>ONAP PDP REST</description> - <properties> - <springframework.version>4.3.15.RELEASE</springframework.version> - </properties> - <packaging>war</packaging> - <build> - <plugins> - <plugin> - <artifactId>maven-war-plugin</artifactId> - <version>2.1</version> - <configuration> - <attachClasses>true</attachClasses> - </configuration> - </plugin> - </plugins> - </build> - <dependencies> - <dependency> - <groupId>com.h2database</groupId> - <artifactId>h2</artifactId> - <scope>test</scope> - </dependency> - <dependency> - <groupId>org.onap.policy.engine</groupId> - <artifactId>ONAP-PDP</artifactId> - <version>${project.version}</version> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.1.3</version> - <exclusions> - <exclusion> - <groupId>javax.servlet</groupId> - <artifactId>servlet-api</artifactId> - </exclusion> - </exclusions> - </dependency> - <dependency> - <groupId>log4j</groupId> - <artifactId>apache-log4j-extras</artifactId> - <version>1.2.17</version> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.4</version> - </dependency> - <dependency> - <groupId>com.google.guava</groupId> - <artifactId>guava</artifactId> - <version>19.0</version> - </dependency> - <dependency> +<project xmlns="http://maven.apache.org/POM/4.0.0" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> + <modelVersion>4.0.0</modelVersion> + <parent> + <groupId>org.onap.policy.engine</groupId> + <artifactId>PolicyEngineSuite</artifactId> + <version>1.3.0-SNAPSHOT</version> + </parent> + <artifactId>ONAP-PDP-REST</artifactId> + <description>ONAP PDP REST</description> + <properties> + <springframework.version>4.3.15.RELEASE</springframework.version> + </properties> + <packaging>war</packaging> + <build> + <plugins> + <plugin> + <artifactId>maven-war-plugin</artifactId> + <configuration> + <attachClasses>true</attachClasses> + </configuration> + </plugin> + </plugins> + </build> + <dependencies> + <dependency> + <groupId>com.h2database</groupId> + <artifactId>h2</artifactId> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.onap.policy.engine</groupId> + <artifactId>ONAP-PDP</artifactId> + <version>${project.version}</version> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.1.3</version> + <exclusions> + <exclusion> + <groupId>javax.servlet</groupId> + <artifactId>servlet-api</artifactId> + </exclusion> + </exclusions> + </dependency> + <dependency> + <groupId>log4j</groupId> + <artifactId>apache-log4j-extras</artifactId> + <version>1.2.17</version> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.4</version> + </dependency> + <dependency> + <groupId>com.google.guava</groupId> + <artifactId>guava</artifactId> + </dependency> + <dependency> <groupId>org.mariadb.jdbc</groupId> <artifactId>mariadb-java-client</artifactId> <version>2.1.1</version> </dependency> - <dependency> - <groupId>postgresql</groupId> - <artifactId>postgresql</artifactId> - <version>9.1-901.jdbc4</version> - </dependency> - <dependency> - <groupId>org.springframework</groupId> - <artifactId>spring-test</artifactId> - <version>${springframework.version}</version> - <scope>test</scope> - </dependency> - <dependency> - <groupId>org.awaitility</groupId> - <artifactId>awaitility</artifactId> - <version>3.0.0</version> - <scope>test</scope> - </dependency> - <dependency> - <groupId>org.hsqldb</groupId> - <artifactId>hsqldb</artifactId> - <version>2.3.2</version> - </dependency> - <dependency> - <groupId>com.sun.jersey</groupId> - <artifactId>jersey-client</artifactId> - <version>1.18</version> - </dependency> - <dependency> - <groupId>com.sun.jersey</groupId> - <artifactId>jersey-core</artifactId> - <version>1.18</version> - </dependency> - <dependency> - <groupId>javax.websocket</groupId> - <artifactId>javax.websocket-api</artifactId> - <version>1.1</version> - <scope>provided</scope> - </dependency> - <dependency> - <groupId>com.att.nsa</groupId> - <artifactId>cambriaClient</artifactId> - <version>0.0.1</version> - <exclusions> - <exclusion> - <artifactId>slf4j-log4j12</artifactId> - <groupId>org.slf4j</groupId> - </exclusion> - </exclusions> - </dependency> - <dependency> - <groupId>com.att.aft</groupId> - <artifactId>dme2</artifactId> - <version>3.1.200-oss</version> - <scope>test</scope> - </dependency> - <dependency> - <groupId>org.springframework</groupId> - <artifactId>spring-core</artifactId> - <version>${springframework.version}</version> - </dependency> - <dependency> - <groupId>org.springframework</groupId> - <artifactId>spring-web</artifactId> - <version>${springframework.version}</version> - </dependency> - <dependency> - <groupId>org.springframework</groupId> - <artifactId>spring-webmvc</artifactId> - <version>${springframework.version}</version> - </dependency> - <dependency> - <groupId>io.springfox</groupId> - <artifactId>springfox-swagger2</artifactId> - <version>2.5.0</version> - <exclusions> - <exclusion> - <groupId>com.fasterxml.jackson.core</groupId> - <artifactId>jackson-annotations</artifactId> - </exclusion> - </exclusions> - </dependency> - <dependency> - <groupId>io.springfox</groupId> - <artifactId>springfox-swagger-ui</artifactId> - <version>2.7.0</version> - </dependency> - <dependency> - <groupId>org.onap.policy.engine</groupId> - <artifactId>PolicyEngineAPI</artifactId> - <version>${project.version}</version> - <exclusions> - <exclusion> - <groupId>org.glassfish.tyrus</groupId> - <artifactId>tyrus-client</artifactId> - </exclusion> - <exclusion> - <groupId>org.glassfish.tyrus</groupId> - <artifactId>tyrus-container-grizzly-client</artifactId> - </exclusion> - <exclusion> - <groupId>javax.persistence</groupId> - <artifactId>persistence-api</artifactId> - </exclusion> - <exclusion> - <groupId>com.att.aft</groupId> - <artifactId>dme2</artifactId> - </exclusion> - </exclusions> - </dependency> - </dependencies> + <dependency> + <groupId>postgresql</groupId> + <artifactId>postgresql</artifactId> + <version>9.1-901.jdbc4</version> + </dependency> + <dependency> + <groupId>org.springframework</groupId> + <artifactId>spring-test</artifactId> + <version>${springframework.version}</version> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.awaitility</groupId> + <artifactId>awaitility</artifactId> + <version>3.0.0</version> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.hsqldb</groupId> + <artifactId>hsqldb</artifactId> + <version>2.3.2</version> + </dependency> + <dependency> + <groupId>com.sun.jersey</groupId> + <artifactId>jersey-client</artifactId> + <version>1.18</version> + </dependency> + <dependency> + <groupId>com.sun.jersey</groupId> + <artifactId>jersey-core</artifactId> + <version>1.18</version> + </dependency> + <dependency> + <groupId>javax.websocket</groupId> + <artifactId>javax.websocket-api</artifactId> + <version>1.1</version> + <scope>provided</scope> + </dependency> + <dependency> + <groupId>com.att.nsa</groupId> + <artifactId>cambriaClient</artifactId> + <exclusions> + <exclusion> + <artifactId>slf4j-log4j12</artifactId> + <groupId>org.slf4j</groupId> + </exclusion> + </exclusions> + </dependency> + <dependency> + <groupId>com.att.aft</groupId> + <artifactId>dme2</artifactId> + <version>3.1.200-oss</version> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.springframework</groupId> + <artifactId>spring-core</artifactId> + <version>${springframework.version}</version> + </dependency> + <dependency> + <groupId>org.springframework</groupId> + <artifactId>spring-web</artifactId> + <version>${springframework.version}</version> + </dependency> + <dependency> + <groupId>org.springframework</groupId> + <artifactId>spring-webmvc</artifactId> + <version>${springframework.version}</version> + </dependency> + <dependency> + <groupId>io.springfox</groupId> + <artifactId>springfox-swagger2</artifactId> + <version>2.5.0</version> + <exclusions> + <exclusion> + <groupId>com.fasterxml.jackson.core</groupId> + <artifactId>jackson-annotations</artifactId> + </exclusion> + </exclusions> + </dependency> + <dependency> + <groupId>io.springfox</groupId> + <artifactId>springfox-swagger-ui</artifactId> + <version>2.7.0</version> + </dependency> + <dependency> + <groupId>org.onap.policy.engine</groupId> + <artifactId>PolicyEngineAPI</artifactId> + <version>${project.version}</version> + <exclusions> + <exclusion> + <groupId>org.glassfish.tyrus</groupId> + <artifactId>tyrus-client</artifactId> + </exclusion> + <exclusion> + <groupId>org.glassfish.tyrus</groupId> + <artifactId>tyrus-container-grizzly-client</artifactId> + </exclusion> + <exclusion> + <groupId>javax.persistence</groupId> + <artifactId>persistence-api</artifactId> + </exclusion> + <exclusion> + <groupId>com.att.aft</groupId> + <artifactId>dme2</artifactId> + </exclusion> + </exclusions> + </dependency> + </dependencies> </project> diff --git a/ONAP-PDP-REST/src/test/java/org/onap/policy/pdp/rest/jmx/ServerContextImpl.java b/ONAP-PDP-REST/src/test/java/org/onap/policy/pdp/rest/jmx/ServerContextImpl.java index d936fbe85..2f8683c5c 100644 --- a/ONAP-PDP-REST/src/test/java/org/onap/policy/pdp/rest/jmx/ServerContextImpl.java +++ b/ONAP-PDP-REST/src/test/java/org/onap/policy/pdp/rest/jmx/ServerContextImpl.java @@ -7,9 +7,9 @@ * 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. @@ -40,318 +40,360 @@ import javax.servlet.SessionCookieConfig; import javax.servlet.SessionTrackingMode; import javax.servlet.descriptor.JspConfigDescriptor; -public class ServerContextImpl implements ServletContext{ - - @Override - public String getContextPath() { - // TODO Auto-generated method stub - return null; - } - - @Override - public ServletContext getContext(String uripath) { - // TODO Auto-generated method stub - return null; - } - - @Override - public int getMajorVersion() { - // TODO Auto-generated method stub - return 0; - } - - @Override - public int getMinorVersion() { - // TODO Auto-generated method stub - return 0; - } - - @Override - public int getEffectiveMajorVersion() { - // TODO Auto-generated method stub - return 0; - } - - @Override - public int getEffectiveMinorVersion() { - // TODO Auto-generated method stub - return 0; - } - - @Override - public String getMimeType(String file) { - // TODO Auto-generated method stub - return null; - } - - @Override - public Set<String> getResourcePaths(String path) { - // TODO Auto-generated method stub - return null; - } - - @Override - public URL getResource(String path) throws MalformedURLException { - // TODO Auto-generated method stub - return null; - } - - @Override - public InputStream getResourceAsStream(String path) { - // TODO Auto-generated method stub - return null; - } - - @Override - public RequestDispatcher getRequestDispatcher(String path) { - // TODO Auto-generated method stub - return null; - } - - @Override - public RequestDispatcher getNamedDispatcher(String name) { - // TODO Auto-generated method stub - return null; - } - - @Override - public Servlet getServlet(String name) throws ServletException { - // TODO Auto-generated method stub - return null; - } - - @Override - public Enumeration<Servlet> getServlets() { - // TODO Auto-generated method stub - return null; - } - - @Override - public Enumeration<String> getServletNames() { - // TODO Auto-generated method stub - return null; - } - - @Override - public void log(String msg) { - // TODO Auto-generated method stub - - } - - @Override - public void log(Exception exception, String msg) { - // TODO Auto-generated method stub - - } - - @Override - public void log(String message, Throwable throwable) { - // TODO Auto-generated method stub - - } - - @Override - public String getRealPath(String path) { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getServerInfo() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getInitParameter(String name) { - // TODO Auto-generated method stub - return null; - } - - @Override - public Enumeration<String> getInitParameterNames() { - // TODO Auto-generated method stub - return null; - } - - @Override - public boolean setInitParameter(String name, String value) { - // TODO Auto-generated method stub - return false; - } - - @Override - public Object getAttribute(String name) { - // TODO Auto-generated method stub - return null; - } - - @Override - public Enumeration<String> getAttributeNames() { - // TODO Auto-generated method stub - return null; - } - - @Override - public void setAttribute(String name, Object object) { - // TODO Auto-generated method stub - - } - - @Override - public void removeAttribute(String name) { - // TODO Auto-generated method stub - - } - - @Override - public String getServletContextName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public Dynamic addServlet(String servletName, String className) { - // TODO Auto-generated method stub - return null; - } - - @Override - public Dynamic addServlet(String servletName, Servlet servlet) { - // TODO Auto-generated method stub - return null; - } - - @Override - public Dynamic addServlet(String servletName, Class<? extends Servlet> servletClass) { - // TODO Auto-generated method stub - return null; - } - - @Override - public <T extends Servlet> T createServlet(Class<T> clazz) throws ServletException { - // TODO Auto-generated method stub - return null; - } - - @Override - public ServletRegistration getServletRegistration(String servletName) { - // TODO Auto-generated method stub - return null; - } - - @Override - public Map<String, ? extends ServletRegistration> getServletRegistrations() { - // TODO Auto-generated method stub - return null; - } - - @Override - public javax.servlet.FilterRegistration.Dynamic addFilter(String filterName, String className) { - // TODO Auto-generated method stub - return null; - } - - @Override - public javax.servlet.FilterRegistration.Dynamic addFilter(String filterName, Filter filter) { - // TODO Auto-generated method stub - return null; - } - - @Override - public javax.servlet.FilterRegistration.Dynamic addFilter(String filterName, Class<? extends Filter> filterClass) { - // TODO Auto-generated method stub - return null; - } - - @Override - public <T extends Filter> T createFilter(Class<T> clazz) throws ServletException { - // TODO Auto-generated method stub - return null; - } - - @Override - public FilterRegistration getFilterRegistration(String filterName) { - // TODO Auto-generated method stub - return null; - } - - @Override - public Map<String, ? extends FilterRegistration> getFilterRegistrations() { - // TODO Auto-generated method stub - return null; - } - - @Override - public SessionCookieConfig getSessionCookieConfig() { - // TODO Auto-generated method stub - return null; - } - - @Override - public void setSessionTrackingModes(Set<SessionTrackingMode> sessionTrackingModes) { - // TODO Auto-generated method stub - - } - - @Override - public Set<SessionTrackingMode> getDefaultSessionTrackingModes() { - // TODO Auto-generated method stub - return null; - } - - @Override - public Set<SessionTrackingMode> getEffectiveSessionTrackingModes() { - // TODO Auto-generated method stub - return null; - } - - @Override - public void addListener(String className) { - // TODO Auto-generated method stub - - } - - @Override - public <T extends EventListener> void addListener(T t) { - // TODO Auto-generated method stub - - } - - @Override - public void addListener(Class<? extends EventListener> listenerClass) { - // TODO Auto-generated method stub - - } - - @Override - public <T extends EventListener> T createListener(Class<T> clazz) throws ServletException { - // TODO Auto-generated method stub - return null; - } - - @Override - public JspConfigDescriptor getJspConfigDescriptor() { - // TODO Auto-generated method stub - return null; - } - - @Override - public ClassLoader getClassLoader() { - // TODO Auto-generated method stub - return null; - } - - @Override - public void declareRoles(String... roleNames) { - // TODO Auto-generated method stub - - } - - @Override - public String getVirtualServerName() { - // TODO Auto-generated method stub - return null; - } - +public class ServerContextImpl implements ServletContext { + + @Override + public String getContextPath() { + // TODO Auto-generated method stub + return null; + } + + @Override + public ServletContext getContext(String uripath) { + // TODO Auto-generated method stub + return null; + } + + @Override + public int getMajorVersion() { + // TODO Auto-generated method stub + return 0; + } + + @Override + public int getMinorVersion() { + // TODO Auto-generated method stub + return 0; + } + + @Override + public int getEffectiveMajorVersion() { + // TODO Auto-generated method stub + return 0; + } + + @Override + public int getEffectiveMinorVersion() { + // TODO Auto-generated method stub + return 0; + } + + @Override + public String getMimeType(String file) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Set<String> getResourcePaths(String path) { + // TODO Auto-generated method stub + return null; + } + + @Override + public URL getResource(String path) throws MalformedURLException { + // TODO Auto-generated method stub + return null; + } + + @Override + public InputStream getResourceAsStream(String path) { + // TODO Auto-generated method stub + return null; + } + + @Override + public RequestDispatcher getRequestDispatcher(String path) { + // TODO Auto-generated method stub + return null; + } + + @Override + public RequestDispatcher getNamedDispatcher(String name) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Servlet getServlet(String name) throws ServletException { + // TODO Auto-generated method stub + return null; + } + + @Override + public Enumeration<Servlet> getServlets() { + // TODO Auto-generated method stub + return null; + } + + @Override + public Enumeration<String> getServletNames() { + // TODO Auto-generated method stub + return null; + } + + @Override + public void log(String msg) { + // TODO Auto-generated method stub + + } + + @Override + public void log(Exception exception, String msg) { + // TODO Auto-generated method stub + + } + + @Override + public void log(String message, Throwable throwable) { + // TODO Auto-generated method stub + + } + + @Override + public String getRealPath(String path) { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getServerInfo() { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getInitParameter(String name) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Enumeration<String> getInitParameterNames() { + // TODO Auto-generated method stub + return null; + } + + @Override + public boolean setInitParameter(String name, String value) { + // TODO Auto-generated method stub + return false; + } + + @Override + public Object getAttribute(String name) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Enumeration<String> getAttributeNames() { + // TODO Auto-generated method stub + return null; + } + + @Override + public void setAttribute(String name, Object object) { + // TODO Auto-generated method stub + + } + + @Override + public void removeAttribute(String name) { + // TODO Auto-generated method stub + + } + + @Override + public String getServletContextName() { + // TODO Auto-generated method stub + return null; + } + + @Override + public Dynamic addServlet(String servletName, String className) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Dynamic addServlet(String servletName, Servlet servlet) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Dynamic addServlet(String servletName, Class<? extends Servlet> servletClass) { + // TODO Auto-generated method stub + return null; + } + + @Override + public <T extends Servlet> T createServlet(Class<T> clazz) throws ServletException { + // TODO Auto-generated method stub + return null; + } + + @Override + public ServletRegistration getServletRegistration(String servletName) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Map<String, ? extends ServletRegistration> getServletRegistrations() { + // TODO Auto-generated method stub + return null; + } + + @Override + public javax.servlet.FilterRegistration.Dynamic addFilter(String filterName, String className) { + // TODO Auto-generated method stub + return null; + } + + @Override + public javax.servlet.FilterRegistration.Dynamic addFilter(String filterName, Filter filter) { + // TODO Auto-generated method stub + return null; + } + + @Override + public javax.servlet.FilterRegistration.Dynamic addFilter( + String filterName, Class<? extends Filter> filterClass) { + // TODO Auto-generated method stub + return null; + } + + @Override + public <T extends Filter> T createFilter(Class<T> clazz) throws ServletException { + // TODO Auto-generated method stub + return null; + } + + @Override + public FilterRegistration getFilterRegistration(String filterName) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Map<String, ? extends FilterRegistration> getFilterRegistrations() { + // TODO Auto-generated method stub + return null; + } + + @Override + public SessionCookieConfig getSessionCookieConfig() { + // TODO Auto-generated method stub + return null; + } + + @Override + public void setSessionTrackingModes(Set<SessionTrackingMode> sessionTrackingModes) { + // TODO Auto-generated method stub + + } + + @Override + public Set<SessionTrackingMode> getDefaultSessionTrackingModes() { + // TODO Auto-generated method stub + return null; + } + + @Override + public Set<SessionTrackingMode> getEffectiveSessionTrackingModes() { + // TODO Auto-generated method stub + return null; + } + + @Override + public void addListener(String className) { + // TODO Auto-generated method stub + + } + + @Override + public <T extends EventListener> void addListener(T t) { + // TODO Auto-generated method stub + + } + + @Override + public void addListener(Class<? extends EventListener> listenerClass) { + // TODO Auto-generated method stub + + } + + @Override + public <T extends EventListener> T createListener(Class<T> clazz) throws ServletException { + // TODO Auto-generated method stub + return null; + } + + @Override + public JspConfigDescriptor getJspConfigDescriptor() { + // TODO Auto-generated method stub + return null; + } + + @Override + public ClassLoader getClassLoader() { + // TODO Auto-generated method stub + return null; + } + + @Override + public void declareRoles(String... roleNames) { + // TODO Auto-generated method stub + + } + + @Override + public String getVirtualServerName() { + // TODO Auto-generated method stub + return null; + } + + @Override + public Dynamic addJspFile(String arg0, String arg1) { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getRequestCharacterEncoding() { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getResponseCharacterEncoding() { + // TODO Auto-generated method stub + return null; + } + + @Override + public int getSessionTimeout() { + // TODO Auto-generated method stub + return 0; + } + + @Override + public void setRequestCharacterEncoding(String arg0) { + // TODO Auto-generated method stub + + } + + @Override + public void setResponseCharacterEncoding(String arg0) { + // TODO Auto-generated method stub + + } + + @Override + public void setSessionTimeout(int arg0) { + // TODO Auto-generated method stub + + } } |