Hi :

  Thanks for the reply.
  The entire page costs about 5 seconds loading about 40 pictures with
each picture about 3K.
  And when I put the pictures under some static web server (Nginx),
the picture loading time is down to 0.4 seconds,
  while the main page (compojure/ring/enlive) costs still a long 1
second in local host testing.

  I am not sure it's because of jetty or compojure or ring, but if
it's picture it shouldn't be enlive.

  I would think to move the project to maybe Lift, for the clojure
solution seems a bit slow.

On 8月2日, 上午3時03分, James Reeves <jree...@weavejester.com> wrote:
> On 1 August 2011 08:24, sailormoo...@gmail.com <sailormoo...@gmail.com> wrote:
>
>
>
>
>
> > I don't know why, but it seems to have a one second delay getting each
> > static file even in local host testing.
>
> > :dependencies [[org.clojure/clojure "1.2.1"]
> >                 [org.clojure/clojure-contrib "1.2.0"]
> >                 [compojure "0.6.4"]
> >                 [ring-serve "0.1.0"]
> >                 [enlive "1.0.0"]
> >                 [clojureql "1.0.0"]
> >                 [mysql/mysql-connector-java "5.1.6"]]
> >  :dev-dependencies [[lein-ring "0.4.5"]]
>
> > (defroutes main-routes
> >  (route/files "/")
> >  (route/not-found "Page not found"))
>
> > And I even tried route/resources, it's still slow, any idea to make
> > those file cached or any Jetty configuration is needed?
>
> Are you certain that it's the route/files or route/resources functions
> that are slow?
>
> Have you tried replacing those functions with routes that return strings?
>
> - James- 隱藏被引用文字 -
>
> - 顯示被引用文字 -

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to