use of org.ovirt.engine.core.common.businessentities.gluster.GlusterGeoRepSession in project ovirt-engine by oVirt.
the class GeoRepCreateEligibilityBaseTest method getSession.
protected GlusterGeoRepSession getSession(Guid slaveVolumeId) {
GlusterGeoRepSession session = new GlusterGeoRepSession();
session.setId(Guid.newGuid());
session.setMasterVolumeId(Guid.newGuid());
session.setSlaveVolumeId(slaveVolumeId);
return session;
}
use of org.ovirt.engine.core.common.businessentities.gluster.GlusterGeoRepSession in project ovirt-engine by oVirt.
the class GlusterGeoRepDaoTest method testGetById.
@Test
public void testGetById() {
GlusterGeoRepSession session = dao.getById(FixturesTool.GLUSTER_GEOREP_SESSION_ID);
assertNotNull(session);
assertEquals(FixturesTool.GLUSTER_GEOREP_SESSION_ID, session.getId());
}
use of org.ovirt.engine.core.common.businessentities.gluster.GlusterGeoRepSession in project ovirt-engine by oVirt.
the class GlusterGeoRepDaoTest method getGlusterGeoRepSession.
private GlusterGeoRepSession getGlusterGeoRepSession() {
GlusterGeoRepSession georepSession = new GlusterGeoRepSession();
georepSession.setId(SESSION_ID);
georepSession.setMasterVolumeId(FixturesTool.GLUSTER_VOLUME_UUID1);
georepSession.setSlaveHostName("remoteHost");
georepSession.setSlaveVolumeName("remoteVol");
georepSession.setSlaveNodeUuid(FixturesTool.GLUSTER_SERVER_UUID1);
georepSession.setSessionKey("remoteHost:remoteVol");
georepSession.setStatus(GeoRepSessionStatus.ACTIVE);
return georepSession;
}
use of org.ovirt.engine.core.common.businessentities.gluster.GlusterGeoRepSession in project ovirt-engine by oVirt.
the class GlusterGeoRepDaoTest method testGetSessionByInvalidId.
@Test
public void testGetSessionByInvalidId() {
GlusterGeoRepSession session = dao.getById(NONEXIST_SESSION_ID);
assertNull(session);
}
use of org.ovirt.engine.core.common.businessentities.gluster.GlusterGeoRepSession in project ovirt-engine by oVirt.
the class GlusterGeoRepDaoTest method testGetBySlaveHostNameAndVolume.
@Test
public void testGetBySlaveHostNameAndVolume() {
GlusterGeoRepSession session = dao.getGeoRepSession(FixturesTool.GLUSTER_VOLUME_UUID1, "192.168.122.17", "slave-replica");
assertNotNull(session);
assertEquals(FixturesTool.GLUSTER_GEOREP_SESSION_ID, session.getId());
}
Aggregations