Search in sources :

Example 11 with ContainerSpecification

use of org.apache.flink.runtime.clusterframework.ContainerSpecification in project flink by apache.

the class KeytabOverlayTest method testConfigure.

@Test
public void testConfigure() throws Exception {
    File keytab = tempFolder.newFile();
    KeytabOverlay overlay = new KeytabOverlay(keytab);
    ContainerSpecification spec = new ContainerSpecification();
    overlay.configure(spec);
    assertEquals(TARGET_PATH.getPath(), spec.getDynamicConfiguration().getString(SecurityOptions.KERBEROS_LOGIN_KEYTAB));
    checkArtifact(spec, TARGET_PATH);
}
Also used : ContainerSpecification(org.apache.flink.runtime.clusterframework.ContainerSpecification) File(java.io.File) Test(org.junit.Test)

Example 12 with ContainerSpecification

use of org.apache.flink.runtime.clusterframework.ContainerSpecification in project flink by apache.

the class Krb5ConfOverlayTest method testConfigure.

@Test
public void testConfigure() throws Exception {
    File krb5conf = tempFolder.newFile();
    Krb5ConfOverlay overlay = new Krb5ConfOverlay(krb5conf);
    ContainerSpecification spec = new ContainerSpecification();
    overlay.configure(spec);
    assertEquals(TARGET_PATH.getPath(), spec.getSystemProperties().getString(JAVA_SECURITY_KRB5_CONF, null));
    checkArtifact(spec, TARGET_PATH);
}
Also used : ContainerSpecification(org.apache.flink.runtime.clusterframework.ContainerSpecification) File(java.io.File) Test(org.junit.Test)

Example 13 with ContainerSpecification

use of org.apache.flink.runtime.clusterframework.ContainerSpecification in project flink by apache.

the class SSLStoreOverlayTest method testConfigure.

@Test
public void testConfigure() throws Exception {
    File keystore = tempFolder.newFile();
    File truststore = tempFolder.newFile();
    SSLStoreOverlay overlay = new SSLStoreOverlay(keystore, truststore);
    ContainerSpecification spec = new ContainerSpecification();
    overlay.configure(spec);
    assertEquals(TARGET_KEYSTORE_PATH.getPath(), spec.getDynamicConfiguration().getString(ConfigConstants.SECURITY_SSL_KEYSTORE, null));
    checkArtifact(spec, TARGET_KEYSTORE_PATH);
    assertEquals(TARGET_TRUSTSTORE_PATH.getPath(), spec.getDynamicConfiguration().getString(ConfigConstants.SECURITY_SSL_TRUSTSTORE, null));
    checkArtifact(spec, TARGET_TRUSTSTORE_PATH);
}
Also used : ContainerSpecification(org.apache.flink.runtime.clusterframework.ContainerSpecification) File(java.io.File) Test(org.junit.Test)

Aggregations

ContainerSpecification (org.apache.flink.runtime.clusterframework.ContainerSpecification)13 Test (org.junit.Test)11 File (java.io.File)5 Path (org.apache.flink.core.fs.Path)3 ActorRef (akka.actor.ActorRef)1 ActorSystem (akka.actor.ActorSystem)1 Address (akka.actor.Address)1 Props (akka.actor.Props)1 IOException (java.io.IOException)1 InetAddress (java.net.InetAddress)1 URL (java.net.URL)1 FileVisitResult (java.nio.file.FileVisitResult)1 BasicFileAttributes (java.nio.file.attribute.BasicFileAttributes)1 ExecutorService (java.util.concurrent.ExecutorService)1 ScheduledExecutorService (java.util.concurrent.ScheduledExecutorService)1 Configuration (org.apache.flink.configuration.Configuration)1 GlobalConfiguration (org.apache.flink.configuration.GlobalConfiguration)1 MesosServices (org.apache.flink.mesos.runtime.clusterframework.services.MesosServices)1 MesosWorkerStore (org.apache.flink.mesos.runtime.clusterframework.store.MesosWorkerStore)1 MesosArtifactServer (org.apache.flink.mesos.util.MesosArtifactServer)1