- Loading...
You are viewing an old version of this page. View the current version.
Compare with Current View Page History
« Previous Version 2 Next »
Running tests
Read about the Submit repo here.
This page is deprecated and it's content is either old or being moved to the OpenJDK Developers' Guide. Please update your links.
This can mean a few different things:
Please note that there is a significant difference between high priority and high urgency. High priority issues like vulnerabilities for example will always have higher priority than regular bug fixing. Critical issues are urgent, but do not always have high priority. It could be a trivial bug in a test that has no particular significance, a test that nobody cares wether it is fixed or not. But, if it causes failures in tier 1 it is urgent to fix it. Not high priority but still urgent. It is most likely urgent enough to take 20 minutes away from fixing a vulnerability.
It is required that anyone who pushes a change monitors the tier 1 testing and the following nightly, or designates this requirement to someone who can also fix possible regressions. It is considered exceptionally bad engineering to push a change at the end of the day, or on the last day before going on vacation or otherwise becoming unavailable. Critical failures must be handled with high urgency, thus the engineer who caused the failure is best suited to do so.
If a failure in tier 1 is identified and can be fixed within two - three hours, this is the preferred way to go. If a fix is not expected within that time the broken change must be backed out.
Integration blockers must be fixed before the next integration per definition. Usually this means that a fix should be available within a few days.
Bugs that causes unrelated tests to fail in the nightly should be fixed before the next nightly. If a fix can not be delivered within two days the causing change must be backed out.
There can never be any ownership involved when it comes to backing out a change. It doesn't matter who made the change or why it fails, if it needs to be backed out it should be backed out. Whoever is on site first should do it. Usually there is some synchronization before doing the actual work to avoid duplicate work.
Use mercurial to create a backout changeset:
hg backout -r <revision_id>
A backout is considered a trivial change so a single Reviewer is enough and you can push immediately when reviewed. See How to backout a change for details on bug management in JBS related to backing out changes.
This information is no longer relevant.
This information has been moved to the OpenJDK Developers' Guide. Please update your links.
This page is deprecated and it's content is either old or being moved to the OpenJDK Developers' Guide. Please update your links.
The HotSpot team owns two components in JBS: hotspot and core-svc.
Please note that all issues in the hotspot component are required to have a subcomponent set.
| Team | JBS component | JBS query |
|---|---|---|
| Compiler | hotspot / compiler | component = hotspot AND Subcomponent = compiler |
| GC | hotspot / gc | component = hotspot AND Subcomponent = gc |
| Runtime | hotspot / runtime hotspot / jfr | component = hotspot AND Subcomponent in (runtime, jfr) |
| Serviceability | hotspot / jvmti hotspot / svc core-svc core-svc / debugger core-svc / tools core-svc / java.lang.instrument tools / hprof | ( (component = hotspot AND Subcomponent in (jvmti, svc)) OR (component = tools AND Subcomponent = hprof) ) |
| Monitor and Management | hotspot / svc-agent core-svc / java.lang.management core-svc / javax.management | ( (component = hotspot AND Subcomponent = svc-agent) OR |
| Test | hotspot / test | component = hotspot AND Subcomponent = test |
The integration_blocker label should be used to indicate that a bug is present in a repository but not present upstreams. When filing a new bug found in hotspot testing, the default should be to add the integration_blocker label. If it is verified (when filing or later) that the new failure is already present upstreams from the repository where it was found the label should be removed and an explicit comment must be added to the bug explaining why the bug is not an integration blocker. A failure seen in a project repo is considered escaped when found in jdk/hs. A failure seen in jdk/hs is considered escaped if seen in jdk/jdk or if older failures are found from a date before the last integration to jdk/jdk.
jdk/hs.The testbug label should be used for bugs in tests and test infrastructure. There is no fundamental difference between a test bug and a product bug in the eyes of the gatekeeper. Both are considered integration blockers and both should be handled asap when appearing in the testing.
When a change is identified that causes a regression and the best way to handle it is to back out the change, anyone can do so. It will still go through the standard code review process, but is considered a trivial change and thus it requires only one Reviewer and will avoid the 24h code review window. The idea here is to save time by not having a broken change hindering others. There is also the rationale that the change itself is automatically created by hg, and reviewed by the person who is performing the backout, so only one additional reviewer is required.
There are two parts to this task, how to do the bookkeeping in JBS, and how to do the actual backout in mercurial.
In order to backout a change, the hg backout command is recommended, which essentially applies the anti delta of the change. Make sure you perform the backout in the most upstream repostiory the change has escaped to.
hg backout [OPTION]... [-r] REV
reverse effect of earlier changeset
Prepare a new changeset with the effect of REV undone in the current
working directory.
If REV is the parent of the working directory, then this new changeset is
committed automatically. Otherwise, hg needs to merge the changes and the
merged result is left uncommitted.
To remove noise from our testing, tests that are expected to fail are quarantined or excluded. A quarantined test is removed from standard runs, but run in a separate job. Excluded tests are not run.
Test quarantines are done in the file ProblemList.txt while exclusions shall be done in the source code using @ignore. This enables adhoc runs on local machines, it makes it possible to go back in time and get expected results, and (for good and bad) by being part of the standard code review process the visibility increases. For each quarantine and exclude, there should of course be a corresponding bug, which is referenced in the quarantine.
Use ProblemList.txt and exclude the test in the known issues ignore list.
Example where MyTest.java is excluded on windows, tracked by bug JDK-4711:
sun.tools.jcmd.MyTest.java 4711 windows-all |
Use @Ignore with a bug reference in the test case, to prevent the test from being run.
Example where MyTest.java is excluded, tracked by bug JDK-4711:
/** * @test * @ignore 4711 * |
@ignore should always be placed directly before the first @run line in the test.
Dealing with JBS bugs for test exclusion
With the quarantine/exclude mechanism in the source code, a check-in into the repository is needed, which means a unique JBS issue and a code review is needed. This is a good thing since it makes the test problems visible.
Triage quarantined issues
Who looks at quarantine batches?
Any rule, any process has exceptions. And in some cases it is better to live with a potential failure and integrate anyway. It should of course be used in rare cases only, for example when it is more important to continue to run the test, and thus at the same time accept the failure. A typical example is an intermittent failure like an intermittent crash (say once a month) in a large system test, or if more info is needed, possibly diagnostics are added to the test, and the risk of not running it is high.
Label the bug with hs-nightly-quarantine-exception.
There are a few ways to figure out if a problem has already escaped a repository:
A bug that has escaped to an upstream repository should be fixed in the upstream repository
jdk/hs, the fix/backout/quarantine should be done in jdk/hs to avoid blocking integration for other Hotspot changes. If a bug escapes jdk/hs into jdk/jdk the fix must go into jdk/jdk.This page is deprecated and it's content is either old or being moved to the OpenJDK Developers' Guide. Please update your links.
Most HotSpot development work is done in jdk/hs. Larger projects are recommended to use a project repository which is synced with jdk/hs on a regular basis.
When is a change integrated?
Changes in jdk/hs are bulk integrated to jdk/jdk once a week. A change in HotSpot will go through these steps on the way to jdk/jdk:
hg pushhg push)All in all this means that if you need a change to be in master at a specific date, you need to make sure your change is pushed to jdk/hs in time to go through the PIT and be pushed to master before the actual date.
What is an integration blocker?
An integration blocker is a bug that is present in a repository, but has not yet spread to the upstream repository. We want to make sure not to spread problems, so if there are new failures in a repository, hold upstream integration.
There is a JBS label that is used to help keep track of bugs that are blocking integration, integration_blocker.
Never integrate if there are open integration blockers
Use the JBS filter Hotspot Integration blockers to find out if there are any blockers.
If a main bug is targeted to a release and the fix is pushed to a different release, then a backport bug is automatically created. Usually this is a "good thing", e.g., when you are really backporting a fix to an earlier release, but not always... If the main bug is targeted to a later release (due to schedule planning), but someone finds the time to fix that bug in the current release, then the bug should be retargeted to the current release before pushing the fix. However, sometimes we forget to do that.
Here is how to fix that:
In this example a fix was pushed to JDK 10 (a.k.a. the current release) while the JBS bug was targeted to JDK 11 (a.k.a. a future release).
Use a comment like the following (in the reopen dialog):
Copy the open push notification comment from the backport bug to the main bug, e.g.:
Add a comment like the following to the main bug:
There are several ways to find out if a change has been integrated to jdk/jdk or not. The easiest way is probably to look at the mercurial log in jdk/jdk and see if your change is there:
hg log | grep 1234567
Or, if you don't have a recent clone of jdk/jdk available, look at http://hg.openjdk.java.net/jdk/jdk/
This information is no longer relevant.
Terms *
Trademarks *
License: GPLv2 *
Contact Us *
Privacy
Powered by a free Atlassian Confluence Open Source Project License granted to Oracle. Evaluate Confluence today.