Sentry-javascript: RavenJS should provide an alias for the latest file

Created on 29 Mar 2017  Â·  7Comments  Â·  Source: getsentry/sentry-javascript

RavenJS is updated often and we use it in many separate projects. It would be really useful for RavenJS to provide a https://cdn.ravenjs.com/latest/raven.min.js alias to the latest stable version.

Most helpful comment

We've had/discussed this thought previously in #868; the difficulty is that as soon as we make /latest/raven.min.js and people depend on it, we can never have backwards-incompatible changes.

Open to ideas; maybe we could do something like https://cdn.ravenjs.com/3.x/latest/raven.min.js as Ben suggested here.

All 7 comments

We've had/discussed this thought previously in #868; the difficulty is that as soon as we make /latest/raven.min.js and people depend on it, we can never have backwards-incompatible changes.

Open to ideas; maybe we could do something like https://cdn.ravenjs.com/3.x/latest/raven.min.js as Ben suggested here.

Worth noting too, is that since this is a CDN, we'd lose the ability to cache "forever" as we do now, and we'd have to have lower TTLs in order to propagate changes in a timely manner. So this would probably mean either dropping down to a 24h TTL or a 1h TTL depending on how quickly we want to propagate changes. Both of which are a performance hit for users that are now requesting these files.

But a performance hit they can choose if they go with latest.

On Wed, Mar 29, 2017 at 11:14 AM, Matt Robenolt notifications@github.com
wrote:

Worth noting too, is that since this is a CDN, we'd lose the ability to
cache "forever" as we do now, and we'd have to have lower TTLs in order to
propagate changes in a timely manner. So this would probably mean either
dropping down to a 24h TTL or a 1h TTL depending on how quickly we want to
propagate changes. Both of which are a performance hit for users that are
now requesting these files.

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/getsentry/raven-js/issues/911#issuecomment-290176996,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AHkdLZQNaz0YBU73obGaQGt5EgsdkMQWks5rqp-DgaJpZM4MtPYU
.

I think only allowing the latest tag on major versions like https://cdn.ravenjs.com/3.x/latest/raven.min.js makes sense. That way you know that breaking changes require a manual update and minor versions and patches get updated automatically. The shorter cache TTL is a downside that I'm willing to live with. People that want a longer cache time can always use the exact version.

In my opinion this would be a great addition, quite annoying to have to redeploy my entire app everytime ravenjs gets an update.

It'll be fixed with an async loader

So has this been fixed or what?

@alex-jitbit if you are using the loader it is fixed yes.
https://docs.sentry.io/platforms/javascript/#lazy-loading-sentry

Was this page helpful?
0 / 5 - 0 ratings