pabloem commented on a change in pull request #13792:
URL: https://github.com/apache/beam/pull/13792#discussion_r564120163



##########
File path: 
sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/healthcare/FhirIO.java
##########
@@ -1556,10 +1571,16 @@ public SearchResourcesJsonString(ValueProvider<String> 
fhirStore) {
       /** DoFn for searching messages from the Fhir store with error handling. 
*/
       class SearchResourcesFn extends DoFn<KV<String, Map<String, T>>, 
JsonArray> {
 
-        private Distribution searchLatencyMs =
-            Metrics.distribution(SearchResourcesFn.class, 
"fhir-search-latency-ms");
-        private Counter failedSearches =
-            Metrics.counter(SearchResourcesFn.class, "failed-fhir-searches");
+        private final Counter SEARCH_RESOURCE_ERRORS =
+            Metrics.counter(
+                SearchResourcesFn.class, BASE_METRIC_PREFIX + 
"search_resource_error_count");
+        private final Counter SEARCH_RESOURCE_SUCCESS =
+            Metrics.counter(
+                SearchResourcesFn.class, BASE_METRIC_PREFIX + 
"search_resource_success_count");
+        private final Distribution SEARCH_RESOURCE_LATENCY_MS =

Review comment:
       Oh there seems to be a style error for these variables. They should be 
static, or not capitalized. fyi: @msbukal 
   
   ```
   [ant:checkstyle] [ERROR] 
/home/jenkins/jenkins-slave/workspace/beam_PreCommit_Java_Phrase/src/sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/healthcare/FhirIO.java:1614:31:
 Name 'SEARCH_RESOURCE_ERRORS' must match pattern '^[a-z][a-zA-Z0-9]*$'. 
[MemberName] |  
     | [ant:checkstyle] [ERROR] 
/home/jenkins/jenkins-slave/workspace/beam_PreCommit_Java_Phrase/src/sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/healthcare/FhirIO.java:1617:31:
 Name 'SEARCH_RESOURCE_SUCCESS' must match pattern '^[a-z][a-zA-Z0-9]*$'. 
[MemberName] |  
     | [ant:checkstyle] [ERROR] 
/home/jenkins/jenkins-slave/workspace/beam_PreCommit_Java_Phrase/src/sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/healthcare/FhirIO.java:1620:36:
 Name 'SEARCH_RESOURCE_LATENCY_MS' must match pattern '^[a-z][a-zA-Z0-9]*$'. 
[MemberName]
   ```
   
   Usually, when a unit test fails, it is displayed directly in Jenkins. In 
this case it wasn't, because it was something else failing.
   
   To find these kinds of errors, you can open PreCommit, and then open the 
Gradle Build Scan, which will point you to the failing task.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to