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

Fix PID instrumentation for configuration caching #238

Merged
merged 5 commits into from
Sep 4, 2020

Conversation

wolfs
Copy link
Member

@wolfs wolfs commented Sep 3, 2020

Use a build service for PID instrumentation on Gradle versions >= 6.1, so the PID collector is
compatible with configuration caching.

on Gradle versions >= 6.1, so the PID collector is
compatible with configuration caching.
@wolfs wolfs self-assigned this Sep 3, 2020
@wolfs wolfs added this to the 0.15.0 milestone Sep 3, 2020
@wolfs wolfs changed the title Use build service to collect the PID Fix PID instrumentation for configuration caching Sep 3, 2020
@wolfs wolfs added the bug label Sep 3, 2020
@wolfs wolfs marked this pull request as ready for review September 3, 2020 21:44
GFileUtils.writeFile(getPid().toString(), getParameters().getPidFile().get().getAsFile());
}

private Integer getPid() throws NoSuchFieldException, IllegalAccessException, NoSuchMethodException, InvocationTargetException {
Copy link
Member Author

Choose a reason for hiding this comment

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

I am not very happy with how we obtain the PID of the current process here, though I don't have a better idea :(.

Copy link
Contributor

Choose a reason for hiding this comment

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

I guess no better solution on Java 8.

@@ -16,7 +16,7 @@ abstract class AbstractProfilerIntegrationTest extends Specification {
"3.3", "3.4.1", "3.5",
"4.0", "4.1", "4.2.1", "4.7",
"5.2.1", "5.5.1", "5.6.3",
"6.0.1", "6.1", "6.6-rc-2"
"6.0.1", "6.1", "6.6"
Copy link
Contributor

Choose a reason for hiding this comment

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

6.6.1?

Copy link
Member Author

Choose a reason for hiding this comment

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

Done. I also upgradled the build to 6.6.1.

Copy link
Contributor

@blindpirate blindpirate left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for fixing!

@wolfs wolfs merged commit 66abbb1 into master Sep 4, 2020
@wolfs wolfs deleted the wolfs/pid-for-config-cache branch September 4, 2020 12:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants