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

gnostic-complexity: new plugin that computes simple complexity metrics #179

Merged
merged 2 commits into from
Jun 4, 2020

Conversation

timburks
Copy link
Contributor

@timburks timburks commented Jun 2, 2020

This PR adds a new plugin that computes simple complexity metrics for an API that include the number of methods (of each type), schemas, and schema parameters. Metrics are described by a new "standard" proto in gnostic/metrics that can be used to parse complexity metrics in external related tools.

@timburks timburks requested review from noahdietz and LorenzHW June 2, 2020 22:10
@timburks
Copy link
Contributor Author

timburks commented Jun 2, 2020

@noahdietz @LorenzHW I wanted you to see the new metrics directory at the top level - its purpose is to contain protos for various measurements that we might make related to API specs. This PR adds a simple "complexity" metric, and separately @gizzon added a "vocabulary" metric that lists the words used in an API spec. Metrics are computed with plugins, and the protos are here (and public) so that external code can be written to access/display these metrics.

@timburks
Copy link
Contributor Author

timburks commented Jun 4, 2020

Merging. @LorenzHW @noahdietz PTAL at your convenience. Thanks!

@timburks timburks merged commit d95c059 into google:master Jun 4, 2020
@timburks timburks deleted the gnostic-complexity branch June 4, 2020 17:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant