class VerifyMerkleTreeActionHandler extends ActionHandler {

    @Override
    public ItemStatus execute(WorkerParameters params, HandlerIO handler) {

        final ItemStatus itemStatus = new ItemStatus(HANDLER_ID);

        InputStream operationsInputStream = null;
        try {

            // 1- Get TraceabilityEventDetail from Workspace
            TraceabilityEvent traceabilityEvent =
                JsonHandler.getFromFile((File) handler.getInput(TRACEABILITY_EVENT_DETAIL_RANK),
                    TraceabilityEvent.class);

            // 2- Get data.txt file
            String operationFilePath = SedaConstants.TRACEABILITY_OPERATION_DIRECTORY + "/" +
                DATA_FILE;
            operationsInputStream = handler.getInputStreamFromWorkspace(operationFilePath);

            // 3- Calculate MerkelTree hash

            // TODO Get digest algorithm from traceabilityEvent object
            MerkleTreeAlgo merkleTreeAlgo = computeMerkleTree(operationsInputStream);

            // calculates hash
            final String currentRootHash = currentRootHash(merkleTreeAlgo);

            // compare to secured and indexed hash
            final ItemStatus subSecuredItem = compareToSecuredHash( handler, currentRootHash);
            itemStatus.setItemsStatus(HANDLER_SUB_ACTION_COMPARE_WITH_SAVED_HASH, subSecuredItem);

            final ItemStatus subLoggedItemStatus = compareToLoggedHash(params, currentRootHash, traceabilityEvent);
            itemStatus.setItemsStatus(HANDLER_SUB_ACTION_COMPARE_WITH_INDEXED_HASH, subLoggedItemStatus);

        } catch (Exception e) {
            LOGGER.error(e);
            itemStatus.increment(StatusCode.FATAL);
        } finally {
        	IOUtils.closeQuietly(operationsInputStream);
        }

        return new ItemStatus(HANDLER_ID).setItemsStatus(HANDLER_ID, itemStatus);
    }

}