You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stratos.apache.org by ud...@apache.org on 2014/12/22 10:08:20 UTC
[3/4] stratos git commit: rename metadata serice to metadata/api
rename metadata serice to metadata/api
Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/74de671c
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/74de671c
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/74de671c
Branch: refs/heads/master
Commit: 74de671ccc4c32acc4381920b5ad46d59ce75db8
Parents: 46b5402
Author: Udara Liyanage <ud...@wso2.com>
Authored: Fri Dec 19 19:06:13 2014 +0530
Committer: Udara Liyanage <ud...@wso2.com>
Committed: Mon Dec 22 14:37:54 2014 +0530
----------------------------------------------------------------------
.../org.apache.stratos.metadataservice/pom.xml | 9 +--
.../META-INF/webapp-classloading.xml | 35 +++++++++
.../metadata-test/WEB-INF/cxf-servlet.xml | 46 +++++++++++
.../main/webapp/metadata-test/WEB-INF/web.xml | 40 ++++++++++
.../metadata/META-INF/webapp-classloading.xml | 35 +++++++++
.../webapp/metadata/WEB-INF/cxf-servlet.xml | 81 ++++++++++++++++++++
.../src/main/webapp/metadata/WEB-INF/web.xml | 39 ++++++++++
.../META-INF/webapp-classloading.xml | 35 ---------
.../WEB-INF/cxf-servlet.xml | 46 -----------
.../stratosmetadataservice-test/WEB-INF/web.xml | 40 ----------
.../META-INF/webapp-classloading.xml | 35 ---------
.../WEB-INF/cxf-servlet.xml | 81 --------------------
.../stratosmetadataservice/WEB-INF/web.xml | 39 ----------
13 files changed, 279 insertions(+), 282 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/pom.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/pom.xml b/components/org.apache.stratos.metadataservice/pom.xml
index 37eb828..281c702 100644
--- a/components/org.apache.stratos.metadataservice/pom.xml
+++ b/components/org.apache.stratos.metadataservice/pom.xml
@@ -38,7 +38,7 @@
</property>
</activation>
<properties>
- <appName>stratosmetadataservice-test</appName>
+ <appName>metadata-test</appName>
</properties>
</profile>
<profile>
@@ -47,7 +47,7 @@
<activeByDefault>true</activeByDefault>
</activation>
<properties>
- <appName>stratosmetadataservice</appName>
+ <appName>metadata</appName>
</properties>
</profile>
</profiles>
@@ -73,10 +73,7 @@
<directory>src/main/webapp/${appName}</directory>
</resource>
</webResources>
- <warName>metadataapi</warName>
-
-
-
+ <warName>metadata</warName>
</configuration>
</plugin>
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/META-INF/webapp-classloading.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/META-INF/webapp-classloading.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/META-INF/webapp-classloading.xml
new file mode 100644
index 0000000..c62912d
--- /dev/null
+++ b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/META-INF/webapp-classloading.xml
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+ # Licensed to the Apache Software Foundation (ASF) under one
+ # or more contributor license agreements. See the NOTICE file
+ # distributed with this work for additional information
+ # regarding copyright ownership. The ASF licenses this file
+ # to you 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.
+ -->
+
+<!--
+ This file defines class loading policy of the whole container. But this behaviour can be overridden by individual webapps by putting this file into the META-INF/ directory.
+-->
+<Classloading xmlns="http://wso2.org/projects/as/classloading">
+
+ <!-- Parent-first or child-first. Default behaviour is child-first.-->
+ <ParentFirst>false</ParentFirst>
+
+ <!--
+ Default environments that contains provides to all the webapps. This can be overridden by individual webapps by specifing required environments
+ Tomcat environment is the default and every webapps gets it even if they didn't specify it.
+ e.g. If a webapps requires CXF, they will get both Tomcat and CXF.
+ -->
+ <Environments>CXF,Carbon</Environments>
+</Classloading>
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/WEB-INF/cxf-servlet.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/WEB-INF/cxf-servlet.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/WEB-INF/cxf-servlet.xml
new file mode 100644
index 0000000..f8b8750
--- /dev/null
+++ b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/WEB-INF/cxf-servlet.xml
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ # Licensed to the Apache Software Foundation (ASF) under one
+ # or more contributor license agreements. See the NOTICE file
+ # distributed with this work for additional information
+ # regarding copyright ownership. The ASF licenses this file
+ # to you 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.
+ -->
+
+<beans xmlns="http://www.springframework.org/schema/beans"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:jaxrs="http://cxf.apache.org/jaxrs"
+ xsi:schemaLocation="
+ http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
+ http://cxf.apache.org/jaxrs http://cxf.apache.org/schemas/jaxrs.xsd">
+
+ <jaxrs:server id="stratosAdmin" address="/">
+ <jaxrs:serviceBeans>
+ <ref bean="stratosRestEndpointTestBean"/>
+ </jaxrs:serviceBeans>
+
+ <jaxrs:providers>
+ <ref bean="throwableExceptionHandler"/>
+ <bean class="org.apache.cxf.jaxrs.provider.json.JSONProvider">
+ <property name="dropRootElement" value="true"/>
+ <property name="supportUnwrapped" value="true"/>
+ </bean>>
+ <ref bean="exceptionHandler"/>
+ </jaxrs:providers>
+ </jaxrs:server>
+
+ <bean id="stratosRestEndpointTestBean" class="org.apache.stratos.rest.endpoint.mock.StratosTestAdmin"/>
+ <bean id="exceptionHandler" class="org.apache.stratos.rest.endpoint.handlers.CustomExceptionMapper"/>
+ <bean id="throwableExceptionHandler" class="org.apache.stratos.rest.endpoint.handlers.CustomThrowableExceptionMapper"/>
+</beans>
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/WEB-INF/web.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/WEB-INF/web.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/WEB-INF/web.xml
new file mode 100644
index 0000000..4a752f6
--- /dev/null
+++ b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata-test/WEB-INF/web.xml
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ # Licensed to the Apache Software Foundation (ASF) under one
+ # or more contributor license agreements. See the NOTICE file
+ # distributed with this work for additional information
+ # regarding copyright ownership. The ASF licenses this file
+ # to you 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.
+ -->
+
+<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+ http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
+
+ <display-name>S2 Meta Data Admin Endpoint</display-name>
+
+ <servlet>
+ <servlet-name>StratosAdminEndpoint</servlet-name>
+ <servlet-class>org.apache.cxf.transport.servlet.CXFServlet</servlet-class>
+ <load-on-startup>1</load-on-startup>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>StratosAdminEndpoint</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+
+</web-app>
+
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/META-INF/webapp-classloading.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/META-INF/webapp-classloading.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/META-INF/webapp-classloading.xml
new file mode 100644
index 0000000..c62912d
--- /dev/null
+++ b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/META-INF/webapp-classloading.xml
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+ # Licensed to the Apache Software Foundation (ASF) under one
+ # or more contributor license agreements. See the NOTICE file
+ # distributed with this work for additional information
+ # regarding copyright ownership. The ASF licenses this file
+ # to you 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.
+ -->
+
+<!--
+ This file defines class loading policy of the whole container. But this behaviour can be overridden by individual webapps by putting this file into the META-INF/ directory.
+-->
+<Classloading xmlns="http://wso2.org/projects/as/classloading">
+
+ <!-- Parent-first or child-first. Default behaviour is child-first.-->
+ <ParentFirst>false</ParentFirst>
+
+ <!--
+ Default environments that contains provides to all the webapps. This can be overridden by individual webapps by specifing required environments
+ Tomcat environment is the default and every webapps gets it even if they didn't specify it.
+ e.g. If a webapps requires CXF, they will get both Tomcat and CXF.
+ -->
+ <Environments>CXF,Carbon</Environments>
+</Classloading>
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/WEB-INF/cxf-servlet.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/WEB-INF/cxf-servlet.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/WEB-INF/cxf-servlet.xml
new file mode 100644
index 0000000..3d001bf
--- /dev/null
+++ b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/WEB-INF/cxf-servlet.xml
@@ -0,0 +1,81 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ # Licensed to the Apache Software Foundation (ASF) under one
+ # or more contributor license agreements. See the NOTICE file
+ # distributed with this work for additional information
+ # regarding copyright ownership. The ASF licenses this file
+ # to you 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.
+ -->
+
+<beans xmlns="http://www.springframework.org/schema/beans"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:jaxrs="http://cxf.apache.org/jaxrs"
+ xsi:schemaLocation="
+ http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
+ http://cxf.apache.org/jaxrs http://cxf.apache.org/schemas/jaxrs.xsd">
+
+ <jaxrs:server id="stratosMetaDataAdmin" address="/api">
+ <jaxrs:serviceBeans>
+ <ref bean="stratosRestEndpointBean"/>
+ </jaxrs:serviceBeans>
+
+ <jaxrs:providers>
+ <ref bean="throwableExceptionHandler"/>
+ <ref bean="genericExceptionHandler"/>
+ <ref bean="jsonProvider"/>
+ <ref bean="exceptionHandler"/>
+ <ref bean="OAuthFilter"/>
+ <ref bean="basicAuthenticationFilter"/>
+ <ref bean="sessionAuthenticationFilter"/>
+ <!--<ref bean="authorizationFilter"/>-->
+ </jaxrs:providers>
+ </jaxrs:server>
+
+ <bean id="stratosRestEndpointBean" class="org.apache.stratos.metadataservice.services.MetaDataAdmin"/>
+ <bean id="basicAuthenticationFilter" class="org.apache.stratos.metadataservice.handlers.StratosAuthenticationHandler"/>
+ <bean id="sessionAuthenticationFilter" class="org.apache.stratos.metadataservice.handlers.CookieBasedAuthenticationHandler"/>
+ <bean id="authorizationFilter" class="org.apache.stratos.metadataservice.handlers.StratosAuthorizingHandler">
+ <property name="securedObject" ref="stratosRestEndpointBean"/>
+ </bean>
+ <bean id="exceptionHandler" class="org.apache.stratos.metadataservice.handlers.CustomExceptionMapper"/>
+ <bean id="genericExceptionHandler" class="org.apache.stratos.metadataservice.handlers.GenericExceptionMapper"/>
+ <bean id="throwableExceptionHandler" class="org.apache.stratos.metadataservice.handlers.CustomThrowableExceptionMapper"/>
+ <!--The below config enables OAuth based authentication/authorization for REST API-->
+ <bean id="OAuthFilter" class="org.apache.stratos.metadataservice.handlers.OAuthHandler">
+ <property name="password" value="admin"/>
+ <property name="username" value="admin"/>
+ <property name="oauthValidationEndpoint" value="https://localhost:9443/services/"/>
+ </bean>
+ <bean id="jsonProvider" class="org.apache.cxf.jaxrs.provider.json.JSONProvider">
+ <property name="supportUnwrapped" value="true"/>
+ <property name="serializeAsArray" value="true"/>
+ <property name="dropRootElement" value="true" />
+ <property name="arrayKeys">
+ <list>
+ <value>partitions</value>
+ <value>property</value>
+ <value>hostNames</value>
+ <value>memberMap</value>
+ <value>portMap</value>
+ <value>partitionGroup</value>
+ <value>partition</value>
+ <value>member</value>
+ <value>hostNames</value>
+ <value>portMappings</value>
+ <value>volumes</value>
+ </list>
+ </property>
+ </bean>
+
+</beans>
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/WEB-INF/web.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/WEB-INF/web.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/WEB-INF/web.xml
new file mode 100644
index 0000000..a46ee34
--- /dev/null
+++ b/components/org.apache.stratos.metadataservice/src/main/webapp/metadata/WEB-INF/web.xml
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ # Licensed to the Apache Software Foundation (ASF) under one
+ # or more contributor license agreements. See the NOTICE file
+ # distributed with this work for additional information
+ # regarding copyright ownership. The ASF licenses this file
+ # to you 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.
+ -->
+
+<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+ http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
+
+ <display-name>S2 Admin Endpoint</display-name>
+ <servlet>
+ <servlet-name>StratosAdminEndpoint</servlet-name>
+ <servlet-class>org.apache.cxf.transport.servlet.CXFServlet</servlet-class>
+ <load-on-startup>1</load-on-startup>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>StratosAdminEndpoint</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+
+</web-app>
+
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/META-INF/webapp-classloading.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/META-INF/webapp-classloading.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/META-INF/webapp-classloading.xml
deleted file mode 100644
index c62912d..0000000
--- a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/META-INF/webapp-classloading.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
-<!--
- # Licensed to the Apache Software Foundation (ASF) under one
- # or more contributor license agreements. See the NOTICE file
- # distributed with this work for additional information
- # regarding copyright ownership. The ASF licenses this file
- # to you 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.
- -->
-
-<!--
- This file defines class loading policy of the whole container. But this behaviour can be overridden by individual webapps by putting this file into the META-INF/ directory.
--->
-<Classloading xmlns="http://wso2.org/projects/as/classloading">
-
- <!-- Parent-first or child-first. Default behaviour is child-first.-->
- <ParentFirst>false</ParentFirst>
-
- <!--
- Default environments that contains provides to all the webapps. This can be overridden by individual webapps by specifing required environments
- Tomcat environment is the default and every webapps gets it even if they didn't specify it.
- e.g. If a webapps requires CXF, they will get both Tomcat and CXF.
- -->
- <Environments>CXF,Carbon</Environments>
-</Classloading>
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/WEB-INF/cxf-servlet.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/WEB-INF/cxf-servlet.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/WEB-INF/cxf-servlet.xml
deleted file mode 100644
index f8b8750..0000000
--- a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/WEB-INF/cxf-servlet.xml
+++ /dev/null
@@ -1,46 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- # Licensed to the Apache Software Foundation (ASF) under one
- # or more contributor license agreements. See the NOTICE file
- # distributed with this work for additional information
- # regarding copyright ownership. The ASF licenses this file
- # to you 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.
- -->
-
-<beans xmlns="http://www.springframework.org/schema/beans"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:jaxrs="http://cxf.apache.org/jaxrs"
- xsi:schemaLocation="
- http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
- http://cxf.apache.org/jaxrs http://cxf.apache.org/schemas/jaxrs.xsd">
-
- <jaxrs:server id="stratosAdmin" address="/">
- <jaxrs:serviceBeans>
- <ref bean="stratosRestEndpointTestBean"/>
- </jaxrs:serviceBeans>
-
- <jaxrs:providers>
- <ref bean="throwableExceptionHandler"/>
- <bean class="org.apache.cxf.jaxrs.provider.json.JSONProvider">
- <property name="dropRootElement" value="true"/>
- <property name="supportUnwrapped" value="true"/>
- </bean>>
- <ref bean="exceptionHandler"/>
- </jaxrs:providers>
- </jaxrs:server>
-
- <bean id="stratosRestEndpointTestBean" class="org.apache.stratos.rest.endpoint.mock.StratosTestAdmin"/>
- <bean id="exceptionHandler" class="org.apache.stratos.rest.endpoint.handlers.CustomExceptionMapper"/>
- <bean id="throwableExceptionHandler" class="org.apache.stratos.rest.endpoint.handlers.CustomThrowableExceptionMapper"/>
-</beans>
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/WEB-INF/web.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/WEB-INF/web.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/WEB-INF/web.xml
deleted file mode 100644
index 4a752f6..0000000
--- a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice-test/WEB-INF/web.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- # Licensed to the Apache Software Foundation (ASF) under one
- # or more contributor license agreements. See the NOTICE file
- # distributed with this work for additional information
- # regarding copyright ownership. The ASF licenses this file
- # to you 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.
- -->
-
-<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
- http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
-
- <display-name>S2 Meta Data Admin Endpoint</display-name>
-
- <servlet>
- <servlet-name>StratosAdminEndpoint</servlet-name>
- <servlet-class>org.apache.cxf.transport.servlet.CXFServlet</servlet-class>
- <load-on-startup>1</load-on-startup>
- </servlet>
-
- <servlet-mapping>
- <servlet-name>StratosAdminEndpoint</servlet-name>
- <url-pattern>/*</url-pattern>
- </servlet-mapping>
-
-</web-app>
-
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/META-INF/webapp-classloading.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/META-INF/webapp-classloading.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/META-INF/webapp-classloading.xml
deleted file mode 100644
index c62912d..0000000
--- a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/META-INF/webapp-classloading.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
-<!--
- # Licensed to the Apache Software Foundation (ASF) under one
- # or more contributor license agreements. See the NOTICE file
- # distributed with this work for additional information
- # regarding copyright ownership. The ASF licenses this file
- # to you 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.
- -->
-
-<!--
- This file defines class loading policy of the whole container. But this behaviour can be overridden by individual webapps by putting this file into the META-INF/ directory.
--->
-<Classloading xmlns="http://wso2.org/projects/as/classloading">
-
- <!-- Parent-first or child-first. Default behaviour is child-first.-->
- <ParentFirst>false</ParentFirst>
-
- <!--
- Default environments that contains provides to all the webapps. This can be overridden by individual webapps by specifing required environments
- Tomcat environment is the default and every webapps gets it even if they didn't specify it.
- e.g. If a webapps requires CXF, they will get both Tomcat and CXF.
- -->
- <Environments>CXF,Carbon</Environments>
-</Classloading>
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/WEB-INF/cxf-servlet.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/WEB-INF/cxf-servlet.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/WEB-INF/cxf-servlet.xml
deleted file mode 100644
index 25e97fb..0000000
--- a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/WEB-INF/cxf-servlet.xml
+++ /dev/null
@@ -1,81 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- # Licensed to the Apache Software Foundation (ASF) under one
- # or more contributor license agreements. See the NOTICE file
- # distributed with this work for additional information
- # regarding copyright ownership. The ASF licenses this file
- # to you 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.
- -->
-
-<beans xmlns="http://www.springframework.org/schema/beans"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:jaxrs="http://cxf.apache.org/jaxrs"
- xsi:schemaLocation="
- http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
- http://cxf.apache.org/jaxrs http://cxf.apache.org/schemas/jaxrs.xsd">
-
- <jaxrs:server id="stratosMetaDataAdmin" address="/">
- <jaxrs:serviceBeans>
- <ref bean="stratosRestEndpointBean"/>
- </jaxrs:serviceBeans>
-
- <jaxrs:providers>
- <ref bean="throwableExceptionHandler"/>
- <ref bean="genericExceptionHandler"/>
- <ref bean="jsonProvider"/>
- <ref bean="exceptionHandler"/>
- <ref bean="OAuthFilter"/>
- <ref bean="basicAuthenticationFilter"/>
- <ref bean="sessionAuthenticationFilter"/>
- <!--<ref bean="authorizationFilter"/>-->
- </jaxrs:providers>
- </jaxrs:server>
-
- <bean id="stratosRestEndpointBean" class="org.apache.stratos.metadataservice.services.MetaDataAdmin"/>
- <bean id="basicAuthenticationFilter" class="org.apache.stratos.metadataservice.handlers.StratosAuthenticationHandler"/>
- <bean id="sessionAuthenticationFilter" class="org.apache.stratos.metadataservice.handlers.CookieBasedAuthenticationHandler"/>
- <bean id="authorizationFilter" class="org.apache.stratos.metadataservice.handlers.StratosAuthorizingHandler">
- <property name="securedObject" ref="stratosRestEndpointBean"/>
- </bean>
- <bean id="exceptionHandler" class="org.apache.stratos.metadataservice.handlers.CustomExceptionMapper"/>
- <bean id="genericExceptionHandler" class="org.apache.stratos.metadataservice.handlers.GenericExceptionMapper"/>
- <bean id="throwableExceptionHandler" class="org.apache.stratos.metadataservice.handlers.CustomThrowableExceptionMapper"/>
- <!--The below config enables OAuth based authentication/authorization for REST API-->
- <bean id="OAuthFilter" class="org.apache.stratos.metadataservice.handlers.OAuthHandler">
- <property name="password" value="admin"/>
- <property name="username" value="admin"/>
- <property name="oauthValidationEndpoint" value="https://localhost:9443/services/"/>
- </bean>
- <bean id="jsonProvider" class="org.apache.cxf.jaxrs.provider.json.JSONProvider">
- <property name="supportUnwrapped" value="true"/>
- <property name="serializeAsArray" value="true"/>
- <property name="dropRootElement" value="true" />
- <property name="arrayKeys">
- <list>
- <value>partitions</value>
- <value>property</value>
- <value>hostNames</value>
- <value>memberMap</value>
- <value>portMap</value>
- <value>partitionGroup</value>
- <value>partition</value>
- <value>member</value>
- <value>hostNames</value>
- <value>portMappings</value>
- <value>volumes</value>
- </list>
- </property>
- </bean>
-
-</beans>
http://git-wip-us.apache.org/repos/asf/stratos/blob/74de671c/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/WEB-INF/web.xml
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/WEB-INF/web.xml b/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/WEB-INF/web.xml
deleted file mode 100644
index a46ee34..0000000
--- a/components/org.apache.stratos.metadataservice/src/main/webapp/stratosmetadataservice/WEB-INF/web.xml
+++ /dev/null
@@ -1,39 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- # Licensed to the Apache Software Foundation (ASF) under one
- # or more contributor license agreements. See the NOTICE file
- # distributed with this work for additional information
- # regarding copyright ownership. The ASF licenses this file
- # to you 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.
- -->
-
-<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
- http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
-
- <display-name>S2 Admin Endpoint</display-name>
- <servlet>
- <servlet-name>StratosAdminEndpoint</servlet-name>
- <servlet-class>org.apache.cxf.transport.servlet.CXFServlet</servlet-class>
- <load-on-startup>1</load-on-startup>
- </servlet>
-
- <servlet-mapping>
- <servlet-name>StratosAdminEndpoint</servlet-name>
- <url-pattern>/*</url-pattern>
- </servlet-mapping>
-
-</web-app>
-