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

AMBARI-26113: Switch the PhantomJS used by Karma tests to chromium-browser #3809

Merged
merged 8 commits into from
Sep 5, 2024

Conversation

zRains
Copy link
Contributor

@zRains zRains commented Aug 10, 2024

What changes were proposed in this pull request?

With the arrival of the ambari-web upgrade PR: #3770 , PhantomJS is no longer sufficient to support future testing tasks, as its support for ES5 has been abandoned(#14506, #14458). The chromium-browser will provide ES5 syntax support and enable testing for more libraries. This will be one of the foundational steps in the overall ambari-web upgrade plan.

This PR will be divided into two modules: ambari-web and ambari-admin. PhantomJS will be completely removed, and some failing tests will be fixed.

How was this patch tested?

$ mvn -T 2C -am test -pl ambari-web -Dmaven.artifact.threads=10 -Drat.skip
$ mvn -T 2C -am test -pl ambari-admin -Dmaven.artifact.threads=10 -Drat.skip

Ambari-web
image

Ambari-admin
image

@zRains zRains marked this pull request as ready for review August 30, 2024 18:37
@zRains
Copy link
Contributor Author

zRains commented Aug 31, 2024

cc @JiaLiangC

@mgucma
Copy link

mgucma commented Sep 2, 2024

Have you tried, for example: Puppeteer ?

@zRains
Copy link
Contributor Author

zRains commented Sep 3, 2024

Have you tried, for example: Puppeteer ?

No, just switched the test browser.

@mgucma
Copy link

mgucma commented Sep 3, 2024

Have you tried, for example: Puppeteer ?

No, just switched the test browser.

Recommended Node.js Versions:
Node.js 12.x to 16.x:

karma-chrome-launcher 3.2.0 works well with Node.js versions from 12.x to 16.x. These versions are also commonly supported by many other dependencies in the JavaScript ecosystem.

@zRains
Copy link
Contributor Author

zRains commented Sep 3, 2024

@mgucma Good idea, this is already in the planning stage, but it is currently limited by dependencies in the project, such as brunch. It will still take some time to handle compatibility issues.

@mgucma
Copy link

mgucma commented Sep 3, 2024

@mgucma Good idea, this is already in the planning stage, but it is currently limited by dependencies in the project, such as brunch. It will still take some time to handle compatibility issues.

@zRains Yes I know about it, I make rpm ambari under rocky 9 on docker. Without tests rpm is created. When I run tests it doesn't work and I can't find the reason.

@zRains
Copy link
Contributor Author

zRains commented Sep 3, 2024

@mgucma Try running the test command in the same environment without using Docker; you should be able to get error messages, or use the -X parameter.

@mgucma
Copy link

mgucma commented Sep 4, 2024

@mgucma Try running the test command in the same environment without using Docker; you should be able to get error messages, or use the -X parameter.

@zRains
The biggest problem with tests for ambari server and I had to update junit to version 4.12.3. And now I am in the process of correcting tests.

My Pull Requet to Rocky 9 will not pass, but I need Ambari update for this system. I need to do migration from Centos 7 to Rocky 9.

Can you show me the way to make corrections?

@JiaLiangC
Copy link
Contributor

@mgucma

  1. Ambari itself is a Java and Python program, theoretically supporting all operating systems. However, Ambari includes two acceleration libraries (.c) in the Ambari agent, which leads to coupling with the operating system.

  2. The big data components managed by Ambari have different levels of coupling with the operating system, depending on their implementation. So if you want Ambari to support Rocky 9, you can refer to this PR for Rocky 8:
    https://github.com/apache/ambari/pull/3758/files

  3. Because of this PR, I modified the Jenkinsfile, which will temporarily cause the project's CI/CD to fail, but this will be fixed quickly. So if you submit a PR, don't worry about the CI/CD issues caused by this PR.

The support for other big data components on Rocky 9 is controlled by the Apache Bigtop project. Additionally, I recommend that you first submit your code as a PR, so that some initial review and suggestions can be made.

Copy link
Contributor

@JiaLiangC JiaLiangC left a comment

Choose a reason for hiding this comment

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

LGTM

@JiaLiangC
Copy link
Contributor

Thanks for your great work!

@JiaLiangC JiaLiangC merged commit 831d589 into apache:trunk Sep 5, 2024
1 check passed
@zRains zRains deleted the feat-chromium-browser branch September 23, 2024 01:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants