use of com.orientechnologies.orient.server.OServer in project orientdb by orientechnologies.
the class OrientGraphRemoteTest method startEmbeddedServer.
@BeforeClass
public static void startEmbeddedServer() throws Exception {
final String buildDirectory = System.getProperty("buildDirectory", ".");
serverHome = buildDirectory + "/" + OrientGraphRemoteTest.class.getSimpleName();
File file = new File(serverHome);
deleteDirectory(file);
file = new File(serverHome);
Assert.assertTrue(file.mkdir());
oldOrientDBHome = System.getProperty("ORIENTDB_HOME");
System.setProperty("ORIENTDB_HOME", serverHome);
server = new OServer(false);
server.startup(OrientGraphRemoteTest.class.getResourceAsStream("/embedded-server-config.xml"));
server.activate();
}
use of com.orientechnologies.orient.server.OServer in project orientdb by orientechnologies.
the class RemoteRidBagTest method before.
@Before
public void before() throws Exception {
server = new OServer();
server.setServerRootDirectory(SERVER_DIRECTORY);
server.startup(getClass().getResourceAsStream("orientdb-server-config.xml"));
server.activate();
final OServerAdmin serverAdmin = new OServerAdmin("remote:localhost");
serverAdmin.connect("root", "D2AFD02F20640EC8B7A5140F34FCA49D2289DB1F0D0598BB9DE8AAA75A0792F3");
serverAdmin.createDatabase("RemoteRidBagTest", "document", "memory");
clientA = Executors.newSingleThreadExecutor();
clientB = Executors.newSingleThreadExecutor();
clientA.submit(new Runnable() {
@Override
public void run() {
dbA = new ODatabaseDocumentTx("remote:localhost/RemoteRidBagTest").open("admin", "admin");
}
}).get();
clientB.submit(new Runnable() {
@Override
public void run() {
dbB = new ODatabaseDocumentTx("remote:localhost/RemoteRidBagTest").open("admin", "admin");
}
}).get();
}
use of com.orientechnologies.orient.server.OServer in project orientdb by orientechnologies.
the class BaseHttpTest method startServer.
protected void startServer() throws Exception {
if (server == null) {
server = new OServer(false);
server.startup(getClass().getResourceAsStream(getServerCfg()));
server.activate();
}
}
use of com.orientechnologies.orient.server.OServer in project orientdb by orientechnologies.
the class ORemoteImportTest method before.
@Before
public void before() throws Exception {
server = new OServer();
server.setServerRootDirectory(SERVER_DIRECTORY);
server.startup(getClass().getResourceAsStream("orientdb-server-config.xml"));
server.activate();
OServerAdmin server = new OServerAdmin("remote:localhost");
server.connect("root", "D2AFD02F20640EC8B7A5140F34FCA49D2289DB1F0D0598BB9DE8AAA75A0792F3");
server.createDatabase(ORemoteImportTest.class.getSimpleName(), "graph", "memory");
}
use of com.orientechnologies.orient.server.OServer in project orientdb by orientechnologies.
the class RemoteSequenceTest method before.
@Before
public void before() throws Exception {
server = new OServer();
server.setServerRootDirectory(SERVER_DIRECTORY);
server.startup(getClass().getResourceAsStream("orientdb-server-config.xml"));
server.activate();
OServerAdmin server = new OServerAdmin("remote:localhost");
server.connect("root", "D2AFD02F20640EC8B7A5140F34FCA49D2289DB1F0D0598BB9DE8AAA75A0792F3");
server.createDatabase(RemoteSequenceTest.class.getSimpleName(), "graph", "memory");
}
Aggregations