Skip to content
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

Create the "Sent" IMAP folder if not exists #296

Closed
SamuelHassine opened this issue Sep 25, 2023 · 0 comments · Fixed by #299
Closed

Create the "Sent" IMAP folder if not exists #296

SamuelHassine opened this issue Sep 25, 2023 · 0 comments · Fixed by #299
Assignees
Labels
bug use for describing something not working as expected solved The issue has been solved
Milestone

Comments

@SamuelHassine
Copy link
Member

Description

When instantiating our cloud environment, the mailbox is created and empty.

Currently, we need to manually connect to the webmail 1 time to avoid this:

2023-09-25 15:54:30.042 | openex				2023-09-25 13:54:30.042 ERROR 7 --- [   scheduling-1] o.s.s.s.TaskUtils$LoggingErrorHandler    : Unexpected error occurred in scheduled task |  
-- | -- | --
  |   |   | 2023-09-25 15:54:20.033 | openex |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at java.base/java.lang.Thread.run(Thread.java:833) ~[na:na] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[na:na] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[na:na] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) ~[na:na] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at java.base/java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) ~[na:na] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[na:na] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54) ~[spring-context-5.3.18.jar!/:5.3.18] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at org.springframework.scheduling.support.ScheduledMethodRunnable.run(ScheduledMethodRunnable.java:84) ~[spring-context-5.3.18.jar!/:5.3.18] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at java.base/java.lang.reflect.Method.invoke(Method.java:577) ~[na:na] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104) ~[na:na] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at io.openex.injects.email.service.ImapService.connectionListener(ImapService.java:297) ~[classes!/:3.2.2-SNAPSHOT] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at io.openex.injects.email.service.ImapService.syncFolders(ImapService.java:280) ~[classes!/:3.2.2-SNAPSHOT] |  
2x |   |   | 2023-09-25 15:54:20.033 | openex					at com.sun.mail.imap.IMAPFolder.open(IMAPFolder.java:1044) ~[jakarta.mail-1.6.7.jar!/:1.6.7] |  
  |   |   | 2023-09-25 15:54:20.033 | openex					at com.sun.mail.imap.IMAPFolder.checkExists(IMAPFolder.java:431) ~[jakarta.mail-1.6.7.jar!/:1.6.7] |  
  |   |   | 2023-09-25 15:54:20.033 | openex				javax.mail.FolderNotFoundException: Sent not found

We need to create the "Sent" email folder on-the-fly if not found.

@SamuelHassine SamuelHassine added the bug use for describing something not working as expected label Sep 25, 2023
@guillaumejparis guillaumejparis self-assigned this Sep 26, 2023
guillaumejparis added a commit that referenced this issue Oct 2, 2023
* [backend] Create Sent folder if not exists (#296)

* [backend] Subscribe to new created folder to display it

---------

Co-authored-by: Romuald Lemesle <romuald.lemesle@filigran.io>
@guillaumejparis guillaumejparis linked a pull request Oct 3, 2023 that will close this issue
@guillaumejparis guillaumejparis added the solved The issue has been solved label Oct 3, 2023
@RomuDeuxfois RomuDeuxfois added this to the Release 3.3.0 milestone Oct 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug use for describing something not working as expected solved The issue has been solved
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants