You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jmeter.apache.org by "tolgagul (via GitHub)" <gi...@apache.org> on 2024/12/03 23:53:35 UTC
[I] Retrieving the Most Recent Emails in Mail Reader Sampler [jmeter]
tolgagul opened a new issue, #6384:
URL: https://github.com/apache/jmeter/issues/6384
### Expected behavior
The Mail Reader Sampler should retrieve the most recent n messages from the mailbox, regardless of the server's default ordering. Instead of fetching messages starting from the first received email, it should correctly fetch the last n messages by adjusting the indices in the getMessages method. This ensures that users can access the latest emails as needed.
### Actual behavior
The Mail Reader Sampler retrieves messages starting from the first received email by default. This behavior aligns with the typical IMAP server ordering, where messages are numbered sequentially from the earliest to the latest. As a result, the sampler fetches older messages instead of the most recent ones, which may not meet the intended requirement of retrieving the latest n messages.
### Steps to reproduce the problem
1. Configure the Mail Reader Sampler to connect to an IMAP mailbox.
2. Use the folder.getMessages(1, n) method to retrieve emails, specifying a value for n (e.g., n=5).
3. Ensure the mailbox contains more than n messages, with both old and new messages available.
4. Execute the sampler to fetch the emails.
5. Observe the retrieved messages and verify that they correspond to the oldest messages in the mailbox instead of the most recent ones.
### JMeter Version
5.6.3
### Java Version
openjdk version "21.0.1" 2023-10-17
### OS Version
_No response_
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Retrieving the Most Recent Emails in Mail Reader Sampler [jmeter]
Posted by "vlsi (via GitHub)" <gi...@apache.org>.
vlsi commented on issue #6384:
URL: https://github.com/apache/jmeter/issues/6384#issuecomment-2516856780
Frankly, I am not sure why users would expect "the recent" messages rather than "the oldest" ones.
In any case, we should not change the behaviour, as the existing scripts will start failing.
I think we could add a configuration parameter to let the users decide if they want the N recent or the N oldest messges.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Retrieving the Most Recent Emails in Mail Reader Sampler [jmeter]
Posted by "tolgagul (via GitHub)" <gi...@apache.org>.
tolgagul commented on issue #6384:
URL: https://github.com/apache/jmeter/issues/6384#issuecomment-2517534174
Thank you for the feedback! You're absolutely right; adding a configuration parameter to let users choose between the N recent or the N oldest messages makes the feature more flexible and user-friendly. I’ll make the necessary adjustments and update the PR accordingly. Thanks again for pointing this out!
This was actually a need we identified while testing our messaging systems. For example, I sent 100 messages to a mailbox, but the last message I sent had an attachment. When I wanted to measure the response time for fetching this particular message with the attachment, I couldn't. I had to write an additional script to handle this.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Retrieving the Most Recent Emails in Mail Reader Sampler [jmeter]
Posted by "GafoorA (via GitHub)" <gi...@apache.org>.
GafoorA commented on issue #6384:
URL: https://github.com/apache/jmeter/issues/6384#issuecomment-2522656988
Even iam facing this issue, its not fetching the latest mail, its getting the old emails..
how can we fix this ? @tolgagul
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org