Rails and ySlow

If anyone has followed Steve Soulder’s tips on optimizing web
performance (Yahoo chief performance guy), his most important rule of
thumb could be deadly to your rails app.

My first blog post:
http://www.dominicson.com/web-2-0

Dominic

All my scripts and css are compress, merged and then gzipped and
served from s3. This is all done via a task each time I deploy my app.

I don’t have any problems with it. What are the problems, i don’t
understand?

On Sep 24, 1:38 pm, Dominic S. [email protected]

I thought it was fine also. Logs seemed active. Then users started
complaining. Then I checked on as many computers that my js would load
correctly. out of 5 computers, each running both IE and FF, one of them
would fail to load the js correctly.

I’m just not going to take the risk…

eggie5 wrote:

All my scripts and css are compress, merged and then gzipped and
served from s3. This is all done via a task each time I deploy my app.

I don’t have any problems with it. What are the problems, i don’t
understand?

On Sep 24, 1:38 pm, Dominic S. [email protected]

Oh, so it’s a compressor issue. A lot of the compressors I was
experimenting with produced bad JS, especially with more advanced JS.
The compressed js is also prone to errors just because of the fact
that javascript is such a flexible language (not rigid in it’s
syntax).

It’s not hard to try out the results in all the browser/os
combinations or FF/IE/S on windows/osx. It just seems like what you’re
saying is a cop-out.

Anyways, I suggest using dojo compressor.

On Sep 24, 8:14 pm, Dominic S. [email protected]

When my deploy script runs, just builds the string path for the css
file and inserts it into the rhtml page as html.

Eggie5, you mention serving your css and js files from S3. I tried
that before and it really slowed my site down. I served it by setting
config.action_controller.asset_host = my.s3.bucket in config/
environment/production.rb. How are you serving these files?

OH, and it’s also CRITICAL that when you upload the files to s3 that
you set the content-types to text/javascript and text/css respectively
or else when they’re severed they will be ignored by in certain
circumstances.

On Sep 24, 8:14 pm, Dominic S. [email protected]

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs