You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by de...@apache.org on 2005/09/14 05:56:49 UTC
svn commit: r280756 [1/2] - in /webservices/axis2/trunk/java/modules:
core/src/org/apache/axis2/ core/src/org/apache/axis2/clientapi/
core/src/org/apache/axis2/context/ core/src/org/apache/axis2/deployment/
core/src/org/apache/axis2/description/ core/s...
Author: deepal
Date: Tue Sep 13 20:56:02 2005
New Revision: 280756
URL: http://svn.apache.org/viewcvs?rev=280756&view=rev
Log:
fixing ServiceGroup ,
build will break , we will fix that soon
Modified:
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/Constants.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/clientapi/Call.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/clientapi/MessageSender.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/context/ConfigurationContext.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentEngine.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ServiceDescription.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ServiceGroupDescription.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AddressingBasedDispatcher.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AxisConfiguration.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AxisConfigurationImpl.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/RequestURIBasedDispatcher.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/PhaseResolver.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/transport/http/HTTPTransportReceiver.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/transport/http/ListingAgent.java
webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/util/Utils.java
webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/deployment/BuildERWithDeploymentTest.java
webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/description/RegistryTest.java
webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ModuleConfigTest.java
webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ModuleEngageTest.java
webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ParamterAddTest.java
webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ParamterLocked.java
webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/phaserule/InvalidPhaseRuleTest.java
webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/groovy/GroovyServiceTest.java
webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/integration/UtilServer.java
webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/integration/UtilsTCPServer.java
webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailCharSetEncodingTest.java
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/Constants.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/Constants.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/Constants.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/Constants.java Tue Sep 13 20:56:02 2005
@@ -172,6 +172,9 @@
public static final String LOGGED = "Logged";
+ public static final char SERVICE_NAME_SPLIT_CHAR =':';
+
+
public static interface Configuration {
public static final String ENABLE_REST = "enableREST";
// globally enable MTOM
@@ -199,6 +202,8 @@
public static final String GET_PARAMETER_URL = "http://ws.apache.org/goGetWithREST";
}
+
+
}
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/clientapi/Call.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/clientapi/Call.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/clientapi/Call.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/clientapi/Call.java Tue Sep 13 20:56:02 2005
@@ -220,7 +220,9 @@
}
axisService.addOperation(operationTemplate);
serviceGroupDescription.addService(axisService);
- return sysContext.createServiceContext(assumedServiceName);
+// return sysContext.createServiceContext(assumedServiceName);
+ //todo fix me Chinthaka
+ return null;
}
/**
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/clientapi/MessageSender.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/clientapi/MessageSender.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/clientapi/MessageSender.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/clientapi/MessageSender.java Tue Sep 13 20:56:02 2005
@@ -89,7 +89,9 @@
ServiceDescription axisService = new ServiceDescription(
assumedServiceName);
sysContext.getAxisConfiguration().addService(axisService);
- return sysContext.createServiceContext(
- assumedServiceName);
+ return null;
+ //todo fixme Chinthaka
+// return sysContext.createServiceContext(
+// assumedServiceName);
}
}
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/context/ConfigurationContext.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/context/ConfigurationContext.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/context/ConfigurationContext.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/context/ConfigurationContext.java Tue Sep 13 20:56:02 2005
@@ -143,16 +143,7 @@
this.storage = storage;
}
-// public ServiceContext createServiceContext(QName serviceName)
-// throws AxisFault {
-// ServiceDescription service = axisConfiguration.getService(serviceName);
-// if (service != null) {
-// return new ServiceContext(service, this);
-// } else {
-// throw new AxisFault(
-// "Service not found service name = " + serviceName);
-// }
-// }
+
/**
* @return the Gloal ThradPool
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentEngine.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentEngine.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentEngine.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentEngine.java Tue Sep 13 20:56:02 2005
@@ -566,7 +566,7 @@
ServiceDescription service =
archiveReader.createService(currentArchiveFile);
service.setClassLoader(currentArchiveFile.getClassLoader());
- service.setParent(axisConfig);
+ // service.setParent(axisConfig);
archiveReader.processServiceDescriptor(currentArchiveFile.getAbsolutePath(),
this,
service,extractServiceArchive);
@@ -673,7 +673,8 @@
WSInfo wsInfo = (WSInfo) wsToUnDeploy.get(i);
if (wsInfo.getType() == SERVICE) {
serviceName = getAxisServiceName(wsInfo.getFilename());
- axisConfig.removeService(new QName(serviceName));
+ //todo fix me deepal
+ // axisConfig.removeService(new QName(serviceName));
log.info(Messages.getMessage(DeploymentErrorMsgs.SERVICE_REMOVED,
wsInfo.getFilename()));
}
@@ -681,7 +682,7 @@
}
}
- } catch (AxisFault e) {
+ } catch (Exception e) {
log.info(e);
}
wsToUnDeploy.clear();
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ServiceDescription.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ServiceDescription.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ServiceDescription.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ServiceDescription.java Tue Sep 13 20:56:02 2005
@@ -121,23 +121,19 @@
if (moduleref == null) {
return;
}
- if (moduleref != null) {
- Collection collectionModule = (Collection) this.getComponentProperty(
- MODULEREF_KEY);
- for (Iterator iterator = collectionModule.iterator();
- iterator.hasNext();) {
- ModuleDescription modu = (ModuleDescription) iterator.next();
- if (modu.getName().equals(moduleref.getName())) {
- throw new AxisFault(moduleref.getName().getLocalPart() +
- " module has alredy been engaged on the service. " +
- " Operation terminated !!!");
- }
-
+ Collection collectionModule = (Collection) this.getComponentProperty(
+ MODULEREF_KEY);
+ for (Iterator iterator = collectionModule.iterator();
+ iterator.hasNext();) {
+ ModuleDescription modu = (ModuleDescription) iterator.next();
+ if (modu.getName().equals(moduleref.getName())) {
+ throw new AxisFault(moduleref.getName().getLocalPart() +
+ " module has alredy been engaged on the service. " +
+ " Operation terminated !!!");
}
+
}
new PhaseResolver(axisConfig).engageModuleToService(this, moduleref);
- Collection collectionModule = (Collection) this.getComponentProperty(
- MODULEREF_KEY);
collectionModule.add(moduleref);
}
@@ -146,11 +142,13 @@
*
* @param module
*/
+
public void addModuleOperations(ModuleDescription module,
- AxisConfiguration axisConfig) {
+ AxisConfiguration axisConfig) throws AxisFault {
HashMap map = module.getOperations();
Collection col = map.values();
PhaseResolver pr = new PhaseResolver(axisConfig, this);
+
for (Iterator iterator = col.iterator(); iterator.hasNext();) {
OperationDescription operation = (OperationDescription) iterator.next();
ArrayList paramters = operation.getParameters();
@@ -161,6 +159,7 @@
this.addMapping((String)parameter.getValue(),operation);
}
}
+ pr.buildModuleOperation(operation);
this.addOperation(operation);
}
}
@@ -187,7 +186,7 @@
/**
* Method getEngadgedModules
*
- * @return
+ * @return Collection
*/
public Collection getEngagedModules() {
return (Collection) this.getComponentProperty(MODULEREF_KEY);
@@ -197,7 +196,7 @@
* Method getOperation
*
* @param operationName
- * @return
+ * @return OperationDescription
*/
public OperationDescription getOperation(QName operationName) {
String opStr = operationName.getLocalPart();
@@ -253,7 +252,7 @@
/**
* Method getClassLoader
*
- * @return
+ * @return ClassLoader
*/
public ClassLoader getClassLoader() {
return (ClassLoader) this.getComponentProperty(CLASSLOADER_KEY);
@@ -285,7 +284,7 @@
/**
* Method getContextPath
*
- * @return
+ * @return String
*/
public String getContextPath() {
return (String) this.getComponentProperty(CONTEXTPATH_KEY);
@@ -317,7 +316,7 @@
/**
* Method getStyle
*
- * @return
+ * @return String
*/
public String getStyle() {
return (String) this.getComponentProperty(STYLE_KEY);
@@ -365,7 +364,7 @@
* Method getParameter
*
* @param name
- * @return
+ * @return Parameter
*/
public Parameter getParameter(String name) {
ParameterIncludeImpl paramInclude =
@@ -388,7 +387,7 @@
/**
* Method getInFlow
*
- * @return
+ * @return Flow
*/
public Flow getInFlow() {
return (Flow) this.getComponentProperty(INFLOW_KEY);
@@ -420,7 +419,7 @@
/**
* Method getOutFlow
*
- * @return
+ * @return Flow
*/
public Flow getOutFlow() {
return (Flow) this.getComponentProperty(OUTFLOW_KEY);
@@ -452,7 +451,7 @@
/**
* Method getFaultInFlow
*
- * @return
+ * @return Flow
*/
public Flow getFaultInFlow() {
return (Flow) this.getComponentProperty(IN_FAULTFLOW_KEY);
@@ -488,7 +487,7 @@
/**
* Method getOperations
*
- * @return
+ * @return HashMap
*/
public HashMap getOperations() {
return this.getServiceInterface().getOperations();
@@ -581,7 +580,7 @@
* EngineContext's ServiceContextMap.
*
* @param msgContext
- * @return
+ * @return ServiceContext
*/
public ServiceContext findServiceContext(MessageContext msgContext) {
// TODO : Fix me. Can't look up a service context in the system context
@@ -606,7 +605,7 @@
/**
* To get the description about the service
*
- * @return
+ * @return String
*/
public String getServiceDescription() {
return serviceDescription;
@@ -796,11 +795,7 @@
return true;
} else {
Parameter parameter = getParameter(paramterName);
- if(parameter != null && parameter.isLocked()){
- return true;
- } else {
- return false;
- }
+ return parameter != null && parameter.isLocked();
}
}
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ServiceGroupDescription.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ServiceGroupDescription.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ServiceGroupDescription.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ServiceGroupDescription.java Tue Sep 13 20:56:02 2005
@@ -1,12 +1,15 @@
package org.apache.axis2.description;
-import org.apache.axis2.AxisFault;
import org.apache.axis2.engine.AxisConfiguration;
import org.apache.axis2.engine.AxisEvent;
+import org.apache.axis2.AxisFault;
import org.apache.axis2.phaseresolver.PhaseResolver;
import javax.xml.namespace.QName;
import java.util.HashMap;
+import java.util.ArrayList;
+import java.util.Iterator;
+
/*
* Copyright 2004,2005 The Apache Software Foundation.
*
@@ -25,45 +28,168 @@
*
*/
-public class ServiceGroupDescription {
- private final HashMap services = new HashMap();
- private AxisConfiguration axisDescription;
+public class ServiceGroupDescription implements ParameterInclude{
+
+ //to add and get paramters
+ protected ParameterInclude paramInclude;
+
+ // to keep name of the service group
+ private String serviceGroupName;
+
+ // to keep the parent of service group , to chcek paramter lock checking and serching
+ private AxisConfiguration parent;
+
+ /**
+ * Field services
+ */
+ private HashMap services;
+
+ //to store modeule configuration info
+ private HashMap moduleConfigmap;
+
+ // to store service Group modules name
+ private ArrayList modules;
+
+
+ public ServiceGroupDescription() {
+ paramInclude = new ParameterIncludeImpl();
+ services = new HashMap();
+ moduleConfigmap = new HashMap();
+ modules = new ArrayList();
+ }
+
+ public void addParameter(Parameter param) throws AxisFault {
+ paramInclude.addParameter(param);
+ }
+
+ public Parameter getParameter(String name) {
+ return paramInclude.getParameter(name);
+ }
+
+ public ArrayList getParameters() {
+ return paramInclude.getParameters();
+ }
+
+ public boolean isParamterLocked(String paramterName) {
+ // checking the locked value of parent
+ boolean loscked = false;
+
+ if (getParent() !=null) {
+ loscked = getParent().isParamterLocked(paramterName);
+ }
+ if(loscked){
+ return true;
+ } else {
+ Parameter parameter = getParameter(paramterName);
+ if(parameter != null && parameter.isLocked()){
+ return true;
+ } else {
+ return false;
+ }
+ }
+ }
+
+ public String getServiceGroupName() {
+ return serviceGroupName;
+ }
+
+ public void setServiceGroupName(String serviceGroupName) {
+ this.serviceGroupName = serviceGroupName;
+ }
+
+ public AxisConfiguration getParent() {
+ return parent;
+ }
+
+ public void setParent(AxisConfiguration parent) {
+ this.parent = parent;
+ }
+
+ /**
+ * Adding module configuration , if there is moduleConfig tag in service
+ * @param moduleConfiguration
+ */
+ public void addModuleConfig(ModuleConfiguration moduleConfiguration){
+ if(moduleConfigmap == null){
+ moduleConfigmap = new HashMap();
+ }
+ moduleConfigmap.put(moduleConfiguration.getModuleName(),moduleConfiguration);
+ }
+
+ public ModuleConfiguration getModuleConfig(QName moduleName){
+ return (ModuleConfiguration)moduleConfigmap.get(moduleName);
+ }
+
+ public void addModule(QName moduleName){
+ modules.add(moduleName);
+ }
+
+ public void engageModuleToGroup(QName moduleName) throws AxisFault {
+ if (moduleName == null) {
+ return;
+ }
+ for (Iterator iterator = modules.iterator();
+ iterator.hasNext();) {
+ ModuleDescription modu = (ModuleDescription) iterator.next();
+ if (modu.getName().equals(moduleName)) {
+ throw new AxisFault(moduleName.getLocalPart() +
+ " module has alredy been engaged on the service Group. " +
+ " Operation terminated !!!");
+ }
+ }
+ Iterator srevice = getServices();
+ PhaseResolver phaseResolver = new PhaseResolver(this.getParent());
+ ModuleDescription module = this.parent.getModule(moduleName);
+ if (module !=null) {
+ while (srevice.hasNext()) {
+ // engagin per each service
+ ServiceDescription serviceDescription = (ServiceDescription) srevice.next();
+ phaseResolver.engageModuleToService(serviceDescription, module);
+ }
+ }
+ addModule(moduleName);
+ }
+
+ public ArrayList getServiceGroupModules(){
+ return modules;
+ }
+
+
+ public Iterator getServices(){
+ return services.values().iterator();
+ }
public ServiceGroupDescription(AxisConfiguration axisDescription) {
- this.axisDescription = axisDescription;
+ this.parent = axisDescription;
}
public synchronized void addService(ServiceDescription service) throws AxisFault {
services.put(service.getName(), service);
- PhaseResolver handlerResolver = new PhaseResolver(this.axisDescription, service);
+ PhaseResolver handlerResolver = new PhaseResolver(this.parent, service);
handlerResolver.buildchains();
service.setLastupdate();
- this.axisDescription.notifyObservers(AxisEvent.SERVICE_DEPLOY ,service);
service.setParent(this);
}
public AxisConfiguration getAxisDescription() {
- return axisDescription;
+ return parent;
}
public void setAxisDescription(AxisConfiguration axisDescription) {
- this.axisDescription = axisDescription;
+ this.parent = axisDescription;
}
public ServiceDescription getService(QName name) throws AxisFault {
return (ServiceDescription) services.get(name);
}
- public HashMap getServices() {
- return services;
- }
public synchronized void removeService(QName name) throws AxisFault {
ServiceDescription service = getService(name);
if (service != null) {
- this.axisDescription.notifyObservers(AxisEvent.SERVICE_DEPLOY , service);
+ this.parent.notifyObservers(AxisEvent.SERVICE_DEPLOY , service);
}
services.remove(name);
}
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AddressingBasedDispatcher.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AddressingBasedDispatcher.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AddressingBasedDispatcher.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AddressingBasedDispatcher.java Tue Sep 13 20:56:02 2005
@@ -65,7 +65,7 @@
QName serviceName = new QName(toEPR.getAddress());
service =
messageContext.getSystemContext().getAxisConfiguration()
- .getService(serviceName);
+ .getService(serviceName.getLocalPart());
if (service == null) {
String filePart = toEPR.getAddress();
String[] values = Utils.parseRequestURLForServiceAndOperation(
@@ -74,7 +74,7 @@
serviceName = new QName(values[0]);
AxisConfiguration registry =
messageContext.getSystemContext().getAxisConfiguration();
- return registry.getService(serviceName);
+ return registry.getService(serviceName.getLocalPart());
}
}
}
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AxisConfiguration.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AxisConfiguration.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AxisConfiguration.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AxisConfiguration.java Tue Sep 13 20:56:02 2005
@@ -23,6 +23,7 @@
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Hashtable;
+import java.util.Iterator;
/**
* The palce where all the Global states of Axis is kept.
@@ -49,12 +50,33 @@
public static final int FAULT_OUT_FLOW = 10006;
/**
+<<<<<<< .mine
+ * Method getService
+ *
+ * @param name
+ * @return
+ * @throws AxisFault
+ */
+ public ServiceDescription getService(String name) throws AxisFault;
+
+ /**
+ * Method addService
+ *
+ * @param service
+ * @throws AxisFault
+ */
+ public void addService(ServiceDescription service) throws AxisFault;
+
+ //to Add service Groups
+ public void addServiceGroup(ServiceGroupDescription serviceGroup);
+
+ /**
* Method removeService
*
* @param name
* @throws AxisFault
*/
-// public void removeService(QName name) throws AxisFault;
+ public void removeService(String name) throws AxisFault;
/**
* Modules is read only as they can not deployed while runing
@@ -90,13 +112,6 @@
public ArrayList getInFaultFlow();
- /**
- * Method getServices
- *
- * @return
- */
-// public HashMap getServices();
-
public Hashtable getFaultyServices();
public Hashtable getFaultyModules();
@@ -122,6 +137,8 @@
public boolean isParamterLocked(String paramterName);
public ServiceGroupDescription getServiceGroup(String serviceNameAndGroupString);
+
+ Iterator getServiceGroups();
public void notifyObservers(int event_type , ServiceDescription service);
}
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AxisConfigurationImpl.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AxisConfigurationImpl.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AxisConfigurationImpl.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/AxisConfigurationImpl.java Tue Sep 13 20:56:02 2005
@@ -17,6 +17,7 @@
import org.apache.axis2.AxisFault;
import org.apache.axis2.InstanceDispatcher;
+import org.apache.axis2.Constants;
import org.apache.axis2.deployment.DeploymentEngine;
import org.apache.axis2.deployment.repository.util.ArchiveReader;
import org.apache.axis2.deployment.util.PhasesInfo;
@@ -56,8 +57,9 @@
/**
* Field services
*/
- private final HashMap services = new HashMap();
+// private final HashMap services = new HashMap();
+ private final HashMap serviceGroups = new HashMap();
private final HashMap transportsIn = new HashMap();
private final HashMap transportsOut = new HashMap();
@@ -65,7 +67,7 @@
/**
* Field phases
*/
- private ArrayList inPhases;
+ // private ArrayList inPhases;
private ArrayList outPhases;
private ArrayList inFaultPhases;
private ArrayList outFaultPhases;
@@ -103,7 +105,6 @@
engagedModules = new ArrayList();
messagReceivers = new HashMap();
- inPhases = new ArrayList();
outPhases = new ArrayList();
inFaultPhases = new ArrayList();
outFaultPhases = new ArrayList();
@@ -199,13 +200,6 @@
inPhasesUptoAndIncludingPostDispatch.add(postDispatch);
}
- /**
- * Method getServices
- *
- */
- public HashMap getServices() {
- return services;
- }
public Hashtable getFaultyServices() {
return faultyServices;
@@ -232,30 +226,74 @@
* @param service
* @throws AxisFault
*/
-// public synchronized void addService(ServiceDescription service) throws AxisFault {
-// services.put(service.getName(), service);
-// PhaseResolver handlerResolver = new PhaseResolver(this, service);
-// handlerResolver.buildchains();
-// service.setLastupdate();
-// notifyObservers(AxisEvent.SERVICE_DEPLOY ,service);
-// service.setParent(this);
-// }
+ public synchronized void addService(ServiceDescription service) throws AxisFault {
+ ServiceGroupDescription serviceGroup = new ServiceGroupDescription();
+ serviceGroup.setServiceGroupName(service.getName().getLocalPart());
+ serviceGroup.setParent(this);
+ serviceGroup.addService(service);
+ addServiceGroup(serviceGroup);
+ }
+
+ public void addServiceGroup(ServiceGroupDescription serviceGroup){
+ serviceGroups.put(serviceGroup.getServiceGroupName(),serviceGroup);
+ Iterator services = serviceGroup.getServices();
+ while (services.hasNext()) {
+ ServiceDescription description = (ServiceDescription) services.next();
+ notifyObservers(AxisEvent.SERVICE_DEPLOY ,description);
+ }
+ }
/**
* Method getModule
*
* @param name
+ * @return ModuleDescription
*/
public ModuleDescription getModule(QName name) {
return (ModuleDescription) modules.get(name);
}
/**
+ * @return HashMap
*/
public HashMap getModules() {
return modules;
}
+ /**
+ * Method getService
+ *
+ * @param name
+ * @return
+ * @throws AxisFault
+ */
+ public ServiceDescription getService(String name) throws AxisFault {
+ String [] nameParts = splitServiceName(name);
+ ServiceGroupDescription sg = getServiceGroup(nameParts[0]);
+ if(sg == null){
+ throw new AxisFault("Service Not Found : " + name);
+ } else {
+ ServiceDescription service = sg.getService(new QName(nameParts[1]));
+ if(service == null){
+ throw new AxisFault("Service Not Found : " + name);
+ } else {
+ return service;
+ }
+ }
+ }
+ /**
+ * Method removeService
+ *
+ * @param name
+ * @throws AxisFault
+ */
+ public synchronized void removeService(String name) throws AxisFault {
+ String [] nameParts = splitServiceName(name);
+ ServiceGroupDescription sg = getServiceGroup(nameParts[0]);
+ if(sg != null){
+ sg.removeService(new QName(nameParts[1]));
+ }
+ }
public TransportInDescription getTransportIn(QName name) throws AxisFault {
return (TransportInDescription) transportsIn.get(name);
@@ -307,20 +345,15 @@
//to check whether a given paramter is locked
public boolean isParamterLocked(String paramterName) {
Parameter parameter = getParameter(paramterName);
- if(parameter != null && parameter.isLocked()){
- return true;
- } else {
- return false;
- }
+ return parameter != null && parameter.isLocked();
}
public ServiceGroupDescription getServiceGroup(String serviceNameAndGroupString) {
- return null; //TODO Deepal please implement this
+ return (ServiceGroupDescription)serviceGroups.get(serviceNameAndGroupString);
}
-
- public void setInPhases(ArrayList inPhases) {
- this.inPhases = inPhases;
+ public Iterator getServiceGroups() {
+ return serviceGroups.values().iterator();
}
public void setOutPhases(ArrayList outPhases) {
@@ -338,12 +371,20 @@
/**
+<<<<<<< .mine
+ * @return ArrayList
+=======
+>>>>>>> .r280753
*/
public ArrayList getInFaultFlow() {
return inFaultPhases;
}
/**
+<<<<<<< .mine
+ * @return ArrayList
+=======
+>>>>>>> .r280753
*/
public ArrayList getOutFaultFlow() {
return outFaultPhases;
@@ -378,6 +419,10 @@
* Method getParameter
*
* @param name
+<<<<<<< .mine
+ * @return Parameter
+=======
+>>>>>>> .r280753
*/
public Parameter getParameter(String name) {
return paramInclude.getParameter(name);
@@ -403,6 +448,10 @@
/**
* Method getEngadgedModules
*
+<<<<<<< .mine
+ * @return Collection
+=======
+>>>>>>> .r280753
*/
public Collection getEngadgedModules() {
return engagedModules;
@@ -492,6 +541,28 @@
public ModuleConfiguration getModuleConfig(QName moduleName){
return (ModuleConfiguration)moduleConfigmap.get(moduleName);
+ }
+
+
+ /**
+ * To split a given service name into it serviceGroupName and Service Name
+ * if the service Name is foo:bar then serviceGroupName ="foo" and ServiceName ="bar"
+ * but if the service name is only the foo we asume ServiceGroupName="foo" ans ServiceName="foo"
+ * meaning foo := foo:foo
+ * @param serviceName
+ * @return String [] <code>String</code>
+ */
+ private String [] splitServiceName(String serviceName){
+ String namePart [] = new String[2];
+ int index = serviceName.indexOf(Constants.SERVICE_NAME_SPLIT_CHAR);
+ if(index > 0){
+ namePart[0] = serviceName.substring(0,index);
+ namePart[1] = serviceName.substring(index +1 ,serviceName.length());
+ } else {
+ namePart[0] = serviceName;
+ namePart[0] = serviceName;
+ }
+ return namePart;
}
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/RequestURIBasedDispatcher.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/RequestURIBasedDispatcher.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/RequestURIBasedDispatcher.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/RequestURIBasedDispatcher.java Tue Sep 13 20:56:02 2005
@@ -35,7 +35,7 @@
public static final QName NAME =
new QName("http://axis.ws.apache.org",
"RequestURIBasedDispatcher");
- QName serviceName = null;
+ String serviceName = null;
QName operationName = null;
@@ -62,7 +62,7 @@
operationName = new QName(values[1]);
}
if (values[0] != null) {
- serviceName = new QName(values[0]);
+ serviceName = values[0];
AxisConfiguration registry =
messageContext.getSystemContext().getAxisConfiguration();
return registry.getService(serviceName);
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java Tue Sep 13 20:56:02 2005
@@ -37,7 +37,7 @@
public static final QName NAME =
new QName("http://axis.ws.apache.org",
"SOAPMessageBodyBasedDispatcher");
- QName serviceName = null;
+ String serviceName = null;
QName operationName = null;
/**
@@ -78,7 +78,7 @@
operationName = new QName(values[1]);
}
if (values[0] != null) {
- serviceName = new QName(values[0]);
+ serviceName = values[0];
AxisConfiguration registry =
messageContext.getSystemContext().getAxisConfiguration();
return registry.getService(serviceName);
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/PhaseResolver.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/PhaseResolver.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/PhaseResolver.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/PhaseResolver.java Tue Sep 13 20:56:02 2005
@@ -128,30 +128,31 @@
if (module != null) {
switch (type) {
case PhaseMetadata.IN_FLOW:
- {
- flow = module.getInFlow();
- break;
- }
+ {
+ flow = module.getInFlow();
+ break;
+ }
case PhaseMetadata.OUT_FLOW:
- {
- flow = module.getOutFlow();
- break;
- }
+ {
+ flow = module.getOutFlow();
+ break;
+ }
case PhaseMetadata.FAULT_IN_FLOW:
- {
- flow = module.getFaultInFlow();
- break;
- }
+ {
+ flow = module.getFaultInFlow();
+ break;
+ }
case PhaseMetadata.FAULT_OUT_FLOW:
- {
- flow = module.getFaultOutFlow();
- break;
- }
+ {
+ flow = module.getFaultOutFlow();
+ break;
+ }
}
axisService.addToEngagModuleList(module);
operation.addToEngageModuleList(module);
} else {
- throw new PhaseException(Messages.getMessage(DeploymentErrorMsgs.INVALID_MODULE_REF, modulename.getLocalPart()));
+ throw new PhaseException(Messages.getMessage(
+ DeploymentErrorMsgs.INVALID_MODULE_REF, modulename.getLocalPart()));
}
if (flow != null) {
@@ -176,25 +177,25 @@
////////////////////////// SERVICE HANDLERS ///////////////////////////////////////////////
switch (type) {
case PhaseMetadata.IN_FLOW:
- {
- flow = axisService.getInFlow();
- break;
- }
+ {
+ flow = axisService.getInFlow();
+ break;
+ }
case PhaseMetadata.OUT_FLOW:
- {
- flow = axisService.getOutFlow();
- break;
- }
+ {
+ flow = axisService.getOutFlow();
+ break;
+ }
case PhaseMetadata.FAULT_IN_FLOW:
- {
- flow = axisService.getFaultInFlow();
- break;
- }
+ {
+ flow = axisService.getFaultInFlow();
+ break;
+ }
case PhaseMetadata.FAULT_OUT_FLOW:
- {
- flow = axisService.getFaultOutFlow();
- break;
- }
+ {
+ flow = axisService.getFaultOutFlow();
+ break;
+ }
}
if (flow != null) {
for (int j = 0; j < flow.getHandlerCount(); j++) {
@@ -202,37 +203,43 @@
// todo change this in properway
if (metadata.getRules().getPhaseName().equals("")) {
- throw new PhaseException(Messages.getMessage(DeploymentErrorMsgs.PHASE_DOES_NOT_SPECIFED,
- metadata.getName().getLocalPart()));
+ throw new PhaseException(
+ Messages.getMessage(DeploymentErrorMsgs.PHASE_DOES_NOT_SPECIFED,
+ metadata.getName().getLocalPart()));
+ } else if(PhaseValidator.isSystemPhases(metadata.getRules().getPhaseName())){
+ throw new PhaseException(Messages.getMessage(
+ DeploymentErrorMsgs.SERVICE_MODULE_CAN_NOT_REFER_GLOBAL_PHASE,
+ metadata.getRules().getPhaseName()));
+ } else {
+ allHandlers.add(metadata);
}
- allHandlers.add(metadata);
}
}
switch (type) {
case PhaseMetadata.IN_FLOW:
- {
- phaseHolder =
- new PhaseHolder(operation.getRemainingPhasesInFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(operation.getRemainingPhasesInFlow());
+ break;
+ }
case PhaseMetadata.OUT_FLOW:
- {
- phaseHolder =
- new PhaseHolder(operation.getPhasesOutFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(operation.getPhasesOutFlow());
+ break;
+ }
case PhaseMetadata.FAULT_IN_FLOW:
- {
- phaseHolder =
- new PhaseHolder(operation.getPhasesInFaultFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(operation.getPhasesInFaultFlow());
+ break;
+ }
case PhaseMetadata.FAULT_OUT_FLOW:
- {
- phaseHolder =
- new PhaseHolder(operation.getPhasesOutFaultFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(operation.getPhasesOutFaultFlow());
+ break;
+ }
}
for (int i = 0; i < allHandlers.size(); i++) {
HandlerDescription handlerMetaData =
@@ -273,17 +280,17 @@
for (int type = 1; type < 4; type++) {
switch (type) {
case PhaseMetadata.IN_FLOW:
- {
- flow = transport.getInFlow();
- phase = transport.getInPhase();
- break;
- }
+ {
+ flow = transport.getInFlow();
+ phase = transport.getInPhase();
+ break;
+ }
case PhaseMetadata.FAULT_IN_FLOW:
- {
- flow = transport.getFaultFlow();
- phase = transport.getFaultPhase();
- break;
- }
+ {
+ flow = transport.getFaultFlow();
+ phase = transport.getFaultPhase();
+ break;
+ }
}
if (flow != null) {
ArrayList handlers = new ArrayList();
@@ -312,17 +319,17 @@
for (int type = 1; type < 5; type++) {
switch (type) {
case PhaseMetadata.OUT_FLOW:
- {
- flow = transport.getOutFlow();
- phase = transport.getOutPhase();
- break;
- }
+ {
+ flow = transport.getOutFlow();
+ phase = transport.getOutPhase();
+ break;
+ }
case PhaseMetadata.FAULT_OUT_FLOW:
- {
- flow = transport.getFaultFlow();
- phase = transport.getFaultPhase();
- break;
- }
+ {
+ flow = transport.getFaultFlow();
+ phase = transport.getFaultPhase();
+ break;
+ }
}
if (flow != null) {
ArrayList handlers = new ArrayList();
@@ -340,13 +347,17 @@
public void engageModuleGlobally(ModuleDescription module) throws AxisFault {
enageToGlobalChain(module);
- HashMap services = axisConfig.getServices();
- Collection serviceCol = services.values();
- for (Iterator iterator = serviceCol.iterator(); iterator.hasNext();) {
- ServiceDescription serviceDescription = (ServiceDescription) iterator.next();
- serviceDescription.addModuleOperations(module, axisConfig);
- engageModuleToServiceFromGlobal(serviceDescription, module);
- serviceDescription.addToEngagModuleList(module);
+ Iterator servicegroups = axisConfig.getServiceGroups();
+ while (servicegroups.hasNext()) {
+ ServiceGroupDescription sericeGroup = (ServiceGroupDescription) servicegroups.next();
+ Iterator services = sericeGroup.getServices();
+ while (services.hasNext()) {
+ ServiceDescription serviceDescription = (ServiceDescription) services.next();
+ serviceDescription.addModuleOperations(module, axisConfig);
+ engageModuleToServiceFromGlobal(serviceDescription, module);
+ serviceDescription.addToEngagModuleList(module);
+ }
+ sericeGroup.addModule(module.getName());
}
}
@@ -380,54 +391,54 @@
for (int type = 1; type < 5; type++) {
switch (type) {
case PhaseMetadata.IN_FLOW:
- {
- phaseHolder =
- new PhaseHolder(opDesc.getRemainingPhasesInFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(opDesc.getRemainingPhasesInFlow());
+ break;
+ }
case PhaseMetadata.OUT_FLOW:
- {
- phaseHolder =
- new PhaseHolder(opDesc.getPhasesOutFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(opDesc.getPhasesOutFlow());
+ break;
+ }
case PhaseMetadata.FAULT_IN_FLOW:
- {
- phaseHolder =
- new PhaseHolder(opDesc.getPhasesInFaultFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(opDesc.getPhasesInFaultFlow());
+ break;
+ }
case PhaseMetadata.FAULT_OUT_FLOW:
- {
- phaseHolder =
- new PhaseHolder(opDesc.getPhasesOutFaultFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(opDesc.getPhasesOutFaultFlow());
+ break;
+ }
}
////////////////////////////////////////////////////////////////////////////////////
/////////////////// Modules refered by axis2.xml //////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////
switch (type) {
case PhaseMetadata.IN_FLOW:
- {
- flow = module.getInFlow();
- break;
- }
+ {
+ flow = module.getInFlow();
+ break;
+ }
case PhaseMetadata.OUT_FLOW:
- {
- flow = module.getOutFlow();
- break;
- }
+ {
+ flow = module.getOutFlow();
+ break;
+ }
case PhaseMetadata.FAULT_IN_FLOW:
- {
- flow = module.getFaultInFlow();
- break;
- }
+ {
+ flow = module.getFaultInFlow();
+ break;
+ }
case PhaseMetadata.FAULT_OUT_FLOW:
- {
- flow = module.getFaultOutFlow();
- break;
- }
+ {
+ flow = module.getFaultOutFlow();
+ break;
+ }
}
if (flow != null) {
for (int j = 0; j < flow.getHandlerCount(); j++) {
@@ -448,55 +459,55 @@
for (int type = 1; type < 5; type++) {
switch (type) {
case PhaseMetadata.IN_FLOW:
- {
- phaseHolder =
- new PhaseHolder(axisConfig.
- getInPhasesUptoAndIncludingPostDispatch());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(axisConfig.
+ getInPhasesUptoAndIncludingPostDispatch());
+ break;
+ }
case PhaseMetadata.OUT_FLOW:
- {
- phaseHolder =
- new PhaseHolder(((AxisConfigurationImpl) axisConfig).getOutFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(((AxisConfigurationImpl) axisConfig).getOutFlow());
+ break;
+ }
case PhaseMetadata.FAULT_IN_FLOW:
- {
- phaseHolder =
- new PhaseHolder(axisConfig.getInFaultFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(axisConfig.getInFaultFlow());
+ break;
+ }
case PhaseMetadata.FAULT_OUT_FLOW:
- {
- phaseHolder =
- new PhaseHolder(((AxisConfigurationImpl) axisConfig).getOutFaultFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(((AxisConfigurationImpl) axisConfig).getOutFaultFlow());
+ break;
+ }
}
////////////////////////////////////////////////////////////////////////////////////
/////////////////// Modules refered by axis2.xml //////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////
switch (type) {
case PhaseMetadata.IN_FLOW:
- {
- flow = module.getInFlow();
- break;
- }
+ {
+ flow = module.getInFlow();
+ break;
+ }
case PhaseMetadata.OUT_FLOW:
- {
- flow = module.getOutFlow();
- break;
- }
+ {
+ flow = module.getOutFlow();
+ break;
+ }
case PhaseMetadata.FAULT_IN_FLOW:
- {
- flow = module.getFaultInFlow();
- break;
- }
+ {
+ flow = module.getFaultInFlow();
+ break;
+ }
case PhaseMetadata.FAULT_OUT_FLOW:
- {
- flow = module.getFaultOutFlow();
- break;
- }
+ {
+ flow = module.getFaultOutFlow();
+ break;
+ }
}
if (flow != null) {
for (int j = 0; j < flow.getHandlerCount(); j++) {
@@ -518,7 +529,7 @@
public void engageModuleToService(ServiceDescription service,
- ModuleDescription module) throws PhaseException {
+ ModuleDescription module) throws AxisFault {
HashMap opeartions = service.getOperations();
Collection opCol = opeartions.values();
boolean engaged = false;
@@ -548,52 +559,52 @@
for (int type = 1; type < 5; type++) {
switch (type) {
case PhaseMetadata.IN_FLOW:
- {
- phaseHolder =
- new PhaseHolder(operation.getRemainingPhasesInFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(operation.getRemainingPhasesInFlow());
+ break;
+ }
case PhaseMetadata.OUT_FLOW:
- {
- phaseHolder =
- new PhaseHolder(operation.getPhasesOutFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(operation.getPhasesOutFlow());
+ break;
+ }
case PhaseMetadata.FAULT_IN_FLOW:
- {
- phaseHolder =
- new PhaseHolder(operation.getPhasesInFaultFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(operation.getPhasesInFaultFlow());
+ break;
+ }
case PhaseMetadata.FAULT_OUT_FLOW:
- {
- phaseHolder =
- new PhaseHolder(operation.getPhasesOutFaultFlow());
- break;
- }
+ {
+ phaseHolder =
+ new PhaseHolder(operation.getPhasesOutFaultFlow());
+ break;
+ }
}
switch (type) {
case PhaseMetadata.IN_FLOW:
- {
- flow = module.getInFlow();
- break;
- }
+ {
+ flow = module.getInFlow();
+ break;
+ }
case PhaseMetadata.OUT_FLOW:
- {
- flow = module.getOutFlow();
- break;
- }
+ {
+ flow = module.getOutFlow();
+ break;
+ }
case PhaseMetadata.FAULT_IN_FLOW:
- {
- flow = module.getFaultInFlow();
- break;
- }
+ {
+ flow = module.getFaultInFlow();
+ break;
+ }
case PhaseMetadata.FAULT_OUT_FLOW:
- {
- flow = module.getFaultOutFlow();
- break;
- }
+ {
+ flow = module.getFaultOutFlow();
+ break;
+ }
}
if (flow != null) {
for (int j = 0; j < flow.getHandlerCount(); j++) {
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/transport/http/HTTPTransportReceiver.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/transport/http/HTTPTransportReceiver.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/transport/http/HTTPTransportReceiver.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/transport/http/HTTPTransportReceiver.java Tue Sep 13 20:56:02 2005
@@ -289,66 +289,71 @@
public static String getServicesHTML(
ConfigurationContext configurationContext) {
String temp = "";
- Map services =
- configurationContext.getAxisConfiguration().getServices();
- Hashtable erroneousServices =
- configurationContext.getAxisConfiguration().getFaultyServices();
- boolean status = false;
-
- if (services != null && !services.isEmpty()) {
- status = true;
- Collection serviceCollection = services.values();
- temp += "<h2>" + "Deployed services" + "</h2>";
- for (Iterator it = serviceCollection.iterator(); it.hasNext();) {
- Map operations;
- Collection operationsList;
- ServiceDescription axisService = (ServiceDescription) it.next();
- operations = axisService.getOperations();
- operationsList = operations.values();
-
- temp += "<h3>" + axisService.getName().getLocalPart() +
- "</h3>";
- if (operationsList.size() > 0) {
- temp += "Available operations <ul>";
- for (Iterator iterator1 = operationsList.iterator();
- iterator1.hasNext();
- ) {
- OperationDescription axisOperation =
- (OperationDescription) iterator1.next();
- temp += "<li>"
- + axisOperation.getName().getLocalPart()
- + "</li>";
- }
- temp += "</ul>";
- } else {
- temp += "No operations speficied for this service";
- }
- }
- }
-
- if (erroneousServices != null && !erroneousServices.isEmpty()) {
-
- temp += "<hr><h2><font color=\"blue\">Faulty Services</font></h2>";
- status = true;
- Enumeration faultyservices = erroneousServices.keys();
- while (faultyservices.hasMoreElements()) {
- String faultyserviceName =
- (String) faultyservices.nextElement();
- temp += "<h3><font color=\"blue\">"
- + faultyserviceName
- + "</font></h3>";
- }
- }
-
- if (!status) {
- temp = "<h2>There are no services deployed</h2>";
- }
-
- temp =
- "<html><head><title>Axis2: Services</title></head>"
- + "<body>"
- + temp
- + "</body></html>";
+ //todo Ruchith please fix me
+// Map services =configurationContext.getAxisConfiguration().getServices();
+// Hashtable erroneousServices =
+// configurationContext.getAxisConfiguration().getFaulytServices();
+// boolean status = false;
+//
+// if (services != null && !services.isEmpty()) {
+// status = true;
+// Collection serviceCollection = services.values();
+// temp += "<h2>" + "Deployed services" + "</h2>";
+// for (Iterator it = serviceCollection.iterator(); it.hasNext();) {
+// Map operations;
+// Collection operationsList;
+// ServiceDescription axisService = (ServiceDescription) it.next();
+// operations = axisService.getOperations();
+// operationsList = operations.values();
+//
+// temp += "<h3>" + axisService.getName().getLocalPart() +
+// "</h3>";
+// if (operationsList.size() > 0) {
+// temp += "Available operations <ul>";
+// for (Iterator iterator1 = operationsList.iterator();
+// iterator1.hasNext();
+// ) {
+// OperationDescription axisOperation =
+// (OperationDescription) iterator1.next();
+// temp += "<li>"
+// + axisOperation.getName().getLocalPart()
+// + "</li>";
+// }
+// temp += "</ul>";
+// } else {
+// temp += "No operations speficied for this service";
+// }
+// }
+// }
+//
+// if (erroneousServices != null && !erroneousServices.isEmpty()) {
+//
+// temp += "<hr><h2><font color=\"blue\">Faulty Services</font></h2>";
+// status = true;
+// Enumeration faultyservices = erroneousServices.keys();
+// while (faultyservices.hasMoreElements()) {
+// String faultyserviceName =
+// (String) faultyservices.nextElement();
+// temp += "<h3><font color=\"blue\">"
+// + faultyserviceName
+// + "</font></h3>";
+// }
+// }
+//
+// if (!status) {
+// temp = "<h2>There are no services deployed</h2>";
+// }
+//
+// temp =
+// "<html><head><title>Axis2: Services</title></head>"
+// + "<body>"
+// + temp
+// + "</body></html>";
+// Map services =
+// configurationContext.getAxisConfiguration().getServices();
+// Hashtable erroneousServices =
+// configurationContext.getAxisConfiguration().getFaultyServices();
+// boolean status = false;
return temp;
}
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/transport/http/ListingAgent.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/transport/http/ListingAgent.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/transport/http/ListingAgent.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/transport/http/ListingAgent.java Tue Sep 13 20:56:02 2005
@@ -182,11 +182,12 @@
* @throws IOException
*/
private void listServices(HttpServletRequest req, HttpServletResponse res) throws IOException {
- HashMap services = configContext.getAxisConfiguration().getServices();
- req.getSession().setAttribute(Constants.SERVICE_MAP, services);
- req.getSession().setAttribute(Constants.ERROR_SERVICE_MAP,
- configContext.getAxisConfiguration().getFaultyServices());
- res.sendRedirect(LIST_MULTIPLE_SERVICE_JSP_NAME);
+ //todo fix me Deepal
+// HashMap services = configContext.getAxisConfiguration().getServices();
+// req.getSession().setAttribute(Constants.SERVICE_MAP, services);
+// req.getSession().setAttribute(Constants.ERROR_SERVICE_MAP,
+// configContext.getAxisConfiguration().getFaulytServices());
+// res.sendRedirect(LIST_MULTIPLE_SERVICE_JSP_NAME);
}
/**
@@ -197,20 +198,22 @@
private void listAdminServices(HttpServletRequest req,
HttpServletResponse res)
throws IOException {
- HashMap services = configContext.getAxisConfiguration().getServices();
- req.getSession().setAttribute(Constants.SERVICE_MAP, services);
- req.getSession().setAttribute(Constants.ERROR_SERVICE_MAP,
- configContext.getAxisConfiguration().getFaultyServices());
- res.sendRedirect(LIST_SRVICES_JSP_NAME);
+ //todo fix me Deepal
+// HashMap services = configContext.getAxisConfiguration().getServices();
+// req.getSession().setAttribute(Constants.SERVICE_MAP, services);
+// req.getSession().setAttribute(Constants.ERROR_SERVICE_MAP,
+// configContext.getAxisConfiguration().getFaulytServices());
+// res.sendRedirect(LIST_SRVICES_JSP_NAME);
}
private void selectService(HttpServletRequest req,
HttpServletResponse res)
throws IOException {
- HashMap services = configContext.getAxisConfiguration().getServices();
- req.getSession().setAttribute(Constants.SERVICE_MAP, services);
- req.getSession().setAttribute(Constants.SELECT_SERVICE_TYPE, "VIEW");
- res.sendRedirect(SELECT_SERVICE_JSP_NAME);
+ //todo fix me Deepal
+// HashMap services = configContext.getAxisConfiguration().getServices();
+// req.getSession().setAttribute(Constants.SERVICE_MAP, services);
+// req.getSession().setAttribute(Constants.SELECT_SERVICE_TYPE, "VIEW");
+// res.sendRedirect(SELECT_SERVICE_JSP_NAME);
}
private void adminLogging(HttpServletRequest req, HttpServletResponse res) throws AdminAppException, IOException {
@@ -298,7 +301,7 @@
req.getSession().setAttribute(Constants.OPEARTION_MAP,
configContext
.getAxisConfiguration()
- .getService(new QName(serviceName))
+ .getService(serviceName)
.getOperations());
req.getSession().setAttribute(Constants.ENGAGE_STATUS, null);
String operationName = req.getParameter("operation");
@@ -306,7 +309,7 @@
try {
OperationDescription od =
configContext.getAxisConfiguration().getService(
- new QName(serviceName))
+ serviceName)
.getOperation(new QName(operationName));
od.engageModule(
configContext.getAxisConfiguration().getModule(
@@ -326,34 +329,35 @@
private void engageModulesToService(HttpServletRequest req,
HttpServletResponse res)
throws IOException {
- HashMap modules =
- ((AxisConfigurationImpl) configContext.getAxisConfiguration()).getModules();
- req.getSession().setAttribute(Constants.MODULE_MAP, modules);
- HashMap services = configContext.getAxisConfiguration().getServices();
- req.getSession().setAttribute(Constants.SERVICE_MAP, services);
- String moduleName = req.getParameter("modules");
- req.getSession().setAttribute(Constants.ENGAGE_STATUS, null);
- req.getSession().setAttribute("modules", null);
- String serviceName = req.getParameter("service");
- req.getSession().setAttribute(Constants.ENGAGE_STATUS, null);
- if (serviceName != null && moduleName != null) {
- try {
-
- configContext.getAxisConfiguration().getService(
- new QName(serviceName))
- .engageModule(
- configContext.getAxisConfiguration().getModule(
- new QName(moduleName)),configContext.getAxisConfiguration());
- req.getSession().setAttribute(Constants.ENGAGE_STATUS,
- moduleName +
- " module engaged to the service Successfully");
- } catch (AxisFault axisFault) {
- req.getSession().setAttribute(Constants.ENGAGE_STATUS,
- axisFault.getMessage());
- }
- }
- req.getSession().setAttribute("service", null);
- res.sendRedirect(ENGAGING_MODULE_TO_SERVICE_JSP_NAME);
+ //todo fix me Deepal
+// HashMap modules =
+// ((AxisConfigurationImpl) configContext.getAxisConfiguration()).getModules();
+// req.getSession().setAttribute(Constants.MODULE_MAP, modules);
+// HashMap services = configContext.getAxisConfiguration().getServices();
+// req.getSession().setAttribute(Constants.SERVICE_MAP, services);
+// String moduleName = req.getParameter("modules");
+// req.getSession().setAttribute(Constants.ENGAGE_STATUS, null);
+// req.getSession().setAttribute("modules", null);
+// String serviceName = req.getParameter("service");
+// req.getSession().setAttribute(Constants.ENGAGE_STATUS, null);
+// if (serviceName != null && moduleName != null) {
+// try {
+//
+// configContext.getAxisConfiguration().getService(
+// new QName(serviceName))
+// .engageModule(
+// configContext.getAxisConfiguration().getModule(
+// new QName(moduleName)),configContext.getAxisConfiguration());
+// req.getSession().setAttribute(Constants.ENGAGE_STATUS,
+// moduleName +
+// " module engaged to the service Successfully");
+// } catch (AxisFault axisFault) {
+// req.getSession().setAttribute(Constants.ENGAGE_STATUS,
+// axisFault.getMessage());
+// }
+// }
+// req.getSession().setAttribute("service", null);
+// res.sendRedirect(ENGAGING_MODULE_TO_SERVICE_JSP_NAME);
}
private void listGloballyModules(HttpServletRequest req,
@@ -368,19 +372,21 @@
private void lsitServiceformodules(HttpServletRequest req,
HttpServletResponse res)
throws IOException {
- HashMap services = configContext.getAxisConfiguration().getServices();
- req.getSession().setAttribute(Constants.SERVICE_MAP, services);
- req.getSession().setAttribute(Constants.SELECT_SERVICE_TYPE, "MODULE");
- res.sendRedirect(SELECT_SERVICE_JSP_NAME);
+ //todo fix me Deepal
+// HashMap services = configContext.getAxisConfiguration().getServices();
+// req.getSession().setAttribute(Constants.SERVICE_MAP, services);
+// req.getSession().setAttribute(Constants.SELECT_SERVICE_TYPE, "MODULE");
+// res.sendRedirect(SELECT_SERVICE_JSP_NAME);
}
private void lsitServiceforParameterChanged(HttpServletRequest req,
HttpServletResponse res)
throws IOException {
- HashMap services = configContext.getAxisConfiguration().getServices();
- req.getSession().setAttribute(Constants.SERVICE_MAP, services);
- req.getSession().setAttribute(Constants.SELECT_SERVICE_TYPE, "SERVICE_PARAMETER");
- res.sendRedirect(SELECT_SERVICE_JSP_NAME);
+ //todo fix me Deepal
+// HashMap services = configContext.getAxisConfiguration().getServices();
+// req.getSession().setAttribute(Constants.SERVICE_MAP, services);
+// req.getSession().setAttribute(Constants.SELECT_SERVICE_TYPE, "SERVICE_PARAMETER");
+// res.sendRedirect(SELECT_SERVICE_JSP_NAME);
}
@@ -391,7 +397,7 @@
if(req.getParameter("changePara")!=null){
String serviceName = req.getParameter("service");
ServiceDescription service = configContext.getAxisConfiguration().
- getService(new QName(serviceName));
+ getService(serviceName);
if(service !=null){
ArrayList service_para = service.getParameters();
for (int i = 0; i < service_para.size(); i++) {
@@ -427,7 +433,7 @@
if (service != null) {
req.getSession().setAttribute(Constants.SERVICE,
configContext.getAxisConfiguration().getService(
- new QName(service)));
+ service));
}
}
res.sendRedirect(SERVICE_PARA_EDIT_JSP_NAME);
@@ -455,7 +461,7 @@
// }
// }
if(turnoff !=null){
- configContext.getAxisConfiguration().removeService(new QName(serviceName));
+ configContext.getAxisConfiguration().removeService(serviceName);
res.setContentType("text/css");
PrintWriter out_writer = new PrintWriter(out);
out_writer.println("Service removed from the system Successfully");
@@ -466,8 +472,9 @@
}
} else {
- HashMap services = configContext.getAxisConfiguration().getServices();
- req.getSession().setAttribute(Constants.SERVICE_MAP, services);
+ //todo fix me Deepal
+// HashMap services = configContext.getAxisConfiguration().getServices();
+// req.getSession().setAttribute(Constants.SERVICE_MAP, services);
}
res.sendRedirect(REMOVE_SERVICE_JSP_NAME);
}
@@ -487,7 +494,7 @@
if (service != null) {
req.getSession().setAttribute(Constants.SERVICE_HANDLERS,
configContext.getAxisConfiguration().getService(
- new QName(service)));
+ service));
}
res.sendRedirect(VIEW_SERVICE_HANDLERS_JSP_NAME);
}
@@ -522,26 +529,27 @@
throws IOException {
String serviceName = filePart.substring(filePart.lastIndexOf("/") + 1,
filePart.length());
- HashMap services = configContext.getAxisConfiguration().getServices();
- String wsdl = req.getParameter("wsdl");
- if ((services != null) && !services.isEmpty()) {
- Object serviceObj = services.get(new QName(serviceName));
- if (serviceObj != null) {
- if (wsdl != null) {
- res.setContentType("text/html");
- PrintWriter out_writer = new PrintWriter(out);
- ((ServiceDescription) serviceObj).printWSDL(out_writer,
- filePart);
- out.flush();
- out.close();
- wsdl = null;
- return;
- } else {
- req.getSession().setAttribute(Constants.SINGLE_SERVICE,
- serviceObj);
- }
- }
- }
+ //todo fix me Deepal
+// HashMap services = configContext.getAxisConfiguration().getServices();
+// String wsdl = req.getParameter("wsdl");
+// if ((services != null) && !services.isEmpty()) {
+// Object serviceObj = services.get(new QName(serviceName));
+// if (serviceObj != null) {
+// if (wsdl != null) {
+// res.setContentType("text/html");
+// PrintWriter out_writer = new PrintWriter(out);
+// ((ServiceDescription) serviceObj).printWSDL(out_writer,
+// filePart);
+// out.flush();
+// out.close();
+// wsdl = null;
+// return;
+// } else {
+// req.getSession().setAttribute(Constants.SINGLE_SERVICE,
+// serviceObj);
+// }
+// }
+// }
String URI = req.getRequestURI();
URI = URI.substring(0, URI.indexOf("services"));
res.sendRedirect(URI + LIST_SINGLE_SERVICE_JSP_NAME);
Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/util/Utils.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/util/Utils.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/util/Utils.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/util/Utils.java Tue Sep 13 20:56:02 2005
@@ -175,7 +175,7 @@
// the notations is ...../axis2/services/<ServiceGroupName>
serviceNameStr = serviceNameAndGroupStrings[0];
}
- ServiceDescription serviceDescription = registry.getService(new QName(serviceNameStr));
+ ServiceDescription serviceDescription = registry.getService(serviceNameStr);
if(serviceGroup != null && serviceDescription != null){
messageContext.setServiceGroupDescription(serviceGroup);
messageContext.setServiceDescription(serviceDescription);
Modified: webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/deployment/BuildERWithDeploymentTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/deployment/BuildERWithDeploymentTest.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/deployment/BuildERWithDeploymentTest.java (original)
+++ webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/deployment/BuildERWithDeploymentTest.java Tue Sep 13 20:56:02 2005
@@ -40,7 +40,7 @@
.getAxisConfiguration();
assertNotNull(er);
- ServiceDescription service = er.getService(new QName("service2"));
+ ServiceDescription service = er.getService("service2");
assertNotNull(service);
//commentd since there is no service based messgeReceivers
/*MessageReceiver provider = service.getMessageReceiver();
Modified: webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/description/RegistryTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/description/RegistryTest.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/description/RegistryTest.java (original)
+++ webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/description/RegistryTest.java Tue Sep 13 20:56:02 2005
@@ -64,7 +64,8 @@
}
public void testService() throws AxisFault {
- service.setParent(reg);
+ reg.addService(service);
+// service.setParent(reg);
testParameteInClude(service);
testFlowIncludeTest(service);
}
Modified: webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ModuleConfigTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ModuleConfigTest.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ModuleConfigTest.java (original)
+++ webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ModuleConfigTest.java Tue Sep 13 20:56:02 2005
@@ -8,6 +8,7 @@
import org.apache.axis2.description.OperationDescription;
import org.apache.axis2.description.Parameter;
import org.apache.axis2.description.ServiceDescription;
+import org.apache.axis2.AxisFault;
import javax.xml.namespace.QName;
import java.io.FileInputStream;
@@ -71,7 +72,8 @@
ServiceDescription service = new ServiceDescription();
- service.setParent(ar);
+ ar.addService(service);
+// service.setParent(ar);
InputStream in = new FileInputStream(repo + "/service1.xml");
ServiceBuilder sbuilder = new ServiceBuilder(in,null,service);
sbuilder.populateService();
@@ -94,6 +96,8 @@
fail("This can not fail with this DeploymentException " + e) ;
} catch (FileNotFoundException e) {
fail("This can not fail with this FileNotFoundException " + e) ;
+ } catch (AxisFault axisFault) {
+ fail("This can not fail with this AxisFault " + axisFault) ;
}
}
}
Modified: webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ModuleEngageTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ModuleEngageTest.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ModuleEngageTest.java (original)
+++ webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ModuleEngageTest.java Tue Sep 13 20:56:02 2005
@@ -50,7 +50,7 @@
ModuleDescription module = ac.getModule(new QName("module1"));
assertNotNull(module);
ac.engageModule(new QName("module1"));
- ServiceDescription service = ac.getService(new QName("service2"));
+ ServiceDescription service = ac.getService("service2");
assertNotNull(service);
OperationDescription moduleOperation = service.getOperation(
new QName("creatSeq"));
Modified: webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ParamterAddTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ParamterAddTest.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ParamterAddTest.java (original)
+++ webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ParamterAddTest.java Tue Sep 13 20:56:02 2005
@@ -45,7 +45,8 @@
reg.addParameter(para);
ServiceDescription service = new ServiceDescription(new QName("Service1"));
- service.setParent(reg);
+ reg.addService(service);
+// service.setParent(reg);
service.addParameter(para);
fail("This should fails with Parmter is locked can not overide");
} catch (AxisFault axisFault) {
@@ -78,7 +79,8 @@
reg.addParameter(para);
ServiceDescription service = new ServiceDescription(new QName("Service1"));
- service.setParent(reg);
+ reg.addService(service);
+ // service.setParent(reg);
OperationDescription opertion = new OperationDescription();
opertion.setParent(service);
@@ -99,7 +101,8 @@
para.setLocked(true);
ServiceDescription service = new ServiceDescription(new QName("Service1"));
- service.setParent(reg);
+// service.setParent(reg);
+ reg.addService(service);
service.addParameter(para);
OperationDescription opertion = new OperationDescription();
Modified: webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ParamterLocked.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ParamterLocked.java?rev=280756&r1=280755&r2=280756&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ParamterLocked.java (original)
+++ webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/engine/ParamterLocked.java Tue Sep 13 20:56:02 2005
@@ -7,6 +7,7 @@
import org.apache.axis2.deployment.ModuleBuilder;
import org.apache.axis2.description.ServiceDescription;
import org.apache.axis2.description.ModuleDescription;
+import org.apache.axis2.AxisFault;
import java.io.InputStream;
import java.io.FileInputStream;
@@ -50,7 +51,8 @@
try {
assertNotNull(ar);
ServiceDescription service = new ServiceDescription();
- service.setParent(ar);
+ ar.addService(service);
+// service.setParent(ar);
InputStream in = new FileInputStream(repo + "/service_overide_non_locked_para.xml");
ServiceBuilder sbuilder = new ServiceBuilder(in,null,service);
sbuilder.populateService();
@@ -60,6 +62,8 @@
fail("This can not fail with this FileNotFoundException " + e) ;
} catch (DeploymentException e) {
fail("This can not fail with this DeploymentException " + e) ;
+ } catch (AxisFault axisFault) {
+ fail("This can not fail with this AxisFault " + axisFault) ;
}
}
@@ -67,7 +71,8 @@
try {
assertNotNull(ar);
ServiceDescription service = new ServiceDescription();
- service.setParent(ar);
+ ar.addService(service);
+// service.setParent(ar);
InputStream in = new FileInputStream(repo + "/service_overide_locked_para.xml");
ServiceBuilder sbuilder = new ServiceBuilder(in,null,service);
sbuilder.populateService();
@@ -77,6 +82,8 @@
fail("This can not fail with this FileNotFoundException " + e) ;
} catch (DeploymentException e) {
+ } catch (AxisFault axisFault) {
+ fail("This can not fail with this AxisFault " + axisFault) ;
}
}
@@ -84,7 +91,8 @@
try {
assertNotNull(ar);
ServiceDescription service = new ServiceDescription();
- service.setParent(ar);
+ ar.addService(service);
+// service.setParent(ar);
InputStream in = new FileInputStream(repo + "/op_overide_global_para.xml");
ServiceBuilder sbuilder = new ServiceBuilder(in,null,service);
sbuilder.populateService();
@@ -94,14 +102,17 @@
fail("This can not fail with this FileNotFoundException " + e) ;
} catch (DeploymentException e) {
+ } catch (AxisFault axisFault) {
+ fail("This can not fail with this AxisFault " + axisFault) ;
}
- }
+ }
public void testOveride_Service_locked_Para_Operation(){
try {
assertNotNull(ar);
ServiceDescription service = new ServiceDescription();
- service.setParent(ar);
+ ar.addService(service);
+// service.setParent(ar);
InputStream in = new FileInputStream(repo + "/Op_overide_Service_para.xml");
ServiceBuilder sbuilder = new ServiceBuilder(in,null,service);
sbuilder.populateService();
@@ -110,8 +121,10 @@
fail("This can not fail with this FileNotFoundException " + e) ;
} catch (DeploymentException e) {
+ } catch (AxisFault axisFault) {
+ fail("This can not fail with this AxisFault " + axisFault) ;
}
- }
+ }
public void testOveride_Non_locked_Para_Module(){
try {