use of alluxio.conf.InstancedConfiguration in project alluxio by Alluxio.
the class ProcessLauncherTest method scriptNotExists.
@Test
public void scriptNotExists() throws Exception {
InstancedConfiguration conf = getTestConfig();
conf.set(PropertyKey.HOME, "/path/to/non/existent/directory");
assertThrows(IOException.class, () -> new ProcessLauncher(conf));
}
use of alluxio.conf.InstancedConfiguration in project alluxio by Alluxio.
the class AgentRpcServerTest method testGetAddress.
@Test
public void testGetAddress() {
InstancedConfiguration c = new InstancedConfiguration(ServerConfiguration.global().copyProperties());
c.set(PropertyKey.HUB_AGENT_RPC_BIND_HOST, "127.6.5.4");
c.set(PropertyKey.HUB_AGENT_RPC_PORT, 0);
InetSocketAddress addr = AgentRpcServer.getConfiguredAddress(c);
assertEquals("127.6.5.4", addr.getHostString());
assertEquals(0, addr.getPort());
}
use of alluxio.conf.InstancedConfiguration in project alluxio by Alluxio.
the class AgentRpcServerTest method getTestSpecificTestConfig.
private InstancedConfiguration getTestSpecificTestConfig() {
InstancedConfiguration c = new InstancedConfiguration(ServerConfiguration.global().copyProperties());
c.set(PropertyKey.HUB_AGENT_RPC_PORT, 0);
return c;
}
use of alluxio.conf.InstancedConfiguration in project alluxio by Alluxio.
the class OBSUnderFileSystemFactoryTest method factory.
/**
* Tests that the OBS UFS module correctly accepts paths that begin with obs://.
*/
@Test
public void factory() {
UnderFileSystemFactory factory = UnderFileSystemFactoryRegistry.find("obs://bucket/key", new InstancedConfiguration(ConfigurationUtils.defaults()));
Assert.assertNotNull("A UnderFileSystemFactory should exist for obs paths when using this module", factory);
}
use of alluxio.conf.InstancedConfiguration in project alluxio by Alluxio.
the class JournalUpgrader method main.
/**
* Reads a journal via
* {@code java -cp \
* assembly/server/target/alluxio-assembly-server-<ALLUXIO-VERSION>-jar-with-dependencies.jar \
* alluxio.master.journal.JournalUpgrader -master BlockMaster}.
*
* @param args arguments passed to the tool
*/
public static void main(String[] args) {
if (!parseInputArgs(args)) {
usage();
System.exit(EXIT_FAILED);
}
if (sHelp) {
usage();
System.exit(EXIT_SUCCEEDED);
}
List<String> masters = new ArrayList<>();
for (MasterFactory factory : ServiceUtils.getMasterServiceLoader()) {
masters.add(factory.getName());
}
for (String master : masters) {
Upgrader upgrader = new Upgrader(master, new InstancedConfiguration(ConfigurationUtils.defaults()));
try {
upgrader.upgrade();
} catch (IOException e) {
LOG.error("Failed to upgrade the journal for {}.", master, e);
System.exit(EXIT_FAILED);
}
}
}
Aggregations