Upgrading to Polymer 0.8

27 views
Skip to first unread message

Jeremy Klein

unread,
Apr 29, 2015, 4:46:45 PM4/29/15
to chromium...@chromium.org, Pavel Sergeev, ray...@chromium.org, Jennifer Apacible, fuk...@chromium.org
Hey Chromium Polymer users!

TLDR: If we want to avoid a 300-500K binary size hit, we need to convert all existing Chromium clients of Polymer over to Polymer 0.8 by the M44 branch date (5/15).

Polymer 0.8 has been released and brought into the Chromium source tree (third_party/polymer/v0_8). With it comes a much smaller binary size, huge performance gains, and JS compiler support. Unfortunately, it also comes with major breaking API changes. 

My initial plan was to keep both 0.5 and 0.8 in Chrome until we had fully converted all clients to 0.8 over time. However, I'm already receiving push-back on having both versions in Chrome's binary at once due to the size overhead. Therefore, our goal will be to convert all existing Polymer clients bundled in Chrome's binary to Polymer 0.8 before the M44 branch point (5/15). This will allow us to avoid having both versions of the library in the Chrome binary in the same release.

I realize that the effort involved in this conversion will be non-trivial for many projects. I (along with other members of the md-settings project) am happy to help any way I can throughout this conversion process through questions, reviews, etc. This mailing list (chromium-polymer) will also be a good place to send questions you have about upgrading. I am confident that the benefits of Polymer 0.8 will be worth the pain of this upgrade process.

Please let me know if you have any questions or concerns. If there is absolutely no way your project will be able to make the switch by the branch date, we will need to try to convince the TPMs to accept the substantial bump in binary size for M44. It is in everyone's best interest to avoid that situation, so please let me know as soon as possible if you have serious doubts about your ability to hit this deadline.

Thank you,
Jeremy

Useful links:

Jeremy Klein

unread,
Apr 29, 2015, 4:55:16 PM4/29/15
to chromium...@chromium.org, Pavel Sergeev, ray...@chromium.org, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org
+A couple more folks this will impact.

Kurt Dresner

unread,
Apr 29, 2015, 7:20:27 PM4/29/15
to Jeremy Klein, chromium...@chromium.org, Pavel Sergeev, ray...@chromium.org, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org
"so we haven’t yet had time to port all the previous elements to 0.8."

Is there a timeline for this? Can we be expected to switch to 0.8 without any core elements?

-Kurt

--
You received this message because you are subscribed to the Google Groups "Chromium-Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-polym...@chromium.org.
To post to this group, send email to chromium...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-polymer/CAA6mrks3Mf3kNO8dcu_xVCeQUgNGOTac4tRtEgLt7Fi3-u5W0g%40mail.gmail.com.

Raymes Khoury

unread,
Apr 29, 2015, 8:11:29 PM4/29/15
to Kurt Dresner, Jeremy Klein, chromium...@chromium.org, Pavel Sergeev, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org, Sam McNally
Upgrading to 0.8 might not be possible for us (and possibly a lot of other users of polymer in Chrome). We run polymer inside an extension which has CSP enabled. However sammc@ pointed out to me that polymer 0.8 seems to violate CSP with no suggested workaround other than waiting for a future release or disabling CSP (see https://www.polymer-project.org/0.8/#content-security-policy-csp-support). 

We would have to have a chat with the security team if we were to decide to disable CSP in our extension but my guess is that they wouldn't be very excited about doing that.

Thanks!
Raymes

Taylor Savage

unread,
Apr 29, 2015, 8:25:08 PM4/29/15
to Raymes Khoury, Kurt Dresner, Jeremy Klein, chromium...@chromium.org, Pavel Sergeev, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org, Sam McNally
Hey all,

Following up on a couple points:

CSP
The latest Polymer 0.8 release is refactored to run under CSP. We've removed all instances of unsafe-eval and built a tool called crisper that strips out inline scripts as well. With these two CSP should be good to go.

Elements
Most elements have been ported to 0.8 - you can look at progress at go/polymer-elements and the PolymerElements github organization. Note that the "core" elements have been renamed to the "iron" elements, and the UI core elements like `core-drawer-panel` have been moved to "paper". If you have an element that you need that isn't yet ported and is below a p2 on go/polymer-elements, please let me know directly and we'll do what we can to get it prioritized and built.

Thanks,
Taylor

Raymes Khoury

unread,
Apr 29, 2015, 8:29:40 PM4/29/15
to Taylor Savage, Kurt Dresner, Jeremy Klein, chromium...@chromium.org, Pavel Sergeev, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org, Sam McNally
Thanks for the update. I guess we'll look into switching over then!

Kurt Dresner

unread,
Apr 30, 2015, 1:12:15 AM4/30/15
to Jeremy Klein, Raymes Khoury, Taylor Savage, chromium...@chromium.org, Pavel Sergeev, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org, Sam McNally
Boo-yah! Thanks, guys! :oD

On Wed, Apr 29, 2015 at 5:45 PM Jeremy Klein <jlk...@google.com> wrote:
What Taylor said :-). CSP should be fine with the version of 0.8 checked into Chrome. Elements are super close to being finished!

