2012-05-22 65 views
0

我正在嘗試在IBM_LINK上運行示例HelloWorld SCA應用程序教程(OASIS 1.1)。我正在使用Rational Application Developer V8.5和WebSphere Application Server V8.5。在WAS 8.5上運行SCA示例應用程序時遇到困難

在部署應用程序時,發佈失敗並出現以下錯誤。

Publishing failed 
/scaHelloWorld > META-INF/sca-contribution.xml 
Project scaHelloWorld.jar was successfully imported in the server 
BLA scaHelloWorld has been successfully created 
An error occurred while adding Composition Unit HelloWorldComposite 
Rolling back a failed publish 
BLA scaHelloWorld has been successfully deleted 
Asset scaHelloWorld.jar was successfully deleted 

WebSphere Application Server的日誌

[5/20/12 17:18:45:860 EST] 00000047 ComponentBuil E Component type service not found for component service (missing @Remotable annotation?): Component = HelloWorldComponent Service = service 

配置

Facet Configuration 
    OASIS SCA 1.1 for WebSphere Application Server 8.5 

接口

HelloService的

package helloworld; 

import org.oasisopen.sca.annotation.Remotable; 

@Remotable 
public interface HelloService { 

    public String sayHello(String name); 

} 

HelloServiceImpl

package helloworld; 

import org.oasisopen.sca.annotation.Service; 

@Service(value = { HelloService.class }) 
public class HelloServiceImpl { 

    public String sayHello(String name) { 
     return "Hello, " + name + "!"; 
    } 

} 

創建一個複合和分量 - link

我部署應用程序的那一刻,它就會失敗。

可能是什麼原因?任何指針將真正理解

編輯

有一個錯字的錯誤,我沒有給一個適當的服務器名稱,它應該是「HelloService的」,現在這個錯誤已經

[5/20/12 17:18:45:860 EST] 00000047 ComponentBuil E Component type service not found for component service (missing @Remotable annotation?): Component = HelloWorldComponent Service = service 

現在我得到這個錯誤,同時啓動服務器

