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
feat(language-service): add perf tracing to LanguageService #41401
Conversation
Note to caretaker: this should not require presubmit, since it does not affect google3 |
@alxhub technically we're not supposed to merge features into patch because of semantic versioning. The commit message uses It doesn't seem like a big deal in this case, and I wouldn't consider perf logging to be a full feature. |
Adding the "blocked" label for now, since the commit message refers to this change as a feature, but we can not merge features into patch branch (and make them available in patch versions) according to SemVer. |
Adds perf tracing for the public methods in LanguageService. If the log level is verbose or higher, trace performance results to the tsServer logger. This logger is implemented on the extension side in angular/vscode-ng-language-service.
fde57b4
to
650d206
Compare
this.compilerFactory.registerLastKnownProgram(); | ||
|
||
const logger = this.project.projectService.logger; |
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.
const logger = this.project.projectService.logger; | |
const {logger} = this.project.projectService; |
|
||
const logger = this.project.projectService.logger; | ||
if (logger.hasLevel(ts.server.LogLevel.verbose)) { | ||
logger.perftrc(`LanguageService#${PerfPhase[phase]}: ${ |
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.
logger.perftrc(`LanguageService#${PerfPhase[phase]}: ${ | |
logger.perftrc(`NgLanguageService#${PerfPhase[phase]}: ${ |
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.
or just NGLS? TypeScript's language service also logs to the same file, it's better to differentiate the two.
Since there's no change in user facing features, I suggest we rename the commit to |
Closed by commit 7b0a800 |
Adds perf tracing for the public methods in LanguageService. If the log level is verbose or higher, trace performance results to the tsServer logger. This logger is implemented on the extension side in angular/vscode-ng-language-service. PR Close #41401
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Adds perf tracing for the public methods in LanguageService. If the log level is verbose or higher,
trace performance results to the tsServer logger. This logger is implemented on the extension side
in angular/vscode-ng-language-service.