>From Ali Alsuliman <[email protected]>:

Ali Alsuliman has submitted this change. ( 
https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17983 )

Change subject: [NO ISSUE] Use getClass().getName() instead of 
getClass().getSimpleName()
......................................................................

[NO ISSUE] Use getClass().getName() instead of getClass().getSimpleName()

- user model changes: no
- storage format changes: no
- interface changes: no

Details:
Use getClass().getName() instead of getClass().getSimpleName()
when logging closable failures to include anonymous classes.

Change-Id: I5e6e056000f7162e00e25a3b071c6ba1156cff6b
Reviewed-on: https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17983
Integration-Tests: Jenkins <[email protected]>
Tested-by: Jenkins <[email protected]>
Reviewed-by: Michael Blow <[email protected]>
---
M 
hyracks-fullstack/hyracks/hyracks-api/src/main/java/org/apache/hyracks/api/util/CleanupUtils.java
1 file changed, 24 insertions(+), 3 deletions(-)

Approvals:
  Michael Blow: Looks good to me, approved
  Jenkins: Verified; Verified
  Anon. E. Moose #1000171:




diff --git 
a/hyracks-fullstack/hyracks/hyracks-api/src/main/java/org/apache/hyracks/api/util/CleanupUtils.java
 
b/hyracks-fullstack/hyracks/hyracks-api/src/main/java/org/apache/hyracks/api/util/CleanupUtils.java
index 220311e..a29a04a 100644
--- 
a/hyracks-fullstack/hyracks/hyracks-api/src/main/java/org/apache/hyracks/api/util/CleanupUtils.java
+++ 
b/hyracks-fullstack/hyracks/hyracks-api/src/main/java/org/apache/hyracks/api/util/CleanupUtils.java
@@ -67,7 +67,7 @@
             } catch (Throwable th) { // NOSONAR Will be suppressed
                 try {
                     LOGGER.log(ExceptionUtils.causedByInterrupt(th) ? 
Level.DEBUG : Level.WARN,
-                            "Failure closing a closeable resource of class 
{}", writer.getClass().getSimpleName(), th);
+                            "Failure closing a closeable resource of class 
{}", writer.getClass().getName(), th);
                 } catch (Throwable loggingFailure) { // NOSONAR: Ignore 
catching Throwable
                     // NOSONAR: Ignore logging failure
                 }
@@ -92,7 +92,7 @@
         } catch (Throwable th) { // NOSONAR Will be suppressed
             try {
                 LOGGER.log(ExceptionUtils.causedByInterrupt(th) ? Level.DEBUG 
: Level.WARN,
-                        "Failure failing " + 
writer.getClass().getSimpleName(), th);
+                        "Failure failing " + writer.getClass().getName(), th);
             } catch (Throwable loggingFailure) { // NOSONAR: Ignore catching 
Throwable
                 // NOSONAR ignore logging failure
             }
@@ -119,7 +119,7 @@
             } catch (Throwable th) { // NOSONAR Will be suppressed
                 try {
                     LOGGER.log(ExceptionUtils.causedByInterrupt(th) ? 
Level.DEBUG : Level.WARN,
-                            "Failure closing a closeable resource", th);
+                            "Failure closing a closeable resource {}", 
closable.getClass().getName(), th);
                 } catch (Throwable loggingFailure) { // NOSONAR: Ignore 
catching Throwable
                     // NOSONAR ignore logging failure
                 }

--
To view, visit https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17983
To unsubscribe, or for help writing mail filters, visit 
https://asterix-gerrit.ics.uci.edu/settings

Gerrit-Project: asterixdb
Gerrit-Branch: trinity
Gerrit-Change-Id: I5e6e056000f7162e00e25a3b071c6ba1156cff6b
Gerrit-Change-Number: 17983
Gerrit-PatchSet: 2
Gerrit-Owner: Ali Alsuliman <[email protected]>
Gerrit-Reviewer: Ali Alsuliman <[email protected]>
Gerrit-Reviewer: Anon. E. Moose #1000171
Gerrit-Reviewer: Jenkins <[email protected]>
Gerrit-Reviewer: Michael Blow <[email protected]>
Gerrit-MessageType: merged

Reply via email to