Search in sources :

Example 1 with Sync

use of it.unibo.arces.wot.sepa.Sync in project SEPA by arces-wot.

the class ITSPARQL11SEProtocol method beginTest.

@BeforeEach
public void beginTest() throws IOException, SEPAProtocolException, SEPAPropertiesException, SEPASecurityException, URISyntaxException, InterruptedException {
    provider = new ConfigurationProvider();
    handler = new Sync();
    protocol = new WebsocketSubscriptionProtocol(provider.getJsap().getSubscribeHost(), provider.getJsap().getSubscribePort(), provider.getJsap().getSubscribePath(), handler, provider.getClientSecurityManager());
    client = new SPARQL11SEProtocol(protocol, provider.getClientSecurityManager());
    Response ret = client.update(provider.buildUpdateRequest("DELETE_ALL"));
    assertFalse(ret.isError(), String.valueOf(ret));
}
Also used : Response(it.unibo.arces.wot.sepa.commons.response.Response) QueryResponse(it.unibo.arces.wot.sepa.commons.response.QueryResponse) ConfigurationProvider(it.unibo.arces.wot.sepa.ConfigurationProvider) WebsocketSubscriptionProtocol(it.unibo.arces.wot.sepa.api.protocols.websocket.WebsocketSubscriptionProtocol) Sync(it.unibo.arces.wot.sepa.Sync) BeforeEach(org.junit.jupiter.api.BeforeEach)

Example 2 with Sync

use of it.unibo.arces.wot.sepa.Sync in project SEPA by arces-wot.

the class ITPattern method beginTest.

@BeforeEach
public void beginTest() throws SEPAProtocolException, SEPASecurityException, SEPAPropertiesException {
    handler = new Sync();
    consumerAll = null;
    randomProducer = null;
    randomAggregator = null;
    consumerRandom1 = null;
    genericClient = null;
}
Also used : Sync(it.unibo.arces.wot.sepa.Sync) BeforeEach(org.junit.jupiter.api.BeforeEach)

Example 3 with Sync

use of it.unibo.arces.wot.sepa.Sync in project SEPA by arces-wot.

the class StressUsingSPARQLProtocol method beginTest.

@BeforeEach
public void beginTest() throws IOException, SEPAProtocolException, SEPAPropertiesException, SEPASecurityException, URISyntaxException, InterruptedException {
    provider = new ConfigurationProvider();
    sync = new Sync();
    client = new SPARQL11Protocol(provider.getClientSecurityManager());
    Response ret = client.update(provider.buildUpdateRequest("DELETE_ALL"));
    logger.debug(ret);
    assertFalse(ret.isError(), String.valueOf(ret));
    subscribers.clear();
    publishers.clear();
    sync.reset();
}
Also used : Response(it.unibo.arces.wot.sepa.commons.response.Response) ConfigurationProvider(it.unibo.arces.wot.sepa.ConfigurationProvider) SPARQL11Protocol(it.unibo.arces.wot.sepa.commons.protocol.SPARQL11Protocol) Sync(it.unibo.arces.wot.sepa.Sync) BeforeEach(org.junit.jupiter.api.BeforeEach)

Aggregations

Sync (it.unibo.arces.wot.sepa.Sync)3 BeforeEach (org.junit.jupiter.api.BeforeEach)3 ConfigurationProvider (it.unibo.arces.wot.sepa.ConfigurationProvider)2 Response (it.unibo.arces.wot.sepa.commons.response.Response)2 WebsocketSubscriptionProtocol (it.unibo.arces.wot.sepa.api.protocols.websocket.WebsocketSubscriptionProtocol)1 SPARQL11Protocol (it.unibo.arces.wot.sepa.commons.protocol.SPARQL11Protocol)1 QueryResponse (it.unibo.arces.wot.sepa.commons.response.QueryResponse)1