diff --git a/CHANGELOG.md b/CHANGELOG.md index 45c090c0..118d209b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -32,6 +32,9 @@ Dropping a requirement of a major version of a dependency is a new contract. - `jfr` and `flamegraph` for convenience - `startParams` and `stopParams` for extensibility +### Deprecated +- Deprecate `AsyncProfiler.Builder.extraParams` in favor of `startParams` due to ambiguity with `stopParams`. + [JPERF-1390]: https://ecosystem.atlassian.net/browse/JPERF-1390 ## [4.27.0] - 2023-10-09 diff --git a/src/main/kotlin/com/atlassian/performance/tools/infrastructure/api/profiler/AsyncProfiler.kt b/src/main/kotlin/com/atlassian/performance/tools/infrastructure/api/profiler/AsyncProfiler.kt index 54a77f70..262f179f 100644 --- a/src/main/kotlin/com/atlassian/performance/tools/infrastructure/api/profiler/AsyncProfiler.kt +++ b/src/main/kotlin/com/atlassian/performance/tools/infrastructure/api/profiler/AsyncProfiler.kt @@ -103,8 +103,8 @@ class AsyncProfiler private constructor( this.startParams.addAll(startParams) } - fun stopParams(vararg extraParams: String) = apply { - this.stopParams.addAll(extraParams) + fun stopParams(vararg stopParams: String) = apply { + this.stopParams.addAll(stopParams) } fun build(): Profiler { diff --git a/src/test/kotlin/com/atlassian/performance/tools/infrastructure/api/profiler/AsyncProfilerIT.kt b/src/test/kotlin/com/atlassian/performance/tools/infrastructure/api/profiler/AsyncProfilerIT.kt index d08447c1..39e8d24c 100644 --- a/src/test/kotlin/com/atlassian/performance/tools/infrastructure/api/profiler/AsyncProfilerIT.kt +++ b/src/test/kotlin/com/atlassian/performance/tools/infrastructure/api/profiler/AsyncProfilerIT.kt @@ -73,7 +73,7 @@ class AsyncProfilerIT { // then val profilerResult = RemotePath(sshClient.host, process.getResultPath()) - .download(createTempFile("profiler-result", ".svg")) + .download(createTempFile("profiler-result", ".tmp")) resultAssert(profilerResult) } }