[Lift] Re: Jetty or Tomcat, Which web container is recommended to use to deploy the Lift app ?

2009-11-23 Thread monty chen
I am uging lift develop a  projectI, I want to deploy my project using
jetty instead of tomcat, so i test jetty 6.1.22.

my notebook: lenovo Y330(cpu: Core2 Duo p7350 2GHz, mem: 3G)
my os: debian lenny for amd64
jdk: Java(TM) SE Runtime Environment (build 1.6.0_17-b04)

step 1: download jetty 6.1.22 from  
http://dist.codehaus.org/jetty/jetty-6.1.22/jetty-6.1.22.zip

step 2: unzip jetty 6.1.22 in my home dir.

setp3: set environment var
export JAVA_OPTS=-Drun.mode=production -server -Xmx2048

setp3: run jetty (cd jetty-6.1.22/ ; java -jar start.jar  )

test 1: start -

test the Hello World Servlet  example  of jetty-6.1.22,
the example url: http://localhost:8080/hello/

mo...@den:~/jetty-6.1.22$ ab -n 1 -c 300 http://localhost:8080/hello/
This is ApacheBench, Version 2.3 $Revision: 655654 $
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/

Benchmarking localhost (be patient)
Completed 1000 requests
Completed 2000 requests
Completed 3000 requests
Completed 4000 requests
Completed 5000 requests
Completed 6000 requests
Completed 7000 requests
Completed 8000 requests
Completed 9000 requests
Completed 1 requests
Finished 1 requests


Server Software:Jetty(6.1.22)
Server Hostname:localhost
Server Port:8080

Document Path:  /hello/
Document Length:39 bytes

