use of org.apache.pulsar.client.impl.auth.AuthenticationBasic in project incubator-pulsar by apache.
the class AuthenticatedProducerConsumerTest method testBasicCryptSyncProducerAndConsumer.
@Test(dataProvider = "batch")
public void testBasicCryptSyncProducerAndConsumer(int batchMessageDelayMs) throws Exception {
log.info("-- Starting {} test --", methodName);
AuthenticationBasic authPassword = new AuthenticationBasic();
authPassword.configure("{\"userId\":\"superUser\",\"password\":\"supepass\"}");
internalSetup(authPassword);
admin.properties().createProperty("my-property", new PropertyAdmin(Lists.newArrayList(), Sets.newHashSet("use")));
admin.namespaces().createNamespace("my-property/use/my-ns");
testSyncProducerAndConsumer(batchMessageDelayMs);
log.info("-- Exiting {} test --", methodName);
}
use of org.apache.pulsar.client.impl.auth.AuthenticationBasic in project incubator-pulsar by apache.
the class AuthenticatedProducerConsumerTest method testBasicArp1SyncProducerAndConsumer.
@Test(dataProvider = "batch")
public void testBasicArp1SyncProducerAndConsumer(int batchMessageDelayMs) throws Exception {
log.info("-- Starting {} test --", methodName);
AuthenticationBasic authPassword = new AuthenticationBasic();
authPassword.configure("{\"userId\":\"superUser2\",\"password\":\"superpassword\"}");
internalSetup(authPassword);
admin.properties().createProperty("my-property", new PropertyAdmin(Lists.newArrayList(), Sets.newHashSet("use")));
admin.namespaces().createNamespace("my-property/use/my-ns");
testSyncProducerAndConsumer(batchMessageDelayMs);
log.info("-- Exiting {} test --", methodName);
}
Aggregations