-
Notifications
You must be signed in to change notification settings - Fork 47
Support Async Profiler Feature #203
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
Merged
Merged
Changes from 23 commits
Commits
Show all changes
27 commits
Select commit
Hold shift + click to select a range
d2355a0
feat: add asyncprofiler support
37550c6
fix: alias
8e10fe0
feat: support asyncprofiler
50b7ba4
Merge branch 'master' into master
mrproliu 5694b3a
Update assets/graphqls/profiling/asyncprofiler/GetTaskList.graphql
zhengziyi0117 b8af7e4
Update internal/commands/profiling/asyncprofiler/getAnalyze.go
zhengziyi0117 ecd88bd
fix: license header
54d3486
Merge remote-tracking branch 'origin/master'
071d2f1
Update internal/commands/profiling/asyncprofiler/getTaskProgress.go
zhengziyi0117 ddb13fa
Merge remote-tracking branch 'origin/master'
693a787
fix: pr comment
d4222fb
fix: license header
5a38d58
fix: license header
4e144c7
fix: license header
ac0314b
test: golint version
d9e2e71
test: golint version
8395933
fix: go ci lint
63167d9
feat: add instanceSlice interceptor
3eedb05
feat: update CHANGES.md
8a00dee
fix style and lint
lujiajing1126 0f6665c
fix: golint
5f9bdc0
fix: golint
ba0d366
fix: command test ci
c1b9519
fix: arguments name
a20535e
fix: arguments name
b4c5cf7
fix dependency test cases
lujiajing1126 9593efc
fix trace cases
lujiajing1126 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
assets/graphqls/profiling/asyncprofiler/CreateTask.graphql
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,24 @@ | ||
| # Licensed to Apache Software Foundation (ASF) under one or more contributor | ||
| # license agreements. See the NOTICE file distributed with | ||
| # this work for additional information regarding copyright | ||
| # ownership. Apache Software Foundation (ASF) licenses this file to you 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. | ||
|
|
||
| mutation ($condition: AsyncProfilerTaskCreationRequest!) { | ||
| result: createAsyncProfilerTask(asyncProfilerTaskCreationRequest: $condition) { | ||
| errorReason | ||
| code | ||
| id | ||
| } | ||
| } |
31 changes: 31 additions & 0 deletions
31
assets/graphqls/profiling/asyncprofiler/GetAnalysis.graphql
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,31 @@ | ||
| # Licensed to Apache Software Foundation (ASF) under one or more contributor | ||
| # license agreements. See the NOTICE file distributed with | ||
| # this work for additional information regarding copyright | ||
| # ownership. Apache Software Foundation (ASF) licenses this file to you 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. | ||
|
|
||
| query ($condition: AsyncProfilerAnalyzationRequest!) { | ||
| result: queryAsyncProfilerAnalyze(request: $condition) { | ||
| tree { | ||
| type | ||
| elements { | ||
| id | ||
| parentId | ||
| codeSignature | ||
| total | ||
| self | ||
| } | ||
| } | ||
| } | ||
| } |
31 changes: 31 additions & 0 deletions
31
assets/graphqls/profiling/asyncprofiler/GetTaskList.graphql
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,31 @@ | ||
| # Licensed to Apache Software Foundation (ASF) under one or more contributor | ||
| # license agreements. See the NOTICE file distributed with | ||
| # this work for additional information regarding copyright | ||
| # ownership. Apache Software Foundation (ASF) licenses this file to you 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. | ||
|
|
||
| query ($condition: AsyncProfilerTaskListRequest!) { | ||
| result: queryAsyncProfilerTaskList(request: $condition) { | ||
| errorReason | ||
| tasks { | ||
| serviceId | ||
| serviceInstanceIds | ||
| createTime | ||
| events | ||
| duration | ||
| execArgs | ||
| id | ||
| } | ||
| } | ||
| } |
30 changes: 30 additions & 0 deletions
30
assets/graphqls/profiling/asyncprofiler/GetTaskProgress.graphql
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| # Licensed to Apache Software Foundation (ASF) under one or more contributor | ||
| # license agreements. See the NOTICE file distributed with | ||
| # this work for additional information regarding copyright | ||
| # ownership. Apache Software Foundation (ASF) licenses this file to you 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. | ||
|
|
||
| query ($taskId: String!){ | ||
| result: queryAsyncProfilerTaskProgress(taskId: $taskId) { | ||
| errorInstanceIds | ||
| successInstanceIds | ||
| logs { | ||
| id | ||
| instanceId | ||
| instanceName | ||
| operationType | ||
| operationTime | ||
| } | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
internal/commands/profiling/asyncprofiler/asyncprofiler.go
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,34 @@ | ||
| // Licensed to Apache Software Foundation (ASF) under one or more contributor | ||
| // license agreements. See the NOTICE file distributed with | ||
| // this work for additional information regarding copyright | ||
| // ownership. Apache Software Foundation (ASF) licenses this file to you 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. | ||
|
|
||
| package asyncprofiler | ||
|
|
||
| import "github.com/urfave/cli/v2" | ||
|
|
||
| var Command = &cli.Command{ | ||
| Name: "async", | ||
| Usage: "async profiler related sub-command", | ||
| UsageText: `If your endpoint has performance issue and could not use tracing to find out what's happening, | ||
| you could try it. You could get more information | ||
| on https://skywalking.apache.org/docs/main/next/en/concepts-and-designs/profiling.`, | ||
| Subcommands: []*cli.Command{ | ||
| createCommand, | ||
| getTaskListCommand, | ||
| getTaskProgressCommand, | ||
| analysisCommand, | ||
| }, | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We usually use "list" instant of "slice"