Jeremy Klein

unread,
Apr 30, 2015, 5:25:42 PM4/30/15
to Kurt Dresner, Raymes Khoury, Taylor Savage, chromium...@chromium.org, Pavel Sergeev, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org, Sam McNally
Sending again from the correct account...

Important update/correction:
If you are currently launched and in the Chrome binary (OOBE, FileManager) DO NOT start converting to Polymer 0.8 until *after* the branch point.

Because we can't have both versions in the binary for the same release, we are going to leave only 0.5 in for M44. This will give teams the full 6 week cycle to convert before the M45 branch point. In order to allow 0.8 development to continue for unreleased projects and projects not in the Chrome binary, 0.8 will stay in the source tree and be included in the binary behind a build flag until after the M44 branch point. I will update with more details once the flag is in place.

I apologize for the confusion and thank you all for your patience!
- Jeremy

On Thu, Apr 30, 2015 at 2:09 PM Jeremy Klein <jlk...@google.com> wrote:
Important update/correction:
If you are currently launched and in the Chrome binary (OOBE, FileManager) DO NOT start converting to Polymer 0.8 until *after* the branch point.

Because we can't have both versions in the binary for the same release, we are going to leave only 0.5 in for M44. This will give teams the full 6 week cycle to convert before the M45 branch point. In order to allow 0.8 development to continue for unreleased projects and projects not in the Chrome binary, 0.8 will stay in the source tree and be included in the binary behind a build flag until after the M44 branch point. I will update with more details once the flag is in place.

I apologize for the confusion and thank you all for your patience!
-Jeremy

Jeremy Klein

unread,
May 1, 2015, 4:02:36 PM5/1/15
to Kurt Dresner, Raymes Khoury, Taylor Savage, chromium...@chromium.org, Pavel Sergeev, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org, Sam McNally
FYI: The gyp build flag is enable_polymer_v08 and has landed in https://codereview.chromium.org/1118673004/. Just add "enable_polymer_v08=1" to your GYP_DEFINES and you should see the 0.8 files served from chrome://resources/polymer/v0_8/...

Thanks!
Jeremy

mark a. foltz

unread,
May 1, 2015, 4:31:41 PM5/1/15
to Jeremy Klein, Kurt Dresner, Raymes Khoury, Taylor Savage, chromium...@chromium.org, Pavel Sergeev, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org, Sam McNally

Jeremy Klein

unread,
May 4, 2015, 1:45:25 PM5/4/15
to mark a. foltz, Kurt Dresner, Raymes Khoury, Taylor Savage, chromium...@chromium.org, Pavel Sergeev, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org, Sam McNally

Pavel Sergeev

unread,
May 19, 2015, 12:29:38 PM5/19/15
to Jeremy Klein, mark a. foltz, Kurt Dresner, Raymes Khoury, Taylor Savage, chromium...@chromium.org, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org, Sam McNally
Do we have a meta issue for this? I was not able to find one. 

Jeremy Klein

unread,
May 19, 2015, 2:28:57 PM5/19/15
to Pavel Sergeev, mark a. foltz, Kurt Dresner, Raymes Khoury, Taylor Savage, chromium...@chromium.org, Jennifer Apacible, fuk...@chromium.org, zeli...@chromium.org, penn...@chromium.org, Sam McNally
Reply all
Reply to author
Forward
0 new messages