Search in sources :

Example 1 with Shards

use of com.cubrid.cubridmanager.core.shard.model.Shards in project cubrid-manager by CUBRID.

the class HaShardDemo method registerServiceAndBuildInfo.

/**
	 * For HA, right now, we cannot get the host name from CMS, so need
	 * specified by user.
	 *
	 * @param ip
	 * @param port
	 * @param userName
	 * @param password
	 * @param serviceName
	 * @param connectName
	 * @param nodeName Node name that registered in /etc/hosts.
	 * @return
	 */
public void registerServiceAndBuildInfo(String ip, int port, String userName, String password, String serviceName, String connectName, String nodeName) {
    HaShardManager haShardManager = HaShardManager.getInstance();
    //build server info
    ServerInfo serverInfo = ServerManager.getInstance().getServer(ip, port, userName);
    if (serverInfo == null) {
        serverInfo = new ServerInfo();
        serverInfo.setHostAddress(ip);
        serverInfo.setHostMonPort(port);
        serverInfo.setHostJSPort(port + 1);
        serverInfo.setUserName(userName);
    }
    serverInfo.setServerName(connectName);
    serverInfo.setUserPassword(password);
    serverInfo.setJdbcDriverVersion("Auto Detect");
    // connect to server
    addServer(serverInfo);
    MonitoringTask monitoringTask = serverInfo.getMonitoringTask();
    String clientVersion = "9.3.0";
    serverInfo = monitoringTask.connectServer(clientVersion, 1000);
    if (serverInfo.isConnected()) {
        addServer(serverInfo);
        GetDatabasesParameterTask getDatabasesParameterTask = new GetDatabasesParameterTask(serverInfo);
        getDatabasesParameterTask.execute();
        if (!getDatabasesParameterTask.isSuccess()) {
            return;
        }
        List<Map<String, String>> dbParamMapList = getDatabasesParameterTask.getConfParameters();
        List<DbLocationInfo> dbLocationInfoList = new ArrayList<DbLocationInfo>();
        CMServiceAnalysisUtil.addDbLocaltionInfos(dbParamMapList, dbLocationInfoList);
        // get required info from server and build NodeInfo
        NodeInfo info = getRequiredInfo(serverInfo, dbLocationInfoList);
        if (info != null) {
            info.setDbLocationInfoList(dbLocationInfoList);
            info.setServiceName(serviceName);
            info.setCmConnectName(connectName);
            info.setIp(ip);
            info.setHostName(nodeName);
            info.setServerInfo(serverInfo);
            if (info instanceof ShardNode) {
                Shards shards = ((ShardNode) info).getShards();
                Shard shard = shards.getShardList().get(0);
                List<String> connections = shard.getShardConnectionFile().getConnections();
                for (String s : connections) {
                    String[] ar = s.split(",");
                    if (ip.equals(ar[2]) || nodeName.equals(ar[2])) {
                        //???
                        ((ShardNode) info).setSeverStatus("Shard #" + ar[0]);
                        //???
                        ((ShardNode) info).genStatus();
                    }
                }
            }
            haShardManager.add(info);
        }
    } else {
        removeServer(serverInfo);
    }
}
Also used : ServerInfo(com.cubrid.cubridmanager.core.common.model.ServerInfo) GetDatabasesParameterTask(com.cubrid.cubridmanager.core.common.task.GetDatabasesParameterTask) ArrayList(java.util.ArrayList) ShardNode(com.cubrid.cubridmanager.core.cubrid.service.model.ShardNode) NodeInfo(com.cubrid.cubridmanager.core.cubrid.service.model.NodeInfo) MonitoringTask(com.cubrid.cubridmanager.core.common.task.MonitoringTask) Shards(com.cubrid.cubridmanager.core.shard.model.Shards) Shard(com.cubrid.cubridmanager.core.shard.model.Shard) Map(java.util.Map) DbLocationInfo(com.cubrid.cubridmanager.core.cubrid.service.model.DbLocationInfo)

Example 2 with Shards

use of com.cubrid.cubridmanager.core.shard.model.Shards in project cubrid-manager by CUBRID.

the class HaShardDemo method getShardNodeIndo92.

