You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by "BOLB (Bohdan L Bodnar)" <BO...@panduit.com> on 2014/09/17 00:04:44 UTC
questions about reading/writing files in jmeter
I've a problem I'm hoping someone much more knowledgeable than I can address and assist me. Here's the background:
I'm running several operations that return alpha-numeric tokens. I'm using jmeter 2.9 (no time to upgrade). These tokens are extracted with the usual regular expression tools in jmeter and are later used for other operations. Currently, I'm storing them in variables for reuse. This approach works very well, but doesn't scale. I'm looking at another approach; viz.,
1. The tokens are extracted and stored in a .csv file. I'm using the "Flexible File Writer" (FFW).
2. They are later read by the "CSV Data Set Config" block.
The writing is done correctly but the reading sends an EOF unless the writer is disabled; in that case the CSV Data Set Config block works as intended. This suggests to me that the FFW isn't closing the file it's writing to.
So, the assistance I'm asking for is: please show me how to close the file the FFW is writing to (e.g., the equivalent of a "fclose()" in C/C++). Idiot-proof directions would be best, as I'm not that knowledgeable about jmeter.
Best regards,
Bohdan Bodnar
Re: questions about reading/writing files in jmeter
Posted by Deepak Shetty <sh...@gmail.com>.
While not a direct answer to your question you might consider the
alternative ..
http://theworkaholic.blogspot.com/2013/03/sharing-session-ids-across-threads.html
On Tue, Sep 16, 2014 at 3:04 PM, BOLB (Bohdan L Bodnar) <BO...@panduit.com>
wrote:
> I've a problem I'm hoping someone much more knowledgeable than I can
> address and assist me. Here's the background:
>
> I'm running several operations that return alpha-numeric tokens. I'm
> using jmeter 2.9 (no time to upgrade). These tokens are extracted with the
> usual regular expression tools in jmeter and are later used for other
> operations. Currently, I'm storing them in variables for reuse. This
> approach works very well, but doesn't scale. I'm looking at another
> approach; viz.,
>
>
> 1. The tokens are extracted and stored in a .csv file. I'm using
> the "Flexible File Writer" (FFW).
>
> 2. They are later read by the "CSV Data Set Config" block.
>
> The writing is done correctly but the reading sends an EOF unless the
> writer is disabled; in that case the CSV Data Set Config block works as
> intended. This suggests to me that the FFW isn't closing the file it's
> writing to.
>
> So, the assistance I'm asking for is: please show me how to close the
> file the FFW is writing to (e.g., the equivalent of a "fclose()" in
> C/C++). Idiot-proof directions would be best, as I'm not that
> knowledgeable about jmeter.
>
> Best regards,
>
> Bohdan Bodnar
>
>