public static ShowResultSet execute(ShowStmt statement, ConnectContext context) {
        return GlobalStateMgr.getCurrentState().getShowExecutor().showExecutorVisitor.visit(statement, context);
    }
@Test
    public void testShowBackendsSharedDataMode(@Mocked StarOSAgent starosAgent) {
        SystemInfoService clusterInfo = AccessTestUtil.fetchSystemInfoService();

        // mock backends
        Backend backend = new Backend(1L, "127.0.0.1", 12345);
        backend.setCpuCores(16);
        backend.setMemLimitBytes(100L);
        backend.updateResourceUsage(0, 1L, 30);
        backend.setAlive(false);
        clusterInfo.addBackend(backend);

        NodeMgr nodeMgr = new NodeMgr();
        new Expectations(nodeMgr) {
            {
                nodeMgr.getClusterInfo();
                minTimes = 0;
                result = clusterInfo;
            }
        };

        WarehouseManager warehouseManager = new WarehouseManager();
        warehouseManager.initDefaultWarehouse();
        new Expectations(globalStateMgr) {
            {
                globalStateMgr.getNodeMgr();
                minTimes = 0;
                result = nodeMgr;

                globalStateMgr.getStarOSAgent();
                minTimes = 0;
                result = starosAgent;

                globalStateMgr.getWarehouseMgr();
                minTimes = 0;
                result = warehouseManager;
            }
        };

        new MockUp<RunMode>() {
            @Mock
            RunMode getCurrentRunMode() {
                return RunMode.SHARED_DATA;
            }
        };

        long tabletNum = 1024;
        long workerId = 1122;
        new Expectations() {
            {
                starosAgent.getWorkerTabletNum(anyString);
                minTimes = 1;
                result = tabletNum;

                starosAgent.getWorkerIdByNodeId(anyLong);
                minTimes = 1;
                result = workerId;
            }
        };

        ShowBackendsStmt stmt = new ShowBackendsStmt();

        ShowResultSet resultSet = ShowExecutor.execute(stmt, ctx);

        Assert.assertEquals(33, resultSet.getMetaData().getColumnCount());
        Assert.assertEquals("BackendId", resultSet.getMetaData().getColumn(0).getName());
        Assert.assertEquals("CpuCores", resultSet.getMetaData().getColumn(22).getName());
        Assert.assertEquals("MemLimit", resultSet.getMetaData().getColumn(23).getName());
        Assert.assertEquals("NumRunningQueries", resultSet.getMetaData().getColumn(24).getName());
        Assert.assertEquals("MemUsedPct", resultSet.getMetaData().getColumn(25).getName());
        Assert.assertEquals("CpuUsedPct", resultSet.getMetaData().getColumn(26).getName());
        Assert.assertEquals("DataCacheMetrics", resultSet.getMetaData().getColumn(27).getName());
        Assert.assertEquals("StatusCode", resultSet.getMetaData().getColumn(29).getName());
        Assert.assertEquals("StarletPort", resultSet.getMetaData().getColumn(30).getName());
        Assert.assertEquals("WorkerId", resultSet.getMetaData().getColumn(31).getName());

        Assert.assertTrue(resultSet.next());
        Assert.assertEquals("1", resultSet.getString(0));

        Assert.assertEquals("16", resultSet.getString(22));
        Assert.assertEquals("100.000B", resultSet.getString(23));
        Assert.assertEquals("0", resultSet.getString(24));
        Assert.assertEquals("N/A", resultSet.getString(27));
        Assert.assertEquals("DISCONNECTED", resultSet.getString(29));
        Assert.assertEquals(String.valueOf(workerId), resultSet.getString(31));
        Assert.assertEquals(String.valueOf(tabletNum), resultSet.getString(11));
    }