Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replacing existing stats.jenkins.io code with https://github.com/jenkins-infra/stats.jenkins.io #4265

Closed
krisstern opened this issue Aug 26, 2024 · 24 comments
Labels
helpdesk Infrastructure related issues management in Github stats.jenkins.io

Comments

@krisstern
Copy link
Member

Service(s)

Helpdesk, stats.jenkins.io

Summary

As the Implementing UI for Jenkins Infra Statistics project has officially completed, we would like to request for the existing code for the website https://stats.jenkins.io/ with that in https://github.com/jenkins-infra/stats.jenkins.io

c.c. @shlomomdahan @gounthar @Vandit1604

Reproduction steps

No response

@krisstern krisstern added the triage Incoming issues that need review label Aug 26, 2024
@jenkins-infra-helpdesk-app jenkins-infra-helpdesk-app bot added helpdesk Infrastructure related issues management in Github stats.jenkins.io labels Aug 26, 2024
@krisstern krisstern changed the title Replacing existing stats.jenkins.io with https://github.com/jenkins-infra/stats.jenkins.io Replacing existing stats.jenkins.io code with https://github.com/jenkins-infra/stats.jenkins.io Aug 26, 2024
@dduportal dduportal added this to the infra-team-sync-2024-09-03 milestone Aug 27, 2024
@dduportal dduportal removed the triage Incoming issues that need review label Aug 27, 2024
@dduportal
Copy link
Contributor

That would be the (almost) last mile of #4132 🥳

@krisstern
Copy link
Member Author

Good to know @dduportal 👍🏼

@hervelemeur
Copy link

I'll prepare a plan for that today hopefully.

@lemeurherveCB
Copy link

lemeurherveCB commented Sep 9, 2024

From #4132 (comment):

It means planning the effective switch to the new webservice.

We would also need to define what we do with the existing service:

  • How much time do we keep it ?
  • Archiving ?
  • etc.

As the existing website is running from Github Pages, I propose to just change its subdomain from stats.jenkins.io to old.stats.jenkins.io and keep it as there is no related infra cost, WDYT?

If we don't want to keep it, we can remove these lines: https://github.com/jenkins-infra/azure-net/blob/a51c2d937433c51eb289b319123beeb8e9477364/dns-records.tf#L287-L290

To switch to the new service we just have to exchange the DNS records.

Note: there is nothing to archive per se as https://github.com/jenkins-infra/infra-statistics is still used by the new website.

@lemeurherveCB
Copy link

To switch to the new service we just have to exchange the DNS records.

Opened jenkins-infra/azure-net#291

@dduportal
Copy link
Contributor

From #4132 (comment):

It means planning the effective switch to the new webservice.
We would also need to define what we do with the existing service:

  • How much time do we keep it ?
  • Archiving ?
  • etc.

As the existing website is running from Github Pages, I propose to just change its subdomain from stats.jenkins.io to old.stats.jenkins.io and keep it as there is no related infra cost, WDYT?

If we don't want to keep it, we can remove these lines: https://github.com/jenkins-infra/azure-net/blob/a51c2d937433c51eb289b319123beeb8e9477364/dns-records.tf#L287-L290

To switch to the new service we just have to exchange the DNS records.

Note: there is nothing to archive per se as https://github.com/jenkins-infra/infra-statistics is still used by the new website.

What about the "process" which updates the branch gh-pages?

@lemeurherveCB
Copy link

lemeurherveCB commented Sep 10, 2024

@lemeurherveCB
Copy link

We may want to add some explanations on https://github.com/jenkins-infra/infra-statistics README to clarify this.

