Package eu.mosaic_cloud.portingtest.ConsumerQPTKV

Examples of eu.mosaic_cloud.portingtest.ConsumerQPTKV.KeyValueCallback


      context.cloudlet = arguments.getCloudlet ();
      final IConfiguration configuration = context.cloudlet.getConfiguration ();
      final IConfiguration queueConfiguration = configuration.spliceConfiguration (ConfigurationIdentifier.resolveAbsolute ("queuestring.consumer"));
      final IConfiguration kvConfiguration = configuration.spliceConfiguration (ConfigurationIdentifier.resolveAbsolute ("storeqptcons"));
      context.consumer = context.cloudlet.getConnectorFactory (IAmqpQueueConsumerConnectorFactory.class).create (queueConfiguration, String.class, PlainTextDataEncoder.create(), new AmqpConsumerCallback (), context);
      context.kvStore = context.cloudlet.getConnectorFactory (IKvStoreConnectorFactory.class).create (kvConfiguration, QPT.class, JsonDataEncoder.create(QPT.class), new KeyValueCallback (), context);
      return CallbackCompletion.createAndChained (context.consumer.initialize (),context.kvStore.initialize());
    }
View Full Code Here


      context.cloudlet = arguments.getCloudlet ();
      final IConfiguration configuration = context.cloudlet.getConfiguration ();
      final IConfiguration queueConfiguration = configuration.spliceConfiguration (ConfigurationIdentifier.resolveAbsolute ("queuestring.consumer"));
      final IConfiguration kvConfiguration = configuration.spliceConfiguration (ConfigurationIdentifier.resolveAbsolute ("storestring"));
      context.consumer = context.cloudlet.getConnectorFactory (IAmqpQueueConsumerConnectorFactory.class).create (queueConfiguration, String.class, PlainTextDataEncoder.create(), new AmqpConsumerCallback (), context);
      context.kvStore = context.cloudlet.getConnectorFactory (IKvStoreConnectorFactory.class).create (kvConfiguration, String.class, PlainTextDataEncoder.create(), new KeyValueCallback (), context);
      return CallbackCompletion.createAndChained (context.consumer.initialize (),context.kvStore.initialize());
    }
View Full Code Here

TOP

Related Classes of eu.mosaic_cloud.portingtest.ConsumerQPTKV.KeyValueCallback

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.