Search in sources :

Example 16 with VoidBlobStore

use of org.apache.flink.runtime.blob.VoidBlobStore in project flink-mirror by flink-ci.

the class BlobServerExtension method before.

@Override
public void before(ExtensionContext context) throws Exception {
    temporaryFolder.create();
    Configuration config = new Configuration();
    blobServer = new BlobServer(config, temporaryFolder.newFolder(), new VoidBlobStore());
    blobServer.start();
}
Also used : VoidBlobStore(org.apache.flink.runtime.blob.VoidBlobStore) Configuration(org.apache.flink.configuration.Configuration) BlobServer(org.apache.flink.runtime.blob.BlobServer)

Example 17 with VoidBlobStore

use of org.apache.flink.runtime.blob.VoidBlobStore in project flink by splunk.

the class KubernetesHaServicesTest method testInternalJobCleanupShouldCleanupConfigMaps.

@Test
public void testInternalJobCleanupShouldCleanupConfigMaps() throws Exception {
    new Context() {

        {
            runTest(() -> {
                final KubernetesHaServices kubernetesHaServices = new KubernetesHaServices(flinkKubeClient, executorService, configuration, new VoidBlobStore());
                JobID jobID = new JobID();
                String configMapName = kubernetesHaServices.getLeaderPathForJobManager(jobID);
                final KubernetesConfigMap configMap = new TestingFlinkKubeClient.MockKubernetesConfigMap(configMapName);
                flinkKubeClient.createConfigMap(configMap);
                assertThat(flinkKubeClient.getConfigMap(configMapName).isPresent(), is(true));
                kubernetesHaServices.internalCleanupJobData(jobID);
                assertThat(flinkKubeClient.getConfigMap(configMapName).isPresent(), is(false));
            });
        }
    };
}
Also used : KubernetesConfigMap(org.apache.flink.kubernetes.kubeclient.resources.KubernetesConfigMap) VoidBlobStore(org.apache.flink.runtime.blob.VoidBlobStore) JobID(org.apache.flink.api.common.JobID) Test(org.junit.Test)

Example 18 with VoidBlobStore

use of org.apache.flink.runtime.blob.VoidBlobStore in project flink by splunk.

the class KubernetesHaServicesTest method testInternalCloseShouldCloseFlinkKubeClient.

@Test
public void testInternalCloseShouldCloseFlinkKubeClient() throws Exception {
    new Context() {

        {
            runTest(() -> {
                final KubernetesHaServices kubernetesHaServices = new KubernetesHaServices(flinkKubeClient, executorService, configuration, new VoidBlobStore());
                kubernetesHaServices.internalClose();
                assertThat(closeKubeClientFuture.isDone(), is(true));
            });
        }
    };
}
Also used : VoidBlobStore(org.apache.flink.runtime.blob.VoidBlobStore) Test(org.junit.Test)

Example 19 with VoidBlobStore

use of org.apache.flink.runtime.blob.VoidBlobStore in project flink by splunk.

the class JobSubmitHandlerTest method setup.

@Before
public void setup() throws IOException {
    Configuration config = new Configuration(configuration);
    blobServer = new BlobServer(config, TEMPORARY_FOLDER.newFolder(), new VoidBlobStore());
    blobServer.start();
}
Also used : VoidBlobStore(org.apache.flink.runtime.blob.VoidBlobStore) Configuration(org.apache.flink.configuration.Configuration) BlobServer(org.apache.flink.runtime.blob.BlobServer) Before(org.junit.Before)

Example 20 with VoidBlobStore

use of org.apache.flink.runtime.blob.VoidBlobStore in project flink by splunk.

the class BlobServerExtension method before.

@Override
public void before(ExtensionContext context) throws Exception {
    temporaryFolder.create();
    Configuration config = new Configuration();
    blobServer = new BlobServer(config, temporaryFolder.newFolder(), new VoidBlobStore());
    blobServer.start();
}
Also used : VoidBlobStore(org.apache.flink.runtime.blob.VoidBlobStore) Configuration(org.apache.flink.configuration.Configuration) BlobServer(org.apache.flink.runtime.blob.BlobServer)

Aggregations

VoidBlobStore (org.apache.flink.runtime.blob.VoidBlobStore)51 Configuration (org.apache.flink.configuration.Configuration)42 BlobServer (org.apache.flink.runtime.blob.BlobServer)39 Before (org.junit.Before)18 Test (org.junit.Test)18 InetSocketAddress (java.net.InetSocketAddress)15 JobID (org.apache.flink.api.common.JobID)15 PermanentBlobCache (org.apache.flink.runtime.blob.PermanentBlobCache)15 PermanentBlobKey (org.apache.flink.runtime.blob.PermanentBlobKey)12 UserCodeClassLoader (org.apache.flink.util.UserCodeClassLoader)9 BeforeClass (org.junit.BeforeClass)9 URL (java.net.URL)6 ArrayList (java.util.ArrayList)6 File (java.io.File)3 IOException (java.io.IOException)3 Collection (java.util.Collection)3 TestingServer (org.apache.curator.test.TestingServer)3 KubernetesConfigMap (org.apache.flink.kubernetes.kubeclient.resources.KubernetesConfigMap)3 BlobCacheSizeTracker (org.apache.flink.runtime.blob.BlobCacheSizeTracker)3 StandaloneCheckpointRecoveryFactory (org.apache.flink.runtime.checkpoint.StandaloneCheckpointRecoveryFactory)3