Hi Kiren
On 28/03/12 10:33, Kiren Pillay wrote:
Hi Sergey!

With your code I'm getting 13 ms average on my Tomcat server and  34ms on
Jetty maven plugin (I was actually expecting the opposite).

Against the String response url I'm getting 4ms on Tomcat  and 5ms on Jetty.

I think now we're getting down to the level of differences in the quality
of our hardware, I've got an intel I5  (M 430  @ 2.27GHz) laptop with
plenty of RAM, you probably have a better machine. I'm running Java 7
update 3 on a linux 64bit Ubuntu 11.10  machine.

I have I7 with few processors and plenty of memory, so that can explain some difference. Java6 & Ubuntu 11.04. Please try CXF 2.5.3-SNAPSHOT, that might help with saving few milliseconds too plus in case of JAXB - save on the pretty-printing 'expenses' which you already verified.

What I think is that the server runtime is performing pretty well, the client runtimes have different qualities though and that can affect the performance measurements...

Wonder how would JIXB perform :-)

Cheers, Sergey

Regards
Kiren

On Tue, Mar 27, 2012 at 11:04 PM, Sergey Beryozkin<[email protected]>wrote:

Hi Kiren

On 27/03/12 13:09, Kiren Pillay wrote:

Hi Sergey,

Attached is a war file against which I am testing my client.

great, thanks


  The test URLS
are given below together with the Jamon stats for a 1000 hits.


1. Large response (27k)

url="http://localhost:8080/**RestTest/rest/test/long/27000<http://localhost:8080/RestTest/rest/test/long/27000>
"**;
JAMon Label=myCodeTimer, Units=ms.: (Hits=1000.0, Avg=7.77, Total=7770.0,
Min=4.0
tps:128.5512276642242

2. Small response

url="http://localhost:8080/**RestTest/rest/test/short<http://localhost:8080/RestTest/rest/test/short>
";
JAMon Label=myCodeTimer, Units=ms.: (Hits=1000.0, Avg=5.454, Total=5454.0,
Min=3.0, Max=37.0
tps:183.0831197363603

3. Dummy Response using the JAXB schema

url="http://localhost:8080/**RestTest/rest/test/xml<http://localhost:8080/RestTest/rest/test/xml>
";
JAMon Label=myCodeTimer, Units=ms.: (Hits=1000.0, Avg=15.381,
Total=15381.0,
Min=9.0, Max=542.0,
tps:64.96037417175522


With the following code:

WebClient wc = WebClient.create("http://**localhost:8080/RestTest/rest/**
test/xml<http://localhost:8080/RestTest/rest/test/xml>");
        wc.accept("text/xml");
        // warm up a bit
        for (int i = 0; i<  50; i++) {
            wc.get();
        }

        long total = 0;
        for (int i = 0; i<  1000; i++) {
            long l1 = System.currentTimeMillis();
                wc.get(Document.class);
            long l2 = System.currentTimeMillis();

                total += l2-l1;
        }
        System.out.println("Average: " + total/1000);

I'm getting 10 millisecs average. Note I'm adding a Document reading just
to eliminate any optimizations with webClient.get() where no actual read is
done.

Running the same code against
http://localhost:8080/**RestTest/rest/test/long/27000<http://localhost:8080/RestTest/rest/test/long/27000>

(changing address, accept to text/plain, and wc.get(Document.class); to
wc.get(String.class);)

gives me 2 milliseconds average.


Can you try the same code please ?

Cheers, Sergey


  I've include our custom JAXB-enabled schema jar, the rest you can build
from
maven pom.xml.

http://cxf.547215.n5.nabble.**com/file/n5597650/**RestWarProject.tar.gz<http://cxf.547215.n5.nabble.com/file/n5597650/RestWarProject.tar.gz>
RestWarProject.tar.gz

Custom JAXB schema file:

http://cxf.547215.n5.nabble.**com/file/n5597650/pams-core-**
xsd-server-1.3.0_ba_nemo-**SNAPSHOT.jar<http://cxf.547215.n5.nabble.com/file/n5597650/pams-core-xsd-server-1.3.0_ba_nemo-SNAPSHOT.jar>
pams-core-xsd-server-1.3.0_ba_**nemo-SNAPSHOT.jar


Regards
Kiren





--
View this message in context: http://cxf.547215.n5.nabble.**
com/CXF-Test-client-for-JAXB-**load-testing-**tp5597650p5597650.html<http://cxf.547215.n5.nabble.com/CXF-Test-client-for-JAXB-load-testing-tp5597650p5597650.html>
Sent from the cxf-user mailing list archive at Nabble.com.



--
Sergey Beryozkin

Talend Community Coders
http://coders.talend.com/

Blog: http://sberyozkin.blogspot.com


Reply via email to