Package eu.mosaic_cloud.platform.core.configuration

Examples of eu.mosaic_cloud.platform.core.configuration.PropertyTypeConfiguration


      scenario.driversChannel.accept (scenario.driversEndpoint);
    }
    {
      final String host = System.getProperty (BaseCloudletTest.MOSAIC_AMQP_HOST, BaseCloudletTest.MOSAIC_AMQP_HOST_DEFAULT);
      final Integer port = Integer.valueOf (System.getProperty (BaseCloudletTest.MOSAIC_AMQP_PORT, BaseCloudletTest.MOSAIC_AMQP_PORT_DEFAULT));
      final PropertyTypeConfiguration driverConfiguration = PropertyTypeConfiguration.create ();
      driverConfiguration.addParameter ("interop.driver.endpoint", scenario.driversEndpoint);
      driverConfiguration.addParameter ("interop.driver.identity", scenario.driversIdentity);
      driverConfiguration.addParameter ("amqp.host", host);
      driverConfiguration.addParameter ("amqp.port", port);
      driverConfiguration.addParameter ("amqp.driver_threads", Integer.valueOf (1));
      driverConfiguration.addParameter ("consumer.amqp.queue", "tests.queue");
      driverConfiguration.addParameter ("consumer.amqp.consumer_id", "tests.consumer");
      driverConfiguration.addParameter ("consumer.amqp.auto_ack", Boolean.FALSE);
      driverConfiguration.addParameter ("consumer.amqp.exclusive", Boolean.FALSE);
      driverConfiguration.addParameter ("publisher.amqp.exchange", "tests.exchange");
      driverConfiguration.addParameter ("publisher.amqp.routing_key", "tests.routing-key");
      driverConfiguration.addParameter ("publisher.amqp.manadatory", Boolean.TRUE);
      driverConfiguration.addParameter ("publisher.amqp.immediate", Boolean.FALSE);
      driverConfiguration.addParameter ("publisher.amqp.durable", Boolean.FALSE);
      scenario.driversChannel.register (AmqpSession.DRIVER);
      scenario.amqpDriverStub = AmqpStub.createDetached (driverConfiguration, scenario.driversChannel, scenario.threading);
    }
    {
      final String host = System.getProperty (BaseCloudletTest.MOSAIC_RIAK_HOST, BaseCloudletTest.MOSAIC_RIAK_HOST_DEFAULT);
      final Integer port = Integer.valueOf (System.getProperty (BaseCloudletTest.MOSAIC_RIAK_PORT, BaseCloudletTest.MOSAIC_RIAK_PORT_DEFAULT));
      final PropertyTypeConfiguration driverConfiguration = PropertyTypeConfiguration.create ();
      driverConfiguration.addParameter ("interop.driver.endpoint", scenario.driversEndpoint);
      driverConfiguration.addParameter ("interop.driver.identity", scenario.driversIdentity);
      driverConfiguration.addParameter ("kvstore.host", host);
      driverConfiguration.addParameter ("kvstore.port", port);
      driverConfiguration.addParameter ("kvstore.driver_name", "RIAKREST");
      driverConfiguration.addParameter ("kvstore.driver_threads", Integer.valueOf (1));
      driverConfiguration.addParameter ("kvstore.bucket", "tests");
      scenario.driversChannel.register (KeyValueSession.DRIVER);
      scenario.kvDriverStub = KeyValueStub.createDetached (driverConfiguration, scenario.threading, scenario.driversChannel);
    }
    this.cloudlet = Cloudlet.create (this.scenario.environment);
  }
View Full Code Here