@dduportal
Copy link
Contributor

  • DNS change: LGTM. Let's plan it for 11 September if no objection (to be confirmed during team meeting)
  • Old site on GH Page: it must be decommissioned. We don't want to have a resource published (it uses common resources: domain names, etc.) and it can be abused (like a DNS not renewed).
    • How much time should we keep it "just in case" once the DNS is switched? 1, 2 weeks? More ? (will discuss it during team meeting and I'll report here)
    • WDYT about changing the branch to data (instead of gh-pages) at this moment? It will allow us to disable the GH Page website once done

@lemeurherveCB
Copy link

data looks fine to me 🙂

@lemeurherveCB
Copy link

It will allow us to disable the GH Page website once done

Note that it can also be disabled by setting "none" as branch in GitHub Pages settings of the repository:

image

@lemeurherveCB
Copy link

As the job run once per month there will be plenty of time switching the branch name from gh-pages to data in both repositories without interrupting the service: https://github.com/jenkins-infra/infra-statistics/blob/8209b583ee5be409d2dc8cdf780bd4358579b8de/Jenkinsfile#L18-L19

// Make sure we run this job once a month (at 3am on the 2nd of the month) when the raw stats are available.
properties([pipelineTriggers([cron('0 3 2 * *')])])

@lemeurherveCB
Copy link

@MarkEWaite @shlomomdahan I'd also suggest that when jenkins-infra/azure-net#291 is merged and released, one of you could announce the new website on https://groups.google.com/g/jenkinsci-users and https://groups.google.com/g/jenkinsci-dev, WDYT?

Maybe a blog post too?

@krisstern
Copy link
Member Author

Hi @lemeurherveCB Thanks! Or I could make an announcement for the revamped project too.

@dduportal
Copy link
Contributor

@krisstern @lemeurherveCB We propose to switch the production to the new site tomorrow, Wednesday 11 September at 08:00am UTC (10h00am Paris time).

The rest can wait (by default 1 week).

No objection?

@hervelemeur
Copy link

@dduportal looks fine to me, but my opinion is not that important, @krisstern's one is.

@krisstern
Copy link
Member Author

No objection from me

@dduportal
Copy link
Contributor

We did change the DNS:

  • The PR in Azure failed (TTL not up to date and non atomic change). We fixed it manually
  • The stats website is now broken as the production in AKS does not have the required ingress setup. We are operating it right now to hotfix but the website is in outaghe until it's done

@dduportal
Copy link
Contributor

Update: the new site is live (https://stats.jenkins.io/) and the old site is now available again (https://old.stats.jenkins.io/)

@krisstern
Copy link
Member Author

I will make an announcement about the new revamped stats.jenkins.io site within the next couple of hours

@krisstern
Copy link
Member Author

My apologies, I have been waiting for jenkins-infra/plugin-site#1890 to be merged first before making an announcement...

@dduportal
Copy link
Contributor

My apologies, I have been waiting for jenkins-infra/plugin-site#1890 to be merged first before making an announcement...

many thanks @krisstern !

@dduportal
Copy link
Contributor

I'm closing this issue as the scope "put the GSoC new website online as default" is ok. See #4132 (comment) for the next steps.

@lemeurherveCB
Copy link

lemeurherveCB commented Sep 12, 2024

EDIT: copied at #4132 (comment) to continue the discussion there (still open)

As noted in badges/shields#10522 (comment), there are far more consumers than we (I) initially though: https://github.com/search?q=stats.jenkins.io&type=code 😱

Links to (old.)stats.jenkins.io were pointing to files (still) stored on GitHub (currently on the gh-pages, generated from the pipeline of https://github.com/jenkins-infra/infra-statistics), while the new frontend doesn't serve them.

To avoid breaking existing consumers and without serving these files from our service, I propose to put in place redirections from the three folders of https://github.com/jenkins-infra/infra-statistics/tree/gh-pages (then from the data branch) to https://raw.githubusercontent.com/jenkins-infra/infra-statistics/gh-pages/ with the help of jenkins-infra/helm-charts#1332, WDYT?

Ex:
https://stats.jenkins.io/plugin-installation-trend/view-job-filters.stats.json would redirect to https://raw.githubusercontent.com/jenkins-infra/infra-statistics/gh-pages/plugin-installation-trend/view-job-filters.stats.json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
helpdesk Infrastructure related issues management in Github stats.jenkins.io
Projects
None yet
Development

No branches or pull requests

4 participants