@Override
    public TImmutablePartitionResult updateImmutablePartition(TImmutablePartitionRequest request) throws TException {
        LOG.info("Receive update immutable partition: {}", request);

        TImmutablePartitionResult result;
        try {
            result = updateImmutablePartitionInternal(request);
        } catch (Throwable t) {
            LOG.warn(t.getMessage(), t);
            result = new TImmutablePartitionResult();
            TStatus errorStatus = new TStatus(RUNTIME_ERROR);
            errorStatus.setError_msgs(Lists.newArrayList(String.format("txn_id=%d failed. %s",
                    request.getTxn_id(), t.getMessage())));
            result.setStatus(errorStatus);
        }

        LOG.info("Finish update immutable partition: {}", result);

        return result;
    }
@Test
    public void testUpdateImmutablePartitionException() throws TException {
        new MockUp<FrontendServiceImpl>() {
            @Mock
            public synchronized TImmutablePartitionResult updateImmutablePartitionInternal(
                    TImmutablePartitionRequest request) {
                throw new RuntimeException("test");
            }
        };

        FrontendServiceImpl impl = new FrontendServiceImpl(exeEnv);
        TImmutablePartitionRequest request = new TImmutablePartitionRequest();
        TImmutablePartitionResult partition = impl.updateImmutablePartition(request);
        Assert.assertEquals(partition.getStatus().getStatus_code(), TStatusCode.RUNTIME_ERROR);
    }