{
  public HdfsDriverComponentCallbacks (final ComponentEnvironment context)
  {
    super (context);
    try {
      final PropertyTypeConfiguration configuration = PropertyTypeConfiguration.create (HdfsDriverComponentCallbacks.class.getResourceAsStream ("driver-component.properties"));
      if (context.supplementary.containsKey ("hdfs.host"))
        configuration.addParameter ("dfs.host", context.supplementary.get ("hdfs.host"));
      if (context.supplementary.containsKey ("hdfs.port"))
        configuration.addParameter ("dfs.port", context.supplementary.get ("hdfs.port"));
      this.setDriverConfiguration (configuration);
      this.selfGroup = ComponentIdentifier.resolve (ConfigUtils.resolveParameter (this.getDriverConfiguration (), "self.group.identifier", String.class, ""));
      this.status = Status.Created;
    } catch (final IOException e) {
      this.exceptions.traceIgnoredException (e);
View Full Code Here

      scenario.driversChannel.accept (scenario.driversEndpoint);
    }
    {
      final String host = System.getProperty (BaseCloudletTest.MOSAIC_AMQP_HOST, BaseCloudletTest.MOSAIC_AMQP_HOST_DEFAULT);
      final Integer port = Integer.valueOf (System.getProperty (BaseCloudletTest.MOSAIC_AMQP_PORT, BaseCloudletTest.MOSAIC_AMQP_PORT_DEFAULT));
      final PropertyTypeConfiguration driverConfiguration = PropertyTypeConfiguration.create ();
      driverConfiguration.addParameter ("interop.driver.endpoint", scenario.driversEndpoint);
      driverConfiguration.addParameter ("interop.driver.identity", scenario.driversIdentity);
      driverConfiguration.addParameter ("amqp.host", host);
      driverConfiguration.addParameter ("amqp.port", port);
      driverConfiguration.addParameter ("amqp.driver_threads", Integer.valueOf (1));
      driverConfiguration.addParameter ("consumer.amqp.queue", "tests.queue");
      driverConfiguration.addParameter ("consumer.amqp.consumer_id", "tests.consumer");
      driverConfiguration.addParameter ("consumer.amqp.auto_ack", Boolean.FALSE);
      driverConfiguration.addParameter ("consumer.amqp.exclusive", Boolean.FALSE);
      driverConfiguration.addParameter ("publisher.amqp.exchange", "tests.exchange");
      driverConfiguration.addParameter ("publisher.amqp.routing_key", "tests.routing-key");
      driverConfiguration.addParameter ("publisher.amqp.manadatory", Boolean.TRUE);
      driverConfiguration.addParameter ("publisher.amqp.immediate", Boolean.FALSE);
      driverConfiguration.addParameter ("publisher.amqp.durable", Boolean.FALSE);
      scenario.driversChannel.register (AmqpSession.DRIVER);
      scenario.amqpDriverStub = AmqpStub.createDetached (driverConfiguration, scenario.driversChannel, scenario.threading);
    }
    {
      final String host = System.getProperty (BaseCloudletTest.MOSAIC_RIAK_HOST, BaseCloudletTest.MOSAIC_RIAK_HOST_DEFAULT);
      final Integer port = Integer.valueOf (System.getProperty (BaseCloudletTest.MOSAIC_RIAK_PORT, BaseCloudletTest.MOSAIC_RIAK_PORT_DEFAULT));
      final PropertyTypeConfiguration driverConfiguration = PropertyTypeConfiguration.create ();
      driverConfiguration.addParameter ("interop.driver.endpoint", scenario.driversEndpoint);
      driverConfiguration.addParameter ("interop.driver.identity", scenario.driversIdentity);
      driverConfiguration.addParameter ("kvstore.host", host);
      driverConfiguration.addParameter ("kvstore.port", port);
      driverConfiguration.addParameter ("kvstore.driver_name", "RIAKREST");
      driverConfiguration.addParameter ("kvstore.driver_threads", Integer.valueOf (1));
      driverConfiguration.addParameter ("kvstore.bucket", "tests");
      scenario.driversChannel.register (KeyValueSession.DRIVER);
      scenario.kvDriverStub = KeyValueStub.createDetached (driverConfiguration, scenario.threading, scenario.driversChannel);
    }
    this.cloudlet = Cloudlet.create (this.scenario.environment);
  }
View Full Code Here

TOP

Related Classes of eu.mosaic_cloud.platform.core.configuration.PropertyTypeConfiguration

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.