Current time: 12-16-2017, 01:45 AM Hello There, Guest! (LoginRegister)

Post Reply 
 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Fine Tuning Http2
05-05-2016, 05:05 AM
Post: #1
Fine Tuning Http2
We implemented two new URL parameters which split our combined js/css link to several links:
splitCss=N
splitJs=N
where N is number of chunks.
For example, https://shopbakersnook.com/?splitCss=2
means that there will be two css links (instead of one).

The following link: https://shopbakersnook.com/?splitCss=10&splitJs=10
splits combined link to request each js/css file separately.

We have done some testing today and cannot find any advantage in doing this. Splitting the JS/CSS into separate files (supposed optimizations for HTTP/2) actually hurts a little in Pagespeed and and has higher page load times.

Regarding the "delayCss=1&preload=1". Yes the GooglePagespeed score is good - but check the delayed applying of the css rules in your browser? Plus, overall, it's not loading any faster. I think it's averaging a little slower in overall pageload VS just http://shopbakersnook.com

Understand, "delayCss=1&preload=1" just delays the CSS. So as far as Pagespeed is concerned - the above the fold content is not delayed waiting for the scripts to load and render. The problem is that the content appears before the styling (CSS) and it looks horrible for a split second.

Any Advice would be welcomed on this subject.
Find all posts by this user
Quote this message in a reply
05-05-2016, 04:38 PM
Post: #2
RE: Fine Tuning Http2
Hi Brian,

I think you've come across what some others who are implementing HTTP/2 have run into with splitting combined script files.

The issues stem from how the compression algorithm works and processing of multiple files. Compressing larger files is typically more efficient. Smaller files don't compress as much. And having more files to process could impact server performance.

These are probably a couple of the things you're running into.

A good example of this issue was experienced by Khan Academy, when they moved to HTTP/2 -- http://engineering.khanacademy.org/posts...-http2.htm

You have to look at your own JS and CSS files, but depending on how many you have, you may want to keep them combined.

Also, comparing page speed with HTTP vs HTTPS may be comparing apples to oranges, if HTTP is running with HTTP/1.1 and HTTPS is running with HTTP/2. Overall use of your site should benefit with the other HTTP/2 features, like multiplexing, that HTTP/1.1 does not have. If that's not the case, let me know.

Hope that helps.

Jean Tunis
Principal Consultant, RootPerformance Consulting
http://www.websiteevals.com
Author, Analyzing HTTP
http://www.analyzinghttp.com
Find all posts by this user
Quote this message in a reply
05-06-2016, 12:44 AM
Post: #3
RE: Fine Tuning Http2
Thank you! This helps us so much!

(05-05-2016 04:38 PM)beyondstop Wrote:  Hi Brian,

I think you've come across what some others who are implementing HTTP/2 have run into with splitting combined script files.

The issues stem from how the compression algorithm works and processing of multiple files. Compressing larger files is typically more efficient. Smaller files don't compress as much. And having more files to process could impact server performance.

These are probably a couple of the things you're running into.

A good example of this issue was experienced by Khan Academy, when they moved to HTTP/2 -- http://engineering.khanacademy.org/posts...-http2.htm

You have to look at your own JS and CSS files, but depending on how many you have, you may want to keep them combined.

Also, comparing page speed with HTTP vs HTTPS may be comparing apples to oranges, if HTTP is running with HTTP/1.1 and HTTPS is running with HTTP/2. Overall use of your site should benefit with the other HTTP/2 features, like multiplexing, that HTTP/1.1 does not have. If that's not the case, let me know.

Hope that helps.
Find all posts by this user
Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)