I know that this mailing list is not meant for design, but if we already started...
I'm sorry, but I've to disagree. We're talking about client/server architecture, I'm a client and I want to send maximum load to the server. In one thread architecture it will look like that: Thread(loop) |- Send TCP/IP message (to server) | |- Wait for TCP/IP Ack message (from server) In an implementation like that, there will be a situation called 'window size = one', that means that the client can't send another message till it gets an ack message from the server (it can send just one message till the ack), and that reduces the load significantly (that's a fact), I don't want to wait for the Acks, I want to keep sending. by decoupling those processes I can also elaborate things, like I described in the previous mail: Thread1(loop) |- Send message A Thread2(loop) |- Wait for Ack (save a special field - f1, push in shared Q) Thread3(loop) |- Send message B sometimes in the future (according to field f1 - pop from shared Q) As you can see, I can't do it in one thread (I won't be able to send a second message A till the B message will be send - sometime in the future). I want to send as much messages A in a second, as I can. And now for the real problem, you wrote: "Variables are not shared across threads. JMeter simulates multiple independent users", That's okay, I want to simulate it myself. like the "User Defined Variables" in the Test Plan. Can you write something on how it is done (ValueReplacer...) Thanks a million P.S I can always use global queue, but... you know On Tue, 21 Sep 2004 11:16:29 -0400, "Michael Stover" <[EMAIL PROTECTED]> said: > That seems like exactly the sort of thing you'd do in one thread. An > initial request gets some data and a subsequent request uses it. How > else would you manage 100 threads doing this? > > -Mike > > On Tue, 2004-09-21 at 10:53, [EMAIL PROTECTED] wrote: > > Okay, so how can I do it? > > What I'm planing, is to use in one thread, a derived > > 'AbstractJavaSamplerClient' to get TCP/IP packet (a request) and to pars > > it. according to this request, another thread will send another request > > (let's say the ack part) - using other derived > > 'AbstractJavaSamplerClient' that will be under an 'IfController' (in the > > 'IfController' the user will "ask" if a specific value equals to > > something). > > I don't think it's wise to do both process in the same thread. > > > > Thanks again, especially for your quick answer. > > > > On Tue, 21 Sep 2004 09:50:01 -0400, "Michael Stover" > > <[EMAIL PROTECTED]> said: > > > Variables are not shared across threads. JMeter simulates multiple > > > independent users, so there hasn't been any need to shared data amongst > > > the threads during the test run. > > > > > > -Mike > > > > > > On Tue, 2004-09-21 at 09:27, [EMAIL PROTECTED] wrote: > > > > I want to save variables that were initialized in one thread, so they > > > > will be seen in other thread. > > > > There is an easy way to save variables in the thread's context: > > > > JMeterContext context = getThreadContext(); > > > > JMeterVariables vars = context.getVariables(); > > > > vars.put(.... > > > > > > > > But trying to save variables so they will be seen in all the threads is > > > > much harder, I looked at: PreCompiler.addNode(Object,HashTree) > > > > and in my code tried naively to write: > > > > JMeterContextService.getContext().getVariables().put("code", "value"); > > > > but this key was unvisible in other threads. I've noticed that there is > > > > some action doing with an instance of 'ValueReplacer' in the 'addNode' > > > > func, but still didn't figure to find out what to do. > > > > Tips will be most welcom > > > > > > > > Thanks. > > > -- > > > Michael Stover <[EMAIL PROTECTED]> > > > Apache Software Foundation > > > > > > > > > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > -- > Michael Stover <[EMAIL PROTECTED]> > Apache Software Foundation > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > -- [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]