-
Notifications
You must be signed in to change notification settings - Fork 2k
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
CheckStyle-Rule-Extension: 6, 7, 8 #4339
Conversation
mssfang
commented
Jul 9, 2019
•
edited
Loading
edited
- Check 6: @ServiceClientBuilder
- All service client builder should be named ClientBuilder and annotated with @ServiceClientBuilder.
- Has a method 'buildClient()' to build a synchronous client,
- Has a method 'buildAsyncClient()' to build an asynchronous client
- Check 7: @ServiceInterface
- The annotation property 'name' should be non-empty
- The length of value of property 'name' should be less than 20 characters and without space
- Check 8: No OpenCensus dependency
- OpenCensus should only be depended on from within the tracing-opencensus module. It should not be used in any other class throughout the Java SDK.
…into CS-Rule-ServiceClient-Instantiation
…into CS-Rule-ServiceClient-Instantiation
…into CS-Rule-ServiceClient-Instantiation
…into CS-Rule-ServiceClient-Instantiation
…into CS-Rule-ServiceClient-Instantiation
…into CS-Rule-ServiceClient-Instantiation
…into CS-Rule-Builder-Interface
No 9 is still experiencing the IO exception failed which is the same problem about reflection. But the existing rule implementation is ready for review. |
core/azure-core/src/main/java/com/azure/core/implementation/RestProxy.java
Outdated
Show resolved
Hide resolved
core/azure-core/src/main/java/com/azure/core/implementation/RestProxy.java
Outdated
Show resolved
Hide resolved
...ality-reports/src/main/java/com/azure/tools/checkstyle/checks/ServiceClientBuilderCheck.java
Outdated
Show resolved
Hide resolved
...quality-reports/src/main/java/com/azure/tools/checkstyle/checks/ThrownClientLoggerCheck.java
Outdated
Show resolved
Hide resolved
I think these checks might have to be split up into another PR. (ie. Check 9 about logAndThrow will result in a PR that touches many files.) |
d6d9dee
to
aba32d2
Compare
Cleaned up and ready for review again. :> |
...ality-reports/src/main/java/com/azure/tools/checkstyle/checks/ServiceClientBuilderCheck.java
Outdated
Show resolved
Hide resolved
...e-quality-reports/src/main/java/com/azure/tools/checkstyle/checks/ServiceInterfaceCheck.java
Outdated
Show resolved
Hide resolved
...ality-reports/src/main/java/com/azure/tools/checkstyle/checks/ServiceClientBuilderCheck.java
Outdated
Show resolved
Hide resolved
…into CS-Rule-Builder-Interface
PR is ready for reviewing again |
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.
Approved with one change requested first.
.../azure-keyvault-secrets/src/main/java/com/azure/security/keyvault/secrets/SecretService.java
Outdated
Show resolved
Hide resolved
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.
LGTM