protected NodeInfo getShardNodeIndo92(ServerInfo serverInfo) {
    ShardNode info = null;
    GetBrokerConfParameterTask getBrokerConfParameterTask = new GetBrokerConfParameterTask(serverInfo);
    getBrokerConfParameterTask.execute();
    if (!getBrokerConfParameterTask.isSuccess()) {
        return null;
    }
    Shards shards = new Shards();
    Map<String, Map<String, String>> confParams = getBrokerConfParameterTask.getConfParameters();
    List<Map<String, String>> shardParamsList = new ArrayList<Map<String, String>>();
    for (Entry<String, Map<String, String>> entry : confParams.entrySet()) {
        String brokerName = entry.getKey();
        Map<String, String> params = entry.getValue();
        if (StringUtils.equalsIgnoreCase(params.get("SHARD"), "ON")) {
            shardParamsList.add(params);
            Shard shard = new Shard();
            shard.setName(brokerName.toLowerCase(Locale.getDefault()));
            shard.setProperties(params);
            ShardConnection shardConnection = new ShardConnection();
            shard.setShardConnectionFile(shardConnection);
            GetShardConfTask<ShardConnection> getShardConnectionConfTask = new GetShardConfTask<ShardConnection>(serverInfo, shardConnection);
            getShardConnectionConfTask.execute();
            getShardConnectionConfTask.loadDataToModel();
            shard.setShardConnectionFile(shardConnection);
            shards.addShard(shard);
        }
    }
    if (shardParamsList.size() == 0) {
        return null;
    }
    info = new ShardNode();
    for (Map<String, String> params : shardParamsList) {
        String shardDbName = params.get("SHARD_DB_NAME");
        info.addDatabase(shardDbName);
    }
    GetDatabaseListTask getDatabaseListTask = new GetDatabaseListTask(serverInfo);
    getDatabaseListTask.execute();
    List<DatabaseInfo> databaseInfoList = getDatabaseListTask.loadDatabaseInfo();
    int shardDbCnt = info.getDatabases().size();
    int matchedCnt = 0;
    for (DatabaseInfo dbInfo : databaseInfoList) {
        for (String dbName : info.getDatabases()) {
            if (dbInfo.getDbName().equals(dbName)) {
                if (DbRunningType.CS.equals(dbInfo.getRunningType())) {
                    info.setDbStatus(dbName, "ON");
                } else {
                    info.setDbStatus(dbName, "OFF");
                }
                matchedCnt++;
                if (shardDbCnt <= matchedCnt) {
                    break;
                } else {
                    continue;
                }
            }
        }
    }
    info.setShards(shards);
    return info;
}
Also used : DatabaseInfo(com.cubrid.cubridmanager.core.cubrid.database.model.DatabaseInfo) ArrayList(java.util.ArrayList) GetShardConfTask(com.cubrid.cubridmanager.core.shard.task.GetShardConfTask) GetDatabaseListTask(com.cubrid.cubridmanager.core.cubrid.database.task.GetDatabaseListTask) ShardNode(com.cubrid.cubridmanager.core.cubrid.service.model.ShardNode) ShardConnection(com.cubrid.cubridmanager.core.shard.model.ShardConnection) GetBrokerConfParameterTask(com.cubrid.cubridmanager.core.broker.task.GetBrokerConfParameterTask) Shards(com.cubrid.cubridmanager.core.shard.model.Shards) Shard(com.cubrid.cubridmanager.core.shard.model.Shard) Map(java.util.Map)

Example 3 with Shards

use of com.cubrid.cubridmanager.core.shard.model.Shards in project cubrid-manager by CUBRID.

the class ShardEnvStatusView method refresh.

/**
	 * Refreshes this view
	 * 
	 * @param isUpdateTable
	 *            whether update table
	 * @param isRefreshChanged
	 *            whether refresh changed
	 * 
	 */
