Когда я попытался отправить почту в Gmail, я получил следующую ошибку. В глобальный коннектор gmail я добавляю fromAddress,replyToAddress и все....
********************************************************************************
WARN 2015-02-10 10:58:28,526 [[mailexample].connector.http.mule.default.receiver.02] org.mule.api.security.tls.TlsProperties: File tls-default.conf not found, using default configuration.
INFO 2015-02-10 10:58:31,354 [[mailexample].connector.http.mule.default.receiver.02] org.mule.api.security.tls.TlsPropertiesMapper: Defaulting mule.email.smtps trust store to client Key Store
WARN 2015-02-10 10:58:31,355 [[mailexample].connector.http.mule.default.receiver.02] org.mule.api.security.tls.TlsProperties: File tls-default.conf not found, using default configuration.
ERROR 2015-02-10 10:58:33,485 [[mailexample].connector.http.mule.default.receiver.02] org.mule.exception.DefaultMessagingExceptionStrategy:
********************************************************************************
Message : Unable to connect to mail transport.
Code : MULE_ERROR--2
--------------------------------------------------------------------------------
Exception stack is:
1. 534-5.7.14 <https://accounts.google.com/ContinueSignIn?sarp=1&scc=1&plt=AKgnsbuRg
534-5.7.14 yGa3WdTfxBAchlMvo6NtJgJK6JL823P9UTvFhfcpUfm5tgTi4Zzdsm1J9NfGCqjG4iAvCi
534-5.7.14 6BRop8ALCvZUrZ1sa9ICkR_u-WykguB7aGSc5jLH5mH1FGGlkusqWnqTyvE-AhRNcJo-PQ
534-5.7.14 rH1WuTiUITDEFdAlfy19PaiFDED6aos2shRxO4-jdEHzGGUTmgFXWUthbF5nSKBPq76Eb5
534-5.7.14 s5b7LbA> Please log in via your web browser and then try again.
534-5.7.14 Learn more at
534 5.7.14 https://support.google.com/mail/bin/answer.py?answer=78754 c17sm18040119pdl.6 - gsmtp
(javax.mail.AuthenticationFailedException)
com.sun.mail.smtp.SMTPTransport$Authenticator:648 (http://java.sun.com/j2ee/sdk_1.3/techdocs/api/javax/mail/AuthenticationFailedException.html)
2. Unable to connect to mail transport. (org.mule.api.endpoint.EndpointException)
org.mule.transport.email.SmtpMessageDispatcher:67 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/api/endpoint/EndpointException.html)
В браузере я получил следующую ошибку
Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=smtp://<emailaddress>%40gmail.com:<password>@smtp.gmail.com, connector=GmailSmtpConnector
{
name=smtpGmailConnector
lifecycle=start
this=103a0ec
numberOfConcurrentTransactedReceivers=4
createMultipleTransactedReceivers=true
connected=true
supportedProtocols=[smtp]
serviceOverrides=<none>
}
, name='endpoint.smtp.emailaddress.gmail.com', mep=ONE_WAY, properties={[email protected], subject=Test email message, fromAddress=emailaddress}, transactionConfig=Transaction{factory=null, action=INDIFFERENT, timeout=0}, deleteUnacceptedMessages=false, initialState=started, responseTimeout=10000, endpointEncoding=UTF-8, disableTransportTransformer=false}. Message payload is of type: MimeMessage
следующий мой поток
<smtp:gmail-connector name="emailConnector" />
<flow name="mailTestFlow1" doc:name="mailTestFlow1">
<http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8081" doc:name="HTTP"
path="sendMail"/>
<component doc:name="Java" class="Component1"/>
<smtp:outbound-endpoint host="smtp.gmail.com" port="587"
user="yourEmailAddress%40gmail.com" password="pass" to="[email protected]"
from="yourEmailAddress%40gmail.com" subject="Testing mule" responseTimeout="10000" connector-ref="gmail" doc:name="Send notification email"/>
</flow>
Теперь, какие изменения я должен сделать ??