-
Notifications
You must be signed in to change notification settings - Fork 40
fix(email-connector): fix for inbound email connector when an email cant be moved #4640
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(email-connector): fix for inbound email connector when an email cant be moved #4640
Conversation
c274706
to
adcd922
Compare
...rs/email/src/main/java/io/camunda/connector/email/client/jakarta/inbound/PollingManager.java
Fixed
Show fixed
Hide fixed
@mathias-vandaele What about avoiding this issue by requiring the folder to be present when starting the Connector? |
@sbuettner I'm not sure about this, it doesn't seem right to remove a feature just because one email provider doesn't allow folder creation at the root level. It should still be possible to create folders in Gmail if we prefix them with |
I am concerned that this feature is not working properly but if you think it’s worth it we can keep it. @mathias-vandaele Please make sure this is properly documented in our docs for this operation. |
Description
Some IMAP servers do not permit folder creation:
When the folder did not exist on Gmail, the scheduler malfunctioned due to an exception being thrown. To prevent this issue, we now mark the email as 'read' before attempting to move it, ensuring that it is not processed again, thereby improving the system's efficiency.
If an exception occurs because the folder could not be created, and we are reading only unseen emails, the connector is canceled with a RetryException. If we are reading all emails, the connector is canceled with a ConnectorException.
Related issues
closes #4367
Checklist
no milestone
label.