Uploaded image for project: 'James Server'
  1. James Server
  2. JAMES-2320

MailQueue element removal should be backed by a Task


    • Type: Improvement
    • Status: Reopened
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: master
    • Fix Version/s: None
    • Component/s: Queue, webadmin
    • Labels:


      DELETE /mailQueues/:name/messages/ ?sender ?name ?recipient 
      201 + taskId

      Should generate a Task.No status is required as it might be complicated to implement.

      You need to write related unit tests.

      A few indications:

      • MailQueueRoutes declares the /mailQueues webAdmin endpoints
      • You need to implement a Task* performing DELETE in a mailQueue
      • TaskManager is used to submit the task (and can be injected. Have a look to MailRepositoriesRoutes if you are looking for an example.
      • Use TaskIdDto::respond in order to send a valid response.
      • You need some additional tests in MailQueueRoutesTest :
        • Ensure that the status is 201, and that the Location header is well positionned.
        • Check the created task details
        • Await the end of the task, and check the effects.

      (Again, a look to MailRepositoriesRoutesTest::reprocessingOneTaskShould* tests can be helpful)

      If you need more details to implement this feature, we are willing to provide support. Don't hesitate to ask on https://gitter.im/apache/james-project. We are willing to provide guidance.




            • Assignee:
              BTellier Tellier Benoit
            • Votes:
              0 Vote for this issue
              3 Start watching this issue


              • Created: