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

Tests - Use base image for frontend tests #190

Merged
merged 10 commits into from
Oct 23, 2019

Conversation

Ark-kun
Copy link
Contributor

@Ark-kun Ark-kun commented Nov 10, 2018

This change moves the unchanging parts of the image to a base image so that they're not rebuilt every time. This improves performance and reliability.

The Dockerfile is now just

FROM gcr.io/ml-pipeline-test/selenium-standalone-chrome-gcloud-nodejs
COPY --chown=seluser . /src
WORKDIR /src
ENTRYPOINT [ "./run_test.sh" ]

This change is Reviewable

@coveralls
Copy link

coveralls commented Nov 10, 2018

Pull Request Test Coverage Report for Build 207

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 67.592%

Totals Coverage Status
Change from base Build 185: 0.0%
Covered Lines: 1535
Relevant Lines: 2179

💛 - Coveralls

@coveralls
Copy link

Pull Request Test Coverage Report for Build 290

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 67.592%

Totals Coverage Status
Change from base Build 185: 0.0%
Covered Lines: 1535
Relevant Lines: 2179

💛 - Coveralls

@IronPan
Copy link
Member

IronPan commented Nov 10, 2018

/test presubmit-e2e-test

@yebrahim
Copy link
Contributor

How much time does this actually save? Looks to me like too many lines of code if they just save us a few seconds of test time.

@Ark-kun
Copy link
Contributor Author

Ark-kun commented Nov 16, 2018

How much time does this actually save? Looks to me like too many lines of code if they just save us a few seconds of test time.

  1. This WIP, so there are some extra lines of code that should be gone before review.
  2. This should save 90% of image building time
  3. This should reduce test flakiness by not downloading from Internet during build.
  4. This would allow us to use local image building tools like Bazel. These tools support adding files and packages to the image, but not RUNning programs.

@Ark-kun
Copy link
Contributor Author

Ark-kun commented Nov 26, 2018

How much time does this actually save? Looks to me like too many lines of code if they just save us a few seconds of test time.

This is just basic prudence. Do not download/clone when you do not need to. Apart from big decrease in image build times, this reduces the failures due to temporary network problems and also saves us from completely broken check-in process.

Here is how the complete test failure looks like:

build-frontend-image:	Step 12/20 : FROM node:9.4.0-alpine
build-frontend-image:	9.4.0-alpine: Pulling from library/node
build-frontend-image:	error parsing HTTP 404 response body: invalid character 'p' after top-level value: "404 page not found\n"

So at this moment no code can be checked in due to failing test.
@yebrahim Would you like to fix that?

@Ark-kun
Copy link
Contributor Author

Ark-kun commented Nov 26, 2018

/test presubmit-e2e-test

@yebrahim
Copy link
Contributor

Doing docker pull node:9.4.0-alpine works for me; the image is still out there. We need to update it to use the lts version, but it's not breaking tests yet as far as I can see.

@Ark-kun Ark-kun force-pushed the avolkov/Tests---Use-base-image-for-frontend-tests branch 3 times, most recently from 5929dea to 0309015 Compare December 1, 2018 07:10
@k8s-ci-robot k8s-ci-robot added size/M and removed size/L labels Dec 1, 2018
@Ark-kun Ark-kun force-pushed the avolkov/Tests---Use-base-image-for-frontend-tests branch 2 times, most recently from a009496 to 8bf6df8 Compare December 1, 2018 23:06
@k8s-ci-robot k8s-ci-robot added size/L and removed size/M labels Dec 1, 2018
@rileyjbauer
Copy link
Contributor

/lgtm

Copy link
Contributor

@yebrahim yebrahim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just two minor comments. Approving in case you want to merge.
/approve

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: yebrahim

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot
Copy link
Contributor

k8s-ci-robot commented Jun 18, 2019

@Ark-kun: The following test failed, say /retest to rerun them all:

Test name Commit Details Rerun command
presubmit-e2e-test a8317f5 link /test presubmit-e2e-test

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@Ark-kun Ark-kun force-pushed the avolkov/Tests---Use-base-image-for-frontend-tests branch from 5abe22c to 84e6a89 Compare June 19, 2019 02:00
@k8s-ci-robot k8s-ci-robot removed the lgtm label Jun 19, 2019
@Bobgy
Copy link
Contributor

Bobgy commented Oct 15, 2019

/area front-end

@Bobgy
Copy link
Contributor

Bobgy commented Oct 15, 2019

@Ark-kun what's your plan about this PR?

@Ark-kun
Copy link
Contributor Author

Ark-kun commented Oct 22, 2019

@Ark-kun what's your plan about this PR?

As the Frontend area lead, you can decide whether to close it or merge.

This change was designed to improve the build speed and stability. The build speed is now pretty good even without this PR. The stability aspect remains valid.

@Bobgy
Copy link
Contributor

Bobgy commented Oct 23, 2019

/retest
/lgtm

@Bobgy
Copy link
Contributor

Bobgy commented Oct 23, 2019

I think this makes code base cleaner in separating env setup with actual test steps. Also great work automating image building. Let's merge this as long as tests are still passing.

@k8s-ci-robot k8s-ci-robot merged commit 1c566f8 into master Oct 23, 2019
@IronPan IronPan deleted the avolkov/Tests---Use-base-image-for-frontend-tests branch October 30, 2019 19:58
HumairAK pushed a commit to red-hat-data-services/data-science-pipelines that referenced this pull request Mar 11, 2024
- Add installation from PyPi to sdk/README.md
- Modify setup.py to read long_description from sdk/README.md
- Replace relative links with absolute links to kfp-tekton GitHub repo
- Add make distribution target for upload to testpypi

Resolves kubeflow#185
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants