From 925cf178c880b7fabc1ecc8e0e5bca8cad9f5d9c Mon Sep 17 00:00:00 2001 From: hengyunabc Date: Wed, 25 Sep 2024 14:18:29 +0800 Subject: [PATCH] update one.profiler --- .../main/java/one/profiler/AsyncProfiler.java | 17 +++-------------- .../java/one/profiler/AsyncProfilerMXBean.java | 17 +++-------------- core/src/main/java/one/profiler/Counter.java | 17 +++-------------- core/src/main/java/one/profiler/Events.java | 18 ++++-------------- 4 files changed, 13 insertions(+), 56 deletions(-) diff --git a/core/src/main/java/one/profiler/AsyncProfiler.java b/core/src/main/java/one/profiler/AsyncProfiler.java index 9a1514388c3..d077f49e498 100644 --- a/core/src/main/java/one/profiler/AsyncProfiler.java +++ b/core/src/main/java/one/profiler/AsyncProfiler.java @@ -1,17 +1,6 @@ /* - * Copyright 2018 Andrei Pangin - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. + * Copyright The async-profiler authors + * SPDX-License-Identifier: Apache-2.0 */ package one.profiler; @@ -283,4 +272,4 @@ private void filterThread(Thread thread, boolean enable) { private native String execute0(String command) throws IllegalArgumentException, IllegalStateException, IOException; private native void filterThread0(Thread thread, boolean enable); -} +} \ No newline at end of file diff --git a/core/src/main/java/one/profiler/AsyncProfilerMXBean.java b/core/src/main/java/one/profiler/AsyncProfilerMXBean.java index 90abf830c7a..5210c647b09 100644 --- a/core/src/main/java/one/profiler/AsyncProfilerMXBean.java +++ b/core/src/main/java/one/profiler/AsyncProfilerMXBean.java @@ -1,17 +1,6 @@ /* - * Copyright 2018 Andrei Pangin - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. + * Copyright The async-profiler authors + * SPDX-License-Identifier: Apache-2.0 */ package one.profiler; @@ -40,4 +29,4 @@ public interface AsyncProfilerMXBean { String dumpCollapsed(Counter counter); String dumpTraces(int maxTraces); String dumpFlat(int maxMethods); -} +} \ No newline at end of file diff --git a/core/src/main/java/one/profiler/Counter.java b/core/src/main/java/one/profiler/Counter.java index 489053b7290..0d0ec1160cc 100644 --- a/core/src/main/java/one/profiler/Counter.java +++ b/core/src/main/java/one/profiler/Counter.java @@ -1,17 +1,6 @@ /* - * Copyright 2018 Andrei Pangin - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. + * Copyright The async-profiler authors + * SPDX-License-Identifier: Apache-2.0 */ package one.profiler; @@ -22,4 +11,4 @@ public enum Counter { SAMPLES, TOTAL -} +} \ No newline at end of file diff --git a/core/src/main/java/one/profiler/Events.java b/core/src/main/java/one/profiler/Events.java index 1731122c725..677c0e4140f 100644 --- a/core/src/main/java/one/profiler/Events.java +++ b/core/src/main/java/one/profiler/Events.java @@ -1,17 +1,6 @@ /* - * Copyright 2018 Andrei Pangin - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. + * Copyright The async-profiler authors + * SPDX-License-Identifier: Apache-2.0 */ package one.profiler; @@ -24,5 +13,6 @@ public class Events { public static final String ALLOC = "alloc"; public static final String LOCK = "lock"; public static final String WALL = "wall"; + public static final String CTIMER = "ctimer"; public static final String ITIMER = "itimer"; -} +} \ No newline at end of file