Return-Path: Delivered-To: apmail-jakarta-jmeter-user-archive@www.apache.org Received: (qmail 39066 invoked from network); 30 Jun 2006 13:51:32 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 30 Jun 2006 13:51:32 -0000 Received: (qmail 4890 invoked by uid 500); 30 Jun 2006 13:51:30 -0000 Delivered-To: apmail-jakarta-jmeter-user-archive@jakarta.apache.org Received: (qmail 4757 invoked by uid 500); 30 Jun 2006 13:51:30 -0000 Mailing-List: contact jmeter-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "JMeter Users List" Reply-To: "JMeter Users List" Delivered-To: mailing list jmeter-user@jakarta.apache.org Received: (qmail 4733 invoked by uid 99); 30 Jun 2006 13:51:29 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 30 Jun 2006 06:51:29 -0700 X-ASF-Spam-Status: No, hits=2.3 required=10.0 tests=DNS_FROM_RFC_ABUSE,DNS_FROM_RFC_WHOIS,HTML_10_20,HTML_MESSAGE X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [68.142.207.83] (HELO web31903.mail.mud.yahoo.com) (68.142.207.83) by apache.org (qpsmtpd/0.29) with SMTP; Fri, 30 Jun 2006 06:51:29 -0700 Received: (qmail 23328 invoked by uid 60001); 30 Jun 2006 13:51:08 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:Received:Date:From:Subject:To:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=hg+aAxY8g8kxCvJMXLT/8Kid9nTQWZRZ4IC9Ib8mNocCUsjqQ0qv2T8YehWv10XIqQfTszUenGP0N7SEtKOejNGt7RxAilqGIL9oQLd0rO0fuu/O/6SzF+RoxiKtH25WIwFXXbbqMmQiIqpa4cC/jAE7qakBaotoEqxg1a0OC8A= ; Message-ID: <20060630135108.23326.qmail@web31903.mail.mud.yahoo.com> Received: from [148.87.1.170] by web31903.mail.mud.yahoo.com via HTTP; Fri, 30 Jun 2006 06:51:08 PDT Date: Fri, 30 Jun 2006 06:51:08 -0700 (PDT) From: Vikrant Sharma Subject: Re: How can we pass objects created in one beanshell sampler to another To: JMeter Users List In-Reply-To: <44A547D0.FA6A.0006.0@bnm.org> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="0-1152398090-1151675468=:22566" Content-Transfer-Encoding: 8bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N --0-1152398090-1151675468=:22566 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Hi Vitalie, Thanks for the reply. When i try to store the object into a variable (in first beanshell) using vars.put("varname", "value"); method, it does not complain about anything. But when I get it (in second beanshell) using vars.get("varname") method and try to cast it, it throws error. Further when i dont cast it and try to print it. it just prints the name of that object as a normal String. SO I think when we set the object in the variable it is just set as a normal String and not as an object instance. For the second solution, yes i can serialize the object but as this is the performance script, storing and loading object's state will incur some more cost. Thanks & Regards Vikrant Vitalie Valache wrote: just some ideas.. - maybe you can declare a global variable assign the object value to it and use it by casting in the second beanshell, not sure if jmeter variable can store objects but why not! or - save object to a file using serialization if your object is supporting and load it from your second beanshell. -- DISCLAIMER: Any e-mail messages from the National Bank of Moldova are sent in good faith, but shall not be binding nor construed as constituting any obligation on the part of the Bank. The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. If you received this in error, please contact the sender and delete the material from any computer. --------------------------------------------------------------------- To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: jmeter-user-help@jakarta.apache.org --------------------------------- Yahoo! Messenger with Voice. Make PC-to-Phone Calls to the US (and 30+ countries) for 2�/min or less. --0-1152398090-1151675468=:22566--