Search in sources :

Example 6 with XMLFileLoaderPath

use of com.alibaba.cobar.manager.dao.xml.XMLFileLoaderPath in project cobar by alibaba.

the class CobarDaoTest method initData.

@Before
public void initData() {
    Assert.assertNotNull(xmlPath);
    xmlFileLoader = new XMLFileLoaderPath();
    xmlFileLoader.setXmlPath(xmlPath);
    cobarDao = new CobarDAOImple();
    cobarDao.setXmlFileLoader(xmlFileLoader);
    cobarXmlPath = xmlPath + System.getProperty("file.separator") + "cobar.xml";
    XmlFile xmlFile = new XmlFile(cobarXmlPath, "cobars");
    try {
        xmlFile.init();
    } catch (IOException e) {
        logger.error(e.getMessage(), e);
        Assert.fail();
    }
    read();
}
Also used : IOException(java.io.IOException) XMLFileLoaderPath(com.alibaba.cobar.manager.dao.xml.XMLFileLoaderPath) CobarDAOImple(com.alibaba.cobar.manager.dao.xml.CobarDAOImple) Before(org.junit.Before)

Aggregations

XMLFileLoaderPath (com.alibaba.cobar.manager.dao.xml.XMLFileLoaderPath)6 Before (org.junit.Before)4 IOException (java.io.IOException)3 ClusterDAOImple (com.alibaba.cobar.manager.dao.xml.ClusterDAOImple)2 CobarDAOImple (com.alibaba.cobar.manager.dao.xml.CobarDAOImple)2 CobarAdapterDAO (com.alibaba.cobar.manager.dao.CobarAdapterDAO)1 AdapterDelegate (com.alibaba.cobar.manager.dao.delegate.AdapterDelegate)1 PropertyDAOImple (com.alibaba.cobar.manager.dao.xml.PropertyDAOImple)1 UserDAOImple (com.alibaba.cobar.manager.dao.xml.UserDAOImple)1 ServerStatus (com.alibaba.cobar.manager.dataobject.cobarnode.ServerStatus)1 CobarAccesser (com.alibaba.cobar.manager.service.CobarAccesser)1 XmlAccesser (com.alibaba.cobar.manager.service.XmlAccesser)1