Ted Yu created ACCUMULO-2327:
--------------------------------

             Summary: Better handling of NoSuchMethodException in 
DfsLogger#open()
                 Key: ACCUMULO-2327
                 URL: https://issues.apache.org/jira/browse/ACCUMULO-2327
             Project: Accumulo
          Issue Type: Task
            Reporter: Ted Yu


Currently NoSuchMethodException is ignored in the open method:
{code}
        try {
          // hsync: send data to datanodes and sync the data to disk
          sync = logFile.getClass().getMethod("hsync");
          e = null;
        } catch (NoSuchMethodException ex) {}
{code}
Since logFile.getClass() would be the same for one log file, we can use boolean 
field to indicate whether hsync is supported so that we don't call hsync again 
and again if hsync is not supported.

A log statement for NoSuchMethodException would be desirable too.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Reply via email to