Concurrency Level:  300
Time taken for tests:   10.344 seconds
Complete requests:  1
Failed requests:0
Write errors:   0
Total transferred:  1060212 bytes
HTML transferred:   390078 bytes
Requests per second:966.72 [#/sec] (mean)
Time per request:   310.329 [ms] (mean)
Time per request:   1.034 [ms] (mean, across all concurrent
requests)
Transfer rate:  100.09 [Kbytes/sec] received

Connection Times (ms)
  min  mean[+/-sd] median   max
Connect:0   12 152.7  23000
Processing:   200  293  53.0266 566
Waiting:1   93  53.6 65 364
Total:206  305 159.12713251

Percentage of the requests served within a certain time (ms)
  50%271
  66%338
  75%345
  80%350
  90%359
  95%366
  98%378
  99%434
 100%   3251 (longest request)

===the test1 result is good!  =
Failed requests:0
Requests per second:966.72 [#/sec] (mean)

test 1: end 

test 2: start -
test the Request Dump JSP exmaple of jetty-6.1.22,
the example url: http://localhost:8080/snoop.jsp

mo...@den:~/jetty-6.1.22$ ab -n 50 -c 3 http://localhost:8080/snoop.jsp
This is ApacheBench, Version 2.3 $Revision: 655654 $
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/

Benchmarking localhost (be patient).done


Server Software:Jetty(6.1.22)
Server Hostname:localhost
Server Port:8080

Document Path:  /snoop.jsp
Document Length:2249 bytes

Concurrency Level:  3
Time taken for tests:   0.044 seconds
Complete requests:  50
Failed requests:23
   (Connect: 0, Receive: 0, Length: 23, Exceptions: 0)
Write errors:   0
Total transferred:  124547 bytes
HTML transferred:   114676 bytes
Requests per second:1132.76 [#/sec] (mean)
Time per request:   2.648 [ms] (mean)
Time per request:   0.883 [ms] (mean, across all concurrent
requests)
Transfer rate:  2755.50 [Kbytes/sec] received

Connection Times (ms)
  min  mean[+/-sd] median   max
Connect:00   0.0  0   0
Processing: 13   2.9  1  12
Waiting:12   2.9  1  12
Total:  13   2.9  1  12

Percentage of the requests served within a certain time (ms)
  50%  1
  66%  3
  75%  3
  80%  3
  90%  9
  95% 10
  98% 12
  99% 12
 100% 12 (longest request)

===the test2  result is bad!  =
Failed requests:23
   (Connect: 0, Receive: 0, Length: 23, Exceptions: 0)
Requests per second:1132.76 [#/sec] (mean)

why the Request Dump JSP exmaple testing result is failed, so less
Number of requests(50) and less concurrency (3),

--

You received this message because you are subscribed to the Google Groups 
Lift group.
To post to this group, send email to lift...@googlegroups.com.
To unsubscribe from this group, send email to 
liftweb+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/liftweb?hl=.




[Lift] Re: Jetty or Tomcat, Which web container is recommended to use to deploy the Lift app ?

2009-11-20 Thread monty chen
David Pollk, thanks you reply!

Let us talk about tomcat or jetty Which web container is recommended
to use to deploy the Lift app.

 I remember your reply of Derek Chen-Becker:

On 5月5日, 上午5时59分, David Pollak feeder.of.the.be...@gmail.com wrote:
 Derek,
 Please note that about half of the requests failed in Jetty.  Jetty does not
 seem to be explicitly closing the NIO sockets leading to an out of IO
 descriptor problem... that's why I used Tomcat.

 Thanks,

 David


But at now why you recommend Nginx + Jetty ?


 On Mon, May 4, 2009 at 2:47 PM, Derek Chen-Becker 
 dchenbec...@gmail.comwrote:



  Just to throw in another data point, I ran the tests on my AMD Phenom X2
  720 (3 cores, 6GB of RAM):

  I generated the archetype exactly as you have it here.

  Ran mvn -Drun.mode=production -Djetty.port=9090 jetty:run

  Output from Apache Bench:

  $ ab -c 10 -n 2http://192.168.2.254:9090/user_mgt/login
  This is ApacheBench, Version 2.3 $Revision: 655654 $
  Copyright 1996 Adam Twiss, Zeus Technology Ltd,http://www.zeustech.net/
  Licensed to The Apache Software Foundation,http://www.apache.org/

  Benchmarking 192.168.2.254 (be patient)
  Completed 2000 requests
  Completed 4000 requests
  Completed 6000 requests
  Completed 8000 requests
  Completed 1 requests
  Completed 12000 requests
  Completed 14000 requests
  Completed 16000 requests
  Completed 18000 requests
  Completed 2 requests
  Finished 2 requests

  Server Software:Jetty(6.1.16)
  Server Hostname:192.168.2.254
  Server Port:9090

  Document Path:  /user_mgt/login
  Document Length:3635 bytes

  Concurrency Level:  10
  Time taken for tests:   37.110 seconds
  Complete requests:  2
  Failed requests:10191
 (Connect: 0, Receive: 0, Length: 10191, Exceptions: 0)
  Write errors:   0
  Total transferred:  79276096 bytes
  HTML transferred:   72626584 bytes
  Requests per second:538.94 [#/sec] (mean)
  Time per request:   18.555 [ms] (mean)

--

You received this message because you are subscribed to the Google Groups 
Lift group.
To post to this group, send email to lift...@googlegroups.com.
To unsubscribe from this group, send email to 
liftweb+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/liftweb?hl=.




[Lift] Re: Jetty or Tomcat, Which web container is recommended to use to deploy the Lift app ?

2009-11-19 Thread monty chen
LVS + Nginx + Haproxy + Tomcat


On 11月20日, 上午9时44分, Margaret mawei...@gmail.com wrote:
  * Apache + Tomcat

 I deploy a comet actor demo on tomcat
 the url ishttp://maweis.com:8080
 you can try it?

 -
 mawei...@gmail.com
 13585201588http://maweis.com

 On Fri, Nov 20, 2009 at 9:35 AM, Neil.Lv anim...@gmail.com wrote:
  Hi all,

   I have a silly question about the deploy.

   Which web container is recommended to use to deploy the Lift app ?
  Jetty or Tomcat ?

   I want to use the Comet to push the data in the app.

   * Apache + Tomcat ?
   * Apache + what  ?
   * Nginx + what ?

   Thanks for any suggestion !

  Cheers,
   Neil

  --

  You received this message because you are subscribed to the Google Groups 
  Lift group.
  To post to this group, send email to lift...@googlegroups.com.
  To unsubscribe from this group, send email to 
  liftweb+unsubscr...@googlegroups.com.
  For more options, visit this group 
  athttp://groups.google.com/group/liftweb?hl=.

--

You received this message because you are subscribed to the Google Groups 
Lift group.
To post to this group, send email to lift...@googlegroups.com.
To unsubscribe from this group, send email to 
liftweb+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/liftweb?hl=.




[Lift] Re: Jetty or Tomcat, Which web container is recommended to use to deploy the Lift app ?

2009-11-19 Thread monty chen

 mysql( for
transaction data)
   /
  /
LVS + Nginx + Haproxy + Tomcat   - - - memcache ( for cache)
 \
  \
 cassandra (for
web 2.0 data)

--

You received this message because you are subscribed to the Google Groups 
Lift group.
To post to this group, send email to lift...@googlegroups.com.
To unsubscribe from this group, send email to 
liftweb+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/liftweb?hl=.




[Lift] Re: Jetty or Tomcat, Which web container is recommended to use to deploy the Lift app ?

2009-11-19 Thread monty chen
Hi, Margaret,  Store engine use: mysq + cassandra , and plus memcached
for cache:


 mysql
( transaction data)
   /
  /
LVS + Nginx + Haproxy + Tomcat   - - - memcache ( for cache)
 \
  \
 cassandra (for
web 2.0 data)

--

You received this message because you are subscribed to the Google Groups 
Lift group.
To post to this group, send email to lift...@googlegroups.com.
To unsubscribe from this group, send email to 
liftweb+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/liftweb?hl=.




[Lift] Re: Jetty or Tomcat, Which web container is recommended to use to deploy the Lift app ?

2009-11-19 Thread monty chen
Hi,David Pollk!

Nginx only comes with a round-robin balancer and a hash-based
balancer, so if a request takes a while to load, Nginx will start
routing requests to backends that are already processing requests -- as
a result, some backends will be queueing up requests while some
backends will remain idle. You will get an uneven load distribution,
and the unevenness will increase with the amount of load subject to
the load-balancer.

Haproxy as a LB can:
1: Plenty of load-balancing algorithms, including a least
connections strategy that picks the backend with the fewest pending
connections. Which happens to be just what we want.

2:  Backends can be sanity- and health-checked by URL to avoid routing
requests to brain-damaged backends. (It can even stagger these checks
to avoid spikes.)

3: Requests can be routed based on all sorts of things: cookies, URL
substrings, client IP, etc.

So, I use nginx + haproxy + tomcat(jetty).


On 11月20日, 上午11时27分, David Pollak feeder.of.the.be...@gmail.com
wrote:
 I recommend Nginx + Jetty.

 Apache is the worst front end for this situation... it can only support a
 few hundred simultaneous connections before it falls over.  Ngnix on the
 other hand can proxy tens of thousands.

 Jetty's continuations make it a much better choice than Tomcat.  You can
 have thousands of open Comet request to a Jetty instance where Tomcat is
 capped at a couple of hundred.

 Once the Servlet 3.0 spec in implemented in Glassfish, etc., Lift will
 support 3.0 continuations and any 3.0 container will have the same scaling
 characteristics that Jetty currently does.



 On Thu, Nov 19, 2009 at 5:35 PM, Neil.Lv anim...@gmail.com wrote:
  Hi all,

   I have a silly question about the deploy.

   Which web container is recommended to use to deploy the Lift app ?
  Jetty or Tomcat ?

   I want to use the Comet to push the data in the app.

   * Apache + Tomcat ?
   * Apache + what  ?
   * Nginx + what ?

   Thanks for any suggestion !

  Cheers,
   Neil

  --

  You received this message because you are subscribed to the Google Groups
  Lift group.
  To post to this group, send email to lift...@googlegroups.com.
  To unsubscribe from this group, send email to
  liftweb+unsubscr...@googlegroups.comliftweb%2bunsubscr...@googlegroups.com
  .
  For more options, visit this group at
 http://groups.google.com/group/liftweb?hl=.

 --
 Lift, the simply functional web frameworkhttp://liftweb.net
 Beginning Scalahttp://www.apress.com/book/view/1430219890
 Follow me:http://twitter.com/dpp
 Surf the harmonics

--

You received this message because you are subscribed to the Google Groups 
Lift group.
To post to this group, send email to lift...@googlegroups.com.
To unsubscribe from this group, send email to 
liftweb+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/liftweb?hl=.




[Lift] record support redis?

2009-10-27 Thread monty chen

Record is a new refactorization of Mapper that is backing-store
agnostic at its core, so it doesn’t matter whether you want to save
your data to JDBC, JPA, or even something such as XML

Redis is a key-value database. It is similar to memcached but the
dataset is not volatile, and values can be strings, exactly like in
memcached, but also lists and sets with atomic operations to push/pop
elements.

I want to know when lift 1.1 release, record support redis?.

Scala bindings for Redis are available in this 
http://github.com/acrosa/scala-redis

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Lift group.
To post to this group, send email to liftweb@googlegroups.com
To unsubscribe from this group, send email to 
liftweb+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/liftweb?hl=en
-~--~~~~--~~--~--~---



[Lift] Re: Proposal : Lift ticketing system

2009-10-25 Thread monty chen

+1, good pr Proposal.

On 10月25日, 上午11时17分, Naftoli Gugenheim naftoli...@gmail.com wrote:
 How about we integrate the wiki, blog, forum, and issue tracker into the CMS? 
 ;)
 Seriously, maybe it would be a good idea to create a repo and list, and start 
 serious discussion on all aspects of its design. Maybe it could become a big 
 community project, with lots of feedback to Lift.

 -

 jlist9jli...@gmail.com wrote:

 CMS, wiki, blog, forum also sound more interesting than bug tracking
 system to me :-)

 On Sat, Oct 24, 2009 at 11:13 AM, aw anth...@whitford.com wrote:

  I don't mean to be negative, but are other options being considered
  besides a ticketing system?  I kind of wonder if the effort is worth
  it when excellent alternatives exist (like JIRA -- their Git
  integration may interest you:  
  https://plugins.atlassian.com/plugin/details/4984
  -- I have used their Subversion integration and was very pleased).

  I would be far more interested in seeing something done for the
  benefit of the Lift Web Site.  (Is it written with Lift?)  I don't see
  a Lift CMS -- and that is something that could evolve well over time.
  I think it is important for a web framework to use their own stuff,
  and it should be indicative of the cool things that it can do,
  stability, scale, and performance...  (I am amazed that I have seen
  rather poor demonstrations of this, specifically by Adobe and JBoss --
  but again, I'm not trying to be negative...)

  I see the Lift site integrating Google Analytics...  Is that something
  that could be out of the box with Lift?  That could be a selling
  point to people making external web sites.

  Another area that would be neat to develop is instrumentation.  Sort
  of the JMX-Console equivalent for Lift.  For scalability and sizing
  analysis, this would be really useful.

  Having said that, one major feature that I feel is missing from github
  is the lack of attachments for an issue.  How do you attach test cases
  or patches for an issue?

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Lift group.
To post to this group, send email to liftweb@googlegroups.com
To unsubscribe from this group, send email to 
liftweb+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/liftweb?hl=en
-~--~~~~--~~--~--~---



[Lift] Re: What is going to be in Lift 1.1

2009-10-15 Thread monty chen

 That is great for lift 1.1. but I suggest to improve doc.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Lift group.
To post to this group, send email to liftweb@googlegroups.com
To unsubscribe from this group, send email to 
liftweb+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/liftweb?hl=en
-~--~~~~--~~--~--~---