00000020 FfdcProvider I FFDC provider error 
           java.lang.NoClassDefFoundError: org.apache.tuscany.sca.Node 
    at java.lang.Class.getDeclaredFieldsImpl(Native Method) 
    at java.lang.Class.getDeclaredFields(Class.java:546) 
    at com.ibm.ffdc.util.formatting.Introspector$1.run(Introspector.java:138) 
    at com.ibm.ffdc.util.formatting.Introspector$1.run(Introspector.java:136) 
    at java.security.AccessController.doPrivileged(AccessController.java:254) 
    at com.ibm.ffdc.util.formatting.Introspector.getDeclaredFields(Introspector.java:135) 
    at com.ibm.ffdc.util.formatting.Introspector.formatTo(Introspector.java:94) 
    at com.ibm.ffdc.util.provider.IncidentStream$2.writeTo(IncidentStream.java:194) 
    at com.ibm.ffdc.util.provider.IncidentStream.write(IncidentStream.java:198) 
    at com.ibm.ffdc.util.provider.IncidentStream.write(IncidentStream.java:129) 
    at com.ibm.ffdc.util.formatting.Introspector.formatTo(Introspector.java:109) 
    at com.ibm.ffdc.util.provider.IncidentStream$2.writeTo(IncidentStream.java:194) 
    at com.ibm.ffdc.util.provider.IncidentStream.write(IncidentStream.java:198) 
    at com.ibm.ffdc.util.provider.IncidentStream.write(IncidentStream.java:129) 
    at com.ibm.ws.ffdc.impl.DMAdapter.formatTo(DMAdapter.java:88) 
    at com.ibm.ffdc.util.provider.IncidentLogger.writeIncidentTo(IncidentLogger.java:63) 
    at com.ibm.ws.ffdc.impl.FfdcProvider.logIncident(FfdcProvider.java:205) 
    at com.ibm.ws.ffdc.impl.FfdcProvider.logIncident(FfdcProvider.java:136) 
    at com.ibm.ffdc.util.provider.FfdcProvider.log(FfdcProvider.java:251) 
    at com.ibm.ws.ffdc.impl.FfdcProvider.log(FfdcProvider.java:149) 
    at com.ibm.ffdc.util.provider.IncidentEntry.log(IncidentEntry.java:105) 
    at com.ibm.ffdc.util.provider.Ffdc.log(Ffdc.java:94) 
    at com.ibm.ws.ffdc.FFDCFilter.processException(FFDCFilter.java:114) 
    at com.ibm.ws.soa.sca.admin.oasis.runtime.tuscany.SCATuscanyOasisRuntimeHandlerImpl.stopModule(SCATuscanyOasisRuntimeHandlerImpl.java:233) 
    at com.ibm.ws.soa.sca.admin.runtime.impl.SCARuntimeImpl.stop(SCARuntimeImpl.java:542) 
    at com.ibm.ws.soa.sca.admin.runtime.impl.SCARuntimeImpl.stop(SCARuntimeImpl.java:639) 
    at com.ibm.ws.soa.sca.admin.runtime.impl.SCARuntimeImpl.start(SCARuntimeImpl.java:622) 
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:445) 
    at com.ibm.ws.runtime.component.CompositionUnitImpl.start(CompositionUnitImpl.java:123) 
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:388) 
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500(CompositionUnitMgrImpl.java:116) 
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(CompositionUnitMgrImpl.java:663) 
    at com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManagerImpl.java:5323) 
    at com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(ContextManagerImpl.java:5539) 
    at com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityContext.java:255) 
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:677) 
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:621) 
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60) 
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) 
    at java.lang.reflect.Method.invoke(Method.java:611) 
    at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) 
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60) 
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) 
    at java.lang.reflect.Method.invoke(Method.java:611) 
    at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) 
    at javax.management.modelmbean.RequiredModelMBean.invokeMethod(RequiredModelMBean.java:1085) 
    at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.java:966) 
    at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:848) 
    at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) 
    at com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl.java:1335) 
    at com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:118) 
    at com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl.java:1228) 
    at com.ibm.ws.management.bla.runtime.ControlOperationHelper.execControlOpViaRuntimeMBean(ControlOperationHelper.java:1082) 
    at com.ibm.ws.management.bla.runtime.ControlOperationHelper.execControlOpOnLocalServer(ControlOperationHelper.java:536) 
    at com.ibm.wsspi.management.bla.runtime.CompUnitControlOpDispatcher.dispatchCompUnitControlOpToTarget(CompUnitControlOpDispatcher.java:285) 
    at com.ibm.wsspi.management.bla.runtime.CompUnitControlOpDispatcher.dispatch(CompUnitControlOpDispatcher.java:210) 
    at com.ibm.ws.management.bla.steps.StepStartBLA.execute(StepStartBLA.java:157) 
    at com.ibm.wsspi.management.bla.op.compound.Phase.execute(Phase.java:151) 
    at com.ibm.wsspi.management.bla.op.compound.CompoundOperation._doPhaseExecute(CompoundOperation.java:102) 
    at com.ibm.wsspi.management.bla.op.compound.CompoundOperation.doExecute(CompoundOperation.java:85) 
    at com.ibm.wsspi.management.bla.op.Operation.execute(Operation.java:158) 
    at com.ibm.wsspi.management.bla.op.compound.CompoundOperation.execute(CompoundOperation.java:68) 
    at com.ibm.ws.management.bla.commands.ADTCommand$OperationScheduler.run(ADTCommand.java:616) 
    at java.lang.Thread.run(Thread.java:769) 
Caused by: java.lang.ClassNotFoundException: org.apache.tuscany.sca.Node 
    at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:506) 
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:422) 
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:410) 
    at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107) 
    at java.lang.ClassLoader.loadClass(ClassLoader.java:627) 
    ... 66 more 

回答

相關問題