java - Failed to invoke Method. Message payload is of type: String -


i have created mule connector using devkit, accepts string, when tried run mule application using connector , throuws "failed invoke myprocessor. message payload of type: string". should do?

enter image description here

exception stack is: 1. parameter username in method connect can't null because not @optional (org.mule.modules.duoasset.connection.unabletoacquireconnectionexception)   org.mule.modules.duoasset.connectivity.duoassetconnectorconnectionmanager:260 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/modules/duoasset/connection/unabletoacquireconnectionexception.html) 2. failed invoke myprocessor. message payload of type: string (org.mule.api.messagingexception)   org.mule.devkit.processor.devkitbasedmessageprocessor:128 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/api/messagingexception.html) -------------------------------------------------------------------------------- root exception stack trace: org.mule.modules.duoasset.connection.unabletoacquireconnectionexception: parameter username in method connect can't null because not @optional     @ org.mule.modules.duoasset.connectivity.duoassetconnectorconnectionmanager.getevaluatedconnectionkey(duoassetconnectorconnectionmanager.java:260)     @ org.mule.modules.duoasset.connectivity.duoassetconnectorconnectionmanager.getevaluatedconnectionkey(duoassetconnectorconnectionmanager.java:39)     @ org.mule.modules.duoasset.process.managedconnectionprocessinterceptor.execute(managedconnectionprocessinterceptor.java:58)     + 3 more (set debug level logging or '-dmule.verbose.exceptions=true' everything) ******************************************************************************** 

according stacktrace need pass in connection attributes on connector. in case "username". on connector config should add username attribute:

<duoasset:connector name="duoasset" username="myusername" password="my password" /> 

and on each global parameter or parameter in @connect method.

if connection parameters, can pass them on operation itself:

<duoasset:myprocessor content="#[payload]" username="myusername" password="my password" /> 

also if not need connection management can remove @connect , @disconnect methods etc.

see more on connection management here: http://www.mulesoft.org/documentation/display/current/implementing+connection+management


Comments

Popular posts from this blog

google api - Incomplete response from Gmail API threads.list -

Installing Android SQLite Asset Helper -

Qt Creator - Searching files with Locator including folder -