消息有效内容的类型为:String

时间:2013-05-02 11:58:00

标签: mule esb

我尝试在此页面的Flow示例中测试转换数据: “http://www.mulesoft.org/documentation/display/current/Transforming+Data+in+a+Flow

但我在浏览器上遇到此错误: 导致异常的组件是:DefaultJavaComponent {HellowFlow1.commponent.30555765}。消息有效内容的类型为:String

mule studio控制台中的确切消息是:

ERROR 2013-05-01 12:39:19,067 [[configureendpoint].connector.http.mule.default.receiver.04] org.mule.exception.DefaultMessagingExceptionStrategy:
********************************************************************************
Message : Failed to find entry point for component, the following resolvers tried but failed: [
CallableEntryPointResolver: Object "NameTransformer{this=4146a7, name='null', ignoreBadInput=false, returnClass=SimpleDataType{type=java.lang.Object, mimeType='*/*'}, sourceTypes=[]}" does not implement required interface "interface org.mule.api.lifecycle.Callable"
MethodHeaderPropertyEntryPointResolver: The required property "method" is not set on the event
AnnotatedEntryPointResolver: Component: NameTransformer{this=4146a7, name='null', ignoreBadInput=false, returnClass=SimpleDataType{type=java.lang.Object, mimeType='*/*'}, sourceTypes=[]} doesn't have any annotated methods, skipping.
ReflectionEntryPointResolver: Found too many possible methods on object "org.mule.examples.hello.NameTransformer" that accept parameters "{class java.lang.String}", Methods matched are "[public void org.mule.transformer.AbstractTransformer.setMimeType(java.lang.String) throws javax.activation.MimeTypeParseException, public final java.lang.Object org.mule.transformer.AbstractTransformer.transform(java.lang.Object) throws org.mule.api.transformer.TransformerException, public void org.mule.transformer.AbstractTransformer.setName(java.lang.String), public void org.mule.transformer.AbstractTransformer.setEncoding(java.lang.String)]"
]
Code : MULE_ERROR-321
--------------------------------------------------------------------------------
Exception stack is:
1. Failed to find entry point for component, the following resolvers tried but failed: [
CallableEntryPointResolver: Object "NameTransformer{this=4146a7, name='null', ignoreBadInput=false, returnClass=SimpleDataType{type=java.lang.Object, mimeType='*/*'}, sourceTypes=[]}" does not implement required interface "interface org.mule.api.lifecycle.Callable"
MethodHeaderPropertyEntryPointResolver: The required property "method" is not set on the event
AnnotatedEntryPointResolver: Component: NameTransformer{this=4146a7, name='null', ignoreBadInput=false, returnClass=SimpleDataType{type=java.lang.Object, mimeType='*/*'}, sourceTypes=[]} doesn't have any annotated methods, skipping.
ReflectionEntryPointResolver: Found too many possible methods on object "org.mule.examples.hello.NameTransformer" that accept parameters "{class java.lang.String}", Methods matched are "[public void org.mule.transformer.AbstractTransformer.setMimeType(java.lang.String) throws javax.activation.MimeTypeParseException, public final java.lang.Object org.mule.transformer.AbstractTransformer.transform(java.lang.Object) throws org.mule.api.transformer.TransformerException, public void org.mule.transformer.AbstractTransformer.setName(java.lang.String), public void org.mule.transformer.AbstractTransformer.setEncoding(java.lang.String)]"
] (org.mule.model.resolvers.EntryPointNotFoundException)
org.mule.model.resolvers.DefaultEntryPointResolverSet:52 (http://www.mulesoft.org/docs/site/cur...)
--------------------------------------------------------------------------------
Root Exception stack trace:
org.mule.model.resolvers.EntryPointNotFoundException: Failed to find entry point for component, the following resolvers tried but failed: [
CallableEntryPointResolver: Object "NameTransformer{this=4146a7, name='null', ignoreBadInput=false, returnClass=SimpleDataType{type=java.lang.Object, mimeType='*/*'}, sourceTypes=[]}" does not implement required interface "interface org.mule.api.lifecycle.Callable"
MethodHeaderPropertyEntryPointResolver: The required property "method" is not set on the event
AnnotatedEntryPointResolver: Component: NameTransformer{this=4146a7, name='null', ignoreBadInput=false, returnClass=SimpleDataType{type=java.lang.Object, mimeType='*/*'}, sourceTypes=[]} doesn't have any annotated methods, skipping.
ReflectionEntryPointResolver: Found too many possible methods on object "org.mule.examples.hello.NameTransformer" that accept parameters "{class java.lang.String}", Methods matched are "[public void org.mule.transformer.AbstractTransformer.setMimeType(java.lang.String) throws javax.activation.MimeTypeParseException, public final java.lang.Object org.mule.transformer.AbstractTransformer.transform(java.lang.Object) throws org.mule.api.transformer.TransformerException, public void org.mule.transformer.AbstractTransformer.setName(java.lang.String), public void org.mule.transformer.AbstractTransformer.setEncoding(java.lang.String)]"
]
at org.mule.model.resolvers.DefaultEntryPointResolverSet.invoke(DefaultEntryPointResolverSet.java:52)
at org.mule.component.DefaultComponentLifecycleAdapter.invoke(DefaultComponentLifecycleAdapter.java:343)
at org.mule.component.AbstractJavaComponent.invokeComponentInstance(AbstractJavaComponent.java:86)
+ 3 more (set debug level logging or '-Dmule.verbose.exceptions=true' for everything) 

如果有可能帮我解决它。

1 个答案:

答案 0 :(得分:2)

你没有显示你的XML配置所以我不得不根据我看到的异常进行猜测:我敢打赌你错误地使用了Java 组件而不是Java 配置org.mule.examples.hello.NameTransformer时的变压器