<br><br><div class="gmail_quote">On Tue, May 25, 2010 at 1:19 AM, Piotr Sikora <span dir="ltr">&lt;<a href="mailto:piotr.sikora@frickle.com">piotr.sikora@frickle.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

<div class="im">Hi,<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I&#39;m trying to store requests that comes in (let&#39;s call it request A), and I<br>
want to be able to &quot;replay&quot; them later, when another query comes in with a<br>
specific argument (request B).<br>
I can store the request to memcache, and get it back later. But I can&#39;t<br>
figure out how to recreate a query from a string.<br>
</blockquote>
<br></div>
You can do this with both: ngx_echo [1] and ngx_lua [2].<br>
<br>
You should also read agentzh&#39;s post on that matter [3],<br>
it will answer pretty much all of your questions ;)<br>
<br>
[1] <a href="http://wiki.nginx.org/NginxHttpEchoModule" target="_blank">http://wiki.nginx.org/NginxHttpEchoModule</a><br>
[2] <a href="http://github.com/chaoslawful/lua-nginx-module" target="_blank">http://github.com/chaoslawful/lua-nginx-module</a><br>
[3] <a href="http://agentzh.spaces.live.com/blog/cns!FF3A735632E41548!560.entry" target="_blank">http://agentzh.spaces.live.com/blog/cns!FF3A735632E41548!560.entry</a><div class="im"><br></div></blockquote><div><br></div>

<div>Thanks for the pointers, but it doesn&#39;t really answer my question. </div><div>Agentzh&#39;s post shows how to send the content fetched from memcached to the downstream.</div><div><br></div><div>I&#39;m trying to send that content representing a request, to an upstream. </div>

<div>Basically &quot;replaying&quot; a query stored as a string, exactly as if it was coming from an open socket.</div></div><div><br></div>Thank you,<div><br></div><div>Matthieu.</div><div><br>-- <br>Matthieu Tourne<br>

</div>