public void refresh() {
    ServerInfo site = cubridNode.getServer().getServerInfo();
    Shards shards = new Shards();
    GetShardConfTask<Shards> getShardConfTask = new GetShardConfTask<Shards>(site, shards);
    getShardConfTask.execute();
    if (!getShardConfTask.isSuccess()) {
        CommonUITool.openErrorBox(getShardConfTask.getErrorMsg());
        return;
    }
    getShardConfTask.loadDataToModel();
    GetShardStatusTask getShardStatusTask = new GetShardStatusTask(site, null);
    getShardStatusTask.execute();
    if (!getShardStatusTask.isSuccess()) {
        CommonUITool.openErrorBox(getShardStatusTask.getErrorMsg());
        return;
    }
    ShardsStatus shardsStatus = getShardStatusTask.getShardsStatus();
    Map<String, ShardStatus> tmpCache = new HashMap<String, ShardStatus>();
    List<ShardStatus> newShardInfoList = shardsStatus.getShardStatuss();
    if (newShardInfoList == null) {
        LOGGER.error("The newShardInfoList is a null.");
        return;
    }
    for (int i = 0; newShardInfoList != null && i < newShardInfoList.size(); i++) {
        ShardStatus shard = newShardInfoList.get(i);
        tmpCache.put(shard.getName(), shard);
    }
    List<Shard> shardList = shards.getShardList();
    for (int i = 0; shardList != null && i < shardList.size(); i++) {
        Shard shard = shardList.get(i);
        ShardStatus newShardInfo = tmpCache.get(shard.getName());
        if (newShardInfo == null) {
            newShardInfo = new ShardStatus();
            newShardInfo.setName(shard.getName());
            newShardInfo.setStatus(OnOffType.OFF.getText());
            newShardInfo.setPort(shard.getValue(CubridShardConfParaConstants.BROKER_PORT));
            newShardInfoList.add(newShardInfo);
        } else {
            newShardInfo.setStatus(OnOffType.ON.getText());
        }
    }
    tableViewer.setInput(newShardInfoList);
    tableViewer.refresh();
}
Also used : ShardStatus(com.cubrid.cubridmanager.core.shard.model.ShardStatus) ShardsStatus(com.cubrid.cubridmanager.core.shard.model.ShardsStatus) HashMap(java.util.HashMap) ServerInfo(com.cubrid.cubridmanager.core.common.model.ServerInfo) GetShardConfTask(com.cubrid.cubridmanager.core.shard.task.GetShardConfTask) Shards(com.cubrid.cubridmanager.core.shard.model.Shards) Shard(com.cubrid.cubridmanager.core.shard.model.Shard) GetShardStatusTask(com.cubrid.cubridmanager.core.shard.task.GetShardStatusTask)

Example 4 with Shards

use of com.cubrid.cubridmanager.core.shard.model.Shards in project cubrid-manager by CUBRID.

the class CubridBrokersFolderLoader method load.

/**
	 * 
	 * Load children object for parent
	 * 
	 * @param parent the parent node
	 * @param monitor the IProgressMonitor object
	 */
public void load(ICubridNode parent, final IProgressMonitor monitor) {
    synchronized (this) {
        if (isLoaded()) {
            return;
        }
        ServerInfo serverInfo = parent.getServer().getServerInfo();
        ServerUserInfo userInfo = serverInfo.getLoginedUserInfo();
        if (userInfo == null || CasAuthType.AUTH_NONE == userInfo.getCasAuth()) {
            parent.removeAllChild();
            CubridNodeManager.getInstance().fireCubridNodeChanged(new CubridNodeChangedEvent((ICubridNode) parent, CubridNodeChangedEventType.CONTAINER_NODE_REFRESH));
            return;
        }
        BrokerInfos brokerInfos = new BrokerInfos();
        final CommonQueryTask<BrokerInfos> task = new CommonQueryTask<BrokerInfos>(serverInfo, CommonSendMsg.getCommonSimpleSendMsg(), brokerInfos);
        monitorCancel(monitor, new ITask[] { task });
        task.execute();
        final String errorMsg = task.getErrorMsg();
        if (!monitor.isCanceled() && errorMsg != null && errorMsg.trim().length() > 0) {
            parent.removeAllChild();
            Display display = Display.getDefault();
            display.syncExec(new Runnable() {

                public void run() {
                    CommonUITool.openErrorBox(errorMsg);
                }
            });
            setLoaded(true);
            return;
        }
        if (monitor.isCanceled()) {
            setLoaded(true);
            return;
        }
        brokerInfos = task.getResultModel();
        List<ICubridNode> oldNodeList = parent.getChildren();
        parent.removeAllChild();
        List<BrokerInfo> brokerInfoList = (brokerInfos == null || brokerInfos.getBorkerInfoList() == null) ? null : brokerInfos.getBorkerInfoList().getBrokerInfoList();
        for (int i = 0; brokerInfoList != null && i < brokerInfoList.size(); i++) {
            BrokerInfo brokerInfo = brokerInfoList.get(i);
            String id = parent.getId() + NODE_SEPARATOR + brokerInfo.getName();
            ICubridNode brokerInfoNode = isContained(oldNodeList, id);
            if (brokerInfoNode == null) {
                brokerInfoNode = new CubridBroker(id, brokerInfo.getName(), "icons/navigator/broker.png");
                ((CubridBroker) brokerInfoNode).setStartedIconPath("icons/navigator/broker_started.png");
                brokerInfoNode.setType(CubridNodeType.BROKER);
                brokerInfoNode.setContainer(true);
                brokerInfoNode.setModelObj(brokerInfo);
                brokerInfoNode.setViewId(BrokerStatusView.ID);
                brokerInfoNode.setLoader(new CubridBrokerFolderLoader());
            } else {
                brokerInfoNode.setModelObj(brokerInfo);
                if (brokerInfoNode.getLoader() != null && brokerInfoNode.getLoader().isLoaded()) {
                    brokerInfoNode.getLoader().setLoaded(false);
                    brokerInfoNode.getChildren(monitor);
                }
            }
            parent.addChild(brokerInfoNode);
        }
        serverInfo.setBrokerInfos(brokerInfos);
        // For the Shard Broker Folder
        if (CompatibleUtil.isSupportShard(serverInfo)) {
            Shards shards = new Shards();
            GetShardConfTask<Shards> getShardConfTask = new GetShardConfTask<Shards>(serverInfo, shards);
            getShardConfTask.execute();
            // !"File(?) open error".equals(errorMsg.trim())) {
            if (getShardConfTask.isSuccess()) {
                GetShardStatusTask getShardStatusTask = new GetShardStatusTask(serverInfo, null);
                getShardStatusTask.execute();
                boolean runningShard = getShardStatusTask.isSuccess();
                serverInfo.setShards(shards);
                shards.setRunning(runningShard);
                String shardFolderId = parent.getId() + NODE_SEPARATOR + SHARD_FOLDER_ID;
                ICubridNode shardFolder = parent.getChild(shardFolderId);
                if (shardFolder == null) {
                    shardFolder = new CubridShardFolder(shardFolderId, SHARD_FOLDER_NAME);
                    ICubridNodeLoader loader = new CubridShardsFolderLoader((CubridShardFolder) shardFolder);
                    loader.setLevel(getLevel());
                    shardFolder.setLoader(loader);
                    parent.addChild(shardFolder);
                // shardFolder.getChildren(monitor);
                } else {
                    if (shardFolder.getLoader() != null && shardFolder.getLoader().isLoaded()) {
                        shardFolder.getLoader().setLoaded(false);
                        shardFolder.getChildren(monitor);
                    }
                }
            }
        }
        Collections.sort(parent.getChildren());
        setLoaded(true);
        CubridNodeManager.getInstance().fireCubridNodeChanged(new CubridNodeChangedEvent((ICubridNode) parent, CubridNodeChangedEventType.CONTAINER_NODE_REFRESH));
    }
}
Also used : ServerInfo(com.cubrid.cubridmanager.core.common.model.ServerInfo) BrokerInfos(com.cubrid.cubridmanager.core.broker.model.BrokerInfos) CubridBroker(com.cubrid.cubridmanager.ui.spi.model.CubridBroker) CubridShardFolder(com.cubrid.cubridmanager.ui.spi.model.CubridShardFolder) CubridNodeChangedEvent(com.cubrid.common.ui.spi.event.CubridNodeChangedEvent) ICubridNode(com.cubrid.common.ui.spi.model.ICubridNode) GetShardConfTask(com.cubrid.cubridmanager.core.shard.task.GetShardConfTask) BrokerInfo(com.cubrid.cubridmanager.core.broker.model.BrokerInfo) ICubridNodeLoader(com.cubrid.common.ui.spi.model.ICubridNodeLoader) CommonQueryTask(com.cubrid.cubridmanager.core.common.task.CommonQueryTask) ServerUserInfo(com.cubrid.cubridmanager.core.common.model.ServerUserInfo) Shards(com.cubrid.cubridmanager.core.shard.model.Shards) GetShardStatusTask(com.cubrid.cubridmanager.core.shard.task.GetShardStatusTask) Display(org.eclipse.swt.widgets.Display)

Example 5 with Shards

use of com.cubrid.cubridmanager.core.shard.model.Shards in project cubrid-manager by CUBRID.

the class CubridBrokerLogFolderLoader method load.

/**
	 * 
	 * Load children object for parent
	 * 
	 * @param parent the parent node
	 * @param monitor the IProgressMonitor object
	 */
public void load(ICubridNode parent, final IProgressMonitor monitor) {
    synchronized (this) {
        if (isLoaded()) {
            return;
        }
        // add access and error and admin log folder to broker logs folder
        String[] brokerLogIdArr = { ACCESS_LOG_FOLDER_ID, ERROR_LOG_FOLDER_ID, ADMIN_LOG_FOLDER_ID };
        String[] brokerLogNameArr = { ACCESS_LOG_FOLDER_NAME, ERROR_LOG_FOLDER_NAME, ADMIN_LOG_FOLDER_NAME };
        String[] brokerLogTypeArr = { CubridNodeType.LOGS_BROKER_ACCESS_LOG_FOLDER, CubridNodeType.LOGS_BROKER_ERROR_LOG_FOLDER, CubridNodeType.LOGS_BROKER_ADMIN_LOG_FOLDER };
        String[] iconArr = { "icons/navigator/folder.png", "icons/navigator/folder.png", "icons/navigator/folder.png" };
        ICubridNode[] logFoldrNodeArr = new ICubridNode[3];
        for (int i = 0; i < brokerLogNameArr.length; i++) {
            String id = parent.getId() + NODE_SEPARATOR + brokerLogIdArr[i];
            logFoldrNodeArr[i] = parent.getChild(id);
            if (logFoldrNodeArr[i] == null) {
                logFoldrNodeArr[i] = new DefaultCubridNode(id, brokerLogNameArr[i], iconArr[i]);
                logFoldrNodeArr[i].setType(brokerLogTypeArr[i]);
                logFoldrNodeArr[i].setContainer(true);
                parent.addChild(logFoldrNodeArr[i]);
                if (i == 2) {
                    ICubridNodeLoader loader = new CubridAdminLogFolderLoader();
                    loader.setLevel(getLevel());
                    logFoldrNodeArr[i].setLoader(loader);
                    if (getLevel() == DEFINITE_LEVEL) {
                        logFoldrNodeArr[i].getChildren(monitor);
                    }
                }
            } else {
                if (logFoldrNodeArr[i].getLoader() != null) {
                    logFoldrNodeArr[i].getLoader().setLoaded(false);
                    logFoldrNodeArr[i].getChildren(monitor);
                }
            }
        }
        ServerInfo serverInfo = parent.getServer().getServerInfo();
        BrokerInfos brokerInfos = serverInfo.getBrokerInfos();
        Shards shards = serverInfo.getShards();
        monitorCancel(monitor, new ITask[] { loadBrokersTask, loadBrokrLogInfoTask });
        if (brokerInfos == null && !monitor.isCanceled()) {
            // load all borkers
            brokerInfos = new BrokerInfos();
            loadBrokersTask = new CommonQueryTask<BrokerInfos>(serverInfo, CommonSendMsg.getCommonSimpleSendMsg(), brokerInfos);
            loadBrokersTask.execute();
            final String errorMsg = loadBrokersTask.getErrorMsg();
            if (!monitor.isCanceled() && errorMsg != null && errorMsg.trim().length() > 0) {
                logFoldrNodeArr[0].removeAllChild();
                logFoldrNodeArr[1].removeAllChild();
                openErrorBox(errorMsg);
                setLoaded(true);
                return;
            }
            brokerInfos = loadBrokersTask.getResultModel();
            serverInfo.setBrokerInfos(brokerInfos);
        }
        if (monitor.isCanceled()) {
            setLoaded(true);
            return;
        }
        // load broker log file information
        List<BrokerLogInfos> brokerLogInfosList = new ArrayList<BrokerLogInfos>();
        if (brokerInfos != null) {
            BrokerInfoList list = brokerInfos.getBorkerInfoList();
            if (list != null && list.getBrokerInfoList() != null) {
                List<BrokerInfo> brokerInfoList = list.getBrokerInfoList();
                for (int i = 0; !monitor.isCanceled() && brokerInfoList != null && i < brokerInfoList.size(); i++) {
                    BrokerInfo brokerInfo = brokerInfoList.get(i);
                    BrokerLogInfos brokerLogInfos = new BrokerLogInfos();
                    loadBrokrLogInfoTask = new CommonQueryTask<BrokerLogInfos>(serverInfo, CommonSendMsg.getGetBrokerLogFileInfoMSGItems(), brokerLogInfos);
                    loadBrokrLogInfoTask.setBroker(brokerInfo.getName());
                    loadBrokrLogInfoTask.execute();
                    final String errorMsg = loadBrokrLogInfoTask.getErrorMsg();
                    if (!monitor.isCanceled() && errorMsg != null && errorMsg.trim().length() > 0) {
                        logFoldrNodeArr[0].removeAllChild();
                        logFoldrNodeArr[1].removeAllChild();
                        openErrorBox(errorMsg);
                        setLoaded(true);
                        return;
                    }
                    brokerLogInfos = loadBrokrLogInfoTask.getResultModel();
                    brokerLogInfosList.add(brokerLogInfos);
                }
            }
        }
        // load shard broker log file information
        if (shards != null) {
            List<Shard> shardList = shards.getShardList();
            if (shardList != null) {
                for (int i = 0; i < shardList.size(); i++) {
                    Shard shard = shardList.get(i);
                    BrokerLogInfos brokerLogInfos = new BrokerLogInfos();
                    loadBrokrLogInfoTask = new CommonQueryTask<BrokerLogInfos>(serverInfo, CommonSendMsg.getGetBrokerLogFileInfoMSGItems(), brokerLogInfos);
                    loadBrokrLogInfoTask.setBroker(shard.getName());
                    loadBrokrLogInfoTask.execute();
                    final String errorMsg = loadBrokrLogInfoTask.getErrorMsg();
                    if (!monitor.isCanceled() && errorMsg != null && errorMsg.trim().length() > 0) {
                        logFoldrNodeArr[0].removeAllChild();
                        logFoldrNodeArr[1].removeAllChild();
                        openErrorBox(errorMsg);
                        setLoaded(true);
                        return;
                    }
                    brokerLogInfos = loadBrokrLogInfoTask.getResultModel();
                    brokerLogInfosList.add(brokerLogInfos);
                }
            }
        }
        if (monitor.isCanceled()) {
            setLoaded(true);
            return;
        }
        logFoldrNodeArr[0].removeAllChild();
        logFoldrNodeArr[1].removeAllChild();
        for (BrokerLogInfos brokerLogInfos : brokerLogInfosList) {
            List<LogInfo> logInfoList = brokerLogInfos.getBrokerLogInfoList().getLogFileInfoList();
            if (logInfoList != null && !logInfoList.isEmpty()) {
                for (LogInfo logInfo : logInfoList) {
                    ICubridNode logInfoNode = new DefaultCubridNode("", logInfo.getName(), "");
                    logInfoNode.setContainer(false);
                    logInfoNode.setModelObj(logInfo);
                    logInfoNode.setEditorId(LogEditorPart.ID);
                    if (LogType.ACCESS.getText().toLowerCase().equals(logInfo.getType())) {
                        String id = logFoldrNodeArr[0].getId() + NODE_SEPARATOR + logInfo.getName();
                        logInfoNode.setId(id);
                        logInfoNode.setType(CubridNodeType.LOGS_BROKER_ACCESS_LOG);
                        logInfoNode.setIconPath("icons/navigator/log_item.png");
                        logFoldrNodeArr[0].addChild(logInfoNode);
                    } else if (LogType.ERROR.getText().toLowerCase().equals(logInfo.getType())) {
                        String id = logFoldrNodeArr[1].getId() + NODE_SEPARATOR + logInfo.getName();
                        logInfoNode.setId(id);
                        logInfoNode.setType(CubridNodeType.LOGS_BROKER_ERROR_LOG);
                        logInfoNode.setIconPath("icons/navigator/log_item.png");
                        logFoldrNodeArr[1].addChild(logInfoNode);
                    }
                }
            }
        }
        Collections.sort(logFoldrNodeArr[0].getChildren());
        Collections.sort(logFoldrNodeArr[1].getChildren());
        setLoaded(true);
        CubridNodeManager.getInstance().fireCubridNodeChanged(new CubridNodeChangedEvent((ICubridNode) parent, CubridNodeChangedEventType.CONTAINER_NODE_REFRESH));
        CubridNodeManager.getInstance().fireCubridNodeChanged(new CubridNodeChangedEvent(logFoldrNodeArr[0], CubridNodeChangedEventType.CONTAINER_NODE_REFRESH));
        CubridNodeManager.getInstance().fireCubridNodeChanged(new CubridNodeChangedEvent(logFoldrNodeArr[1], CubridNodeChangedEventType.CONTAINER_NODE_REFRESH));
    }
}
Also used : DefaultCubridNode(com.cubrid.common.ui.spi.model.DefaultCubridNode) LogInfo(com.cubrid.cubridmanager.core.logs.model.LogInfo) BrokerLogInfos(com.cubrid.cubridmanager.core.logs.model.BrokerLogInfos) ServerInfo(com.cubrid.cubridmanager.core.common.model.ServerInfo) BrokerInfos(com.cubrid.cubridmanager.core.broker.model.BrokerInfos) ArrayList(java.util.ArrayList) ICubridNode(com.cubrid.common.ui.spi.model.ICubridNode) CubridNodeChangedEvent(com.cubrid.common.ui.spi.event.CubridNodeChangedEvent) BrokerInfoList(com.cubrid.cubridmanager.core.broker.model.BrokerInfoList) BrokerInfo(com.cubrid.cubridmanager.core.broker.model.BrokerInfo) ICubridNodeLoader(com.cubrid.common.ui.spi.model.ICubridNodeLoader) Shards(com.cubrid.cubridmanager.core.shard.model.Shards) Shard(com.cubrid.cubridmanager.core.shard.model.Shard)

Aggregations

Shards (com.cubrid.cubridmanager.core.shard.model.Shards)11 Shard (com.cubrid.cubridmanager.core.shard.model.Shard)7 ServerInfo (com.cubrid.cubridmanager.core.common.model.ServerInfo)5 GetShardConfTask (com.cubrid.cubridmanager.core.shard.task.GetShardConfTask)5 CubridNodeChangedEvent (com.cubrid.common.ui.spi.event.CubridNodeChangedEvent)3 ICubridNode (com.cubrid.common.ui.spi.model.ICubridNode)3 ShardNode (com.cubrid.cubridmanager.core.cubrid.service.model.ShardNode)3 ShardConnection (com.cubrid.cubridmanager.core.shard.model.ShardConnection)3 ShardsStatus (com.cubrid.cubridmanager.core.shard.model.ShardsStatus)3 GetShardStatusTask (com.cubrid.cubridmanager.core.shard.task.GetShardStatusTask)3 ArrayList (java.util.ArrayList)3 HashMap (java.util.HashMap)3 ICubridNodeLoader (com.cubrid.common.ui.spi.model.ICubridNodeLoader)2 BrokerInfo (com.cubrid.cubridmanager.core.broker.model.BrokerInfo)2 BrokerInfos (com.cubrid.cubridmanager.core.broker.model.BrokerInfos)2 ServerUserInfo (com.cubrid.cubridmanager.core.common.model.ServerUserInfo)2 DatabaseInfo (com.cubrid.cubridmanager.core.cubrid.database.model.DatabaseInfo)2 GetDatabaseListTask (com.cubrid.cubridmanager.core.cubrid.database.task.GetDatabaseListTask)2 ShardStatus (com.cubrid.cubridmanager.core.shard.model.ShardStatus)2 Map (java.util.Map)2