# EmailReader simply not working

**URL:** https://forum.cloverdx.com/t/emailreader-simply-not-working/2153
**Category:** CloverDX Platform
**Created:** [January 10, 2024, 4:17pm UTC](https://forum.cloverdx.com/t/emailreader-simply-not-working/2153 "2024-01-10T16:17:21Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Martin\_Thomas](https://avatars.discourse-cdn.com/v4/letter/m/8dc957/32.png) [@Martin\_Thomas](https://forum.cloverdx.com/u/Martin_Thomas)
#### Post date: [January 10, 2024, 4:17pm UTC](https://forum.cloverdx.com/t/emailreader-simply-not-working/2153/1 "2024-01-10T16:17:21Z")

</div>

Hi, I’m quite new to CloverDX and simply try to use an EmailReader but it doesn’t work.

I used the [EmailReader | CloverDX 6.3.0 Documentation](https://doc.cloverdx.com/latest/designer/emailreader.html#id%5Femailreader%5Fexample%5F02) to create the job on a 6.2.0.14 Designer.

The job kind of starts but finishes with an error I just don’t understand.

17:14:36,450 INFO [WatchDog\_80] ---------------------------------------------------------------------------------

17:14:36,450 INFO [WatchDog\_80] EmailReader EMAIL\_READER RUNNING

17:14:36,450 INFO [WatchDog\_80] (alloc:0MB, cpu:0%) Out:0 0 0 0 0

17:14:36,450 INFO [WatchDog\_80] FlatFileWriter FLAT\_FILE\_WRITER RUNNING

17:14:36,450 INFO [WatchDog\_80] (alloc:0MB, cpu:0%) In:0 0 0 0 0

17:14:36,450 INFO [WatchDog\_80] ---------------------------------\*\* End of Log \*\*--------------------------------

17:14:38,403 ERROR [WatchDog\_80] Component [EmailReader:EMAIL\_READER] finished with status ERROR. (Out1: 0 recs)

Component [EMAIL\_READER:EmailReader] - Component pre-execute initialization failed.

javax.mail.MessagingException: Connection dropped by server?;

nested exception is:

java.io.IOException: Connection dropped by server?

17:14:38,403 ERROR [WatchDog\_80] Error details:

org.jetel.exception.JetelRuntimeException: Component [EmailReader:EMAIL\_READER] finished with status ERROR. (Out1: 0 recs)

at org.jetel.graph.Node.createNodeException(Node.java:673)

at org.jetel.graph.Node.run(Node.java:638)

at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)

at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)

at java.base/java.lang.Thread.run(Thread.java:834)

Caused by: org.jetel.exception.ComponentNotReadyException: Component [EMAIL\_READER:EmailReader] - Component pre-execute initialization failed.

at org.jetel.graph.Node.run(Node.java:573)

… 3 more

Caused by: org.jetel.exception.ComponentNotReadyException: javax.mail.MessagingException: Connection dropped by server?;

nested exception is:

java.io.IOException: Connection dropped by server?

at com.opensys.cloveretl.tools.g.preExecute(Main:145)

at com.opensys.cloveretl.component.EmailReader.preExecute(Main:434)

at org.jetel.graph.Node.run(Node.java:571)

… 3 more

Caused by: javax.mail.MessagingException: Connection dropped by server?;

nested exception is:

java.io.IOException: Connection dropped by server?

at com.sun.mail.imap.IMAPStore.protocolConnect(IMAPStore.java:742)

at javax.mail.Service.connect(Service.java:366)

at javax.mail.Service.connect(Service.java:246)

at javax.mail.Service.connect(Service.java:267)

at com.opensys.cloveretl.tools.g.gz(Main:209)

at com.opensys.cloveretl.tools.g.preExecute(Main:143)

… 5 more

Caused by: java.io.IOException: Connection dropped by server?

at com.sun.mail.iap.ResponseInputStream.readResponse(ResponseInputStream.java:119)

at com.sun.mail.iap.Response.(Response.java:133)

at com.sun.mail.imap.protocol.IMAPResponse.(IMAPResponse.java:60)

at com.sun.mail.imap.protocol.IMAPProtocol.readResponse(IMAPProtocol.java:412)

at com.sun.mail.iap.Protocol.(Protocol.java:141)

at com.sun.mail.imap.protocol.IMAPProtocol.(IMAPProtocol.java:131)

at com.sun.mail.imap.IMAPStore.newIMAPProtocol(IMAPStore.java:763)

at com.sun.mail.imap.IMAPStore.protocolConnect(IMAPStore.java:698)

… 10 more

 ![](https://canada1.discourse-cdn.com/flex007/uploads/cloverdx1/original/1X/670f21fd682468e5c0b432b7897891cb0a980c7e.png)

Thank you for your input!

Best

Martin

---

<div class="post-metadata">

### Author: ![Vladimir\_Barton](https://yyz1.discourse-cdn.com/flex007/user_avatar/forum.cloverdx.com/vladimir_barton/32/167_2.png) [@Vladimir\_Barton](https://forum.cloverdx.com/u/Vladimir_Barton)
#### Post date: [January 15, 2024, 1:27pm UTC](https://forum.cloverdx.com/t/emailreader-simply-not-working/2153/2 "2024-01-15T13:27:30Z")

</div>

Hi Martin,

The error message indicates that the server (Microsoft Office Outlook IMAP Server in this case) dropped the connection from the client (CloverDX). I dare to presume it was because you tried to connect by using SFA (single-factor authentication, i.e. username and password) which is not something Microsoft allows by default. As a matter of fact, SFA might already represent a deprecated option in the Microsoft cloud environment.

A recommended way to go here would be to create a valid OAuth2 connection (MFA - multi-factor authentication) to the Microsoft IMAP server (as described here: [https://doc.cloverdx.com/latest/designer/oauth2-connections.html](https://doc.cloverdx.com/latest/designer/oauth2-connections.html)) and use that connection in the EmailReader component (“OAuth2 connection” property instead of “User Name” and “Password”).

If you stumble upon any issues while establishing a valid OAuth2 connection to Microsoft I’d suggest logging a ticket to CloverDX product support to get additional assistance.

With regards,

-Vladi
