Search in sources :

Example 6 with FloodlightModuleConfigurationProvider

use of org.openkilda.floodlight.config.provider.FloodlightModuleConfigurationProvider in project open-kilda by telstra.

the class PathVerificationService method initConfiguration.

@VisibleForTesting
void initConfiguration(FloodlightModuleContext moduleContext) throws FloodlightModuleException {
    FloodlightModuleConfigurationProvider provider = FloodlightModuleConfigurationProvider.of(moduleContext, this);
    config = provider.getConfiguration(PathVerificationServiceConfig.class);
    islBandwidthQuotient = config.getIslBandwidthQuotient();
    initAlgorithm(config.getHmac256Secret());
}
Also used : FloodlightModuleConfigurationProvider(org.openkilda.floodlight.config.provider.FloodlightModuleConfigurationProvider) VisibleForTesting(com.google.common.annotations.VisibleForTesting)

Example 7 with FloodlightModuleConfigurationProvider

use of org.openkilda.floodlight.config.provider.FloodlightModuleConfigurationProvider in project open-kilda by telstra.

the class KafkaChannel method init.

@Override
public void init(FloodlightModuleContext moduleContext) {
    FloodlightModuleConfigurationProvider provider = FloodlightModuleConfigurationProvider.of(moduleContext, this);
    config = provider.getConfiguration(KafkaChannelConfig.class);
    topics = provider.getConfiguration(KafkaTopicsConfig.class);
}
Also used : FloodlightModuleConfigurationProvider(org.openkilda.floodlight.config.provider.FloodlightModuleConfigurationProvider) KafkaTopicsConfig(org.openkilda.config.KafkaTopicsConfig)

Example 8 with FloodlightModuleConfigurationProvider

use of org.openkilda.floodlight.config.provider.FloodlightModuleConfigurationProvider in project open-kilda by telstra.

the class KafkaMessageCollector method startUp.

@Override
public void startUp(FloodlightModuleContext moduleContext) {
    logger.info("Starting {}", this.getClass().getCanonicalName());
    FloodlightModuleConfigurationProvider provider = FloodlightModuleConfigurationProvider.of(moduleContext, this);
    KafkaMessageCollectorConfig consumerConfig = provider.getConfiguration(KafkaMessageCollectorConfig.class);
    KafkaChannel kafkaChannel = moduleContext.getServiceImpl(KafkaUtilityService.class).getKafkaChannel();
    logger.info("region: {}", kafkaChannel.getRegion());
    ConsumerLauncher launcher = new ConsumerLauncher(moduleContext, consumerConfig);
    launchTopics(consumerConfig, kafkaChannel, launcher);
}
Also used : FloodlightModuleConfigurationProvider(org.openkilda.floodlight.config.provider.FloodlightModuleConfigurationProvider) KafkaChannel(org.openkilda.floodlight.KafkaChannel) KafkaUtilityService(org.openkilda.floodlight.service.kafka.KafkaUtilityService)

Example 9 with FloodlightModuleConfigurationProvider

use of org.openkilda.floodlight.config.provider.FloodlightModuleConfigurationProvider in project open-kilda by telstra.

the class KildaCore method init.

@Override
public void init(FloodlightModuleContext moduleContext) {
    FloodlightModuleConfigurationProvider provider = FloodlightModuleConfigurationProvider.of(moduleContext, this);
    config = provider.getConfiguration(KildaCoreConfig.class);
}
Also used : FloodlightModuleConfigurationProvider(org.openkilda.floodlight.config.provider.FloodlightModuleConfigurationProvider)

Example 10 with FloodlightModuleConfigurationProvider

use of org.openkilda.floodlight.config.provider.FloodlightModuleConfigurationProvider in project open-kilda by telstra.

the class FeatureDetectorService method setup.

@Override
public void setup(FloodlightModuleContext context) throws FloodlightModuleException {
    FloodlightModuleConfigurationProvider provider = FloodlightModuleConfigurationProvider.of(context, SwitchManager.class);
    FeatureDetectorServiceConfig config = provider.getConfiguration(FeatureDetectorServiceConfig.class);
    features = ImmutableList.of(new MeterFeature(config.isOvsMetersEnabled()), new InaccurateMeterFeature(), new BfdFeature(), new BfdReviewFeature(), new GroupPacketOutFeature(), new ResetCountsFlagFeature(), new LimitedBurstSizeFeature(), new NoviFlowCopyFieldFeature(), new PktpsFlagFeature(), new MatchUdpPortFeature(), new MaxBurstCoefficientLimitationFeature(), new MultiTableFeature(), new InaccurateSetVlanVidAction(), new NoviFlowPushPopVxlanFeature(), new HalfSizeMetadataFeature(), new NoviFlowSwapEthSrcEthDstFeature(), new GroupsFeature(), new KildaOvsCopyFieldFeature(), new KildaOvsSwapFieldFeature(), new KildaOvsPushPopMatchVxlanFeature(), new LagFeature());
}
Also used : NoviFlowSwapEthSrcEthDstFeature(org.openkilda.floodlight.feature.NoviFlowSwapEthSrcEthDstFeature) ResetCountsFlagFeature(org.openkilda.floodlight.feature.ResetCountsFlagFeature) GroupPacketOutFeature(org.openkilda.floodlight.feature.GroupPacketOutFeature) LimitedBurstSizeFeature(org.openkilda.floodlight.feature.LimitedBurstSizeFeature) MaxBurstCoefficientLimitationFeature(org.openkilda.floodlight.feature.MaxBurstCoefficientLimitationFeature) KildaOvsCopyFieldFeature(org.openkilda.floodlight.feature.KildaOvsCopyFieldFeature) KildaOvsSwapFieldFeature(org.openkilda.floodlight.feature.KildaOvsSwapFieldFeature) LagFeature(org.openkilda.floodlight.feature.LagFeature) MultiTableFeature(org.openkilda.floodlight.feature.MultiTableFeature) HalfSizeMetadataFeature(org.openkilda.floodlight.feature.HalfSizeMetadataFeature) FloodlightModuleConfigurationProvider(org.openkilda.floodlight.config.provider.FloodlightModuleConfigurationProvider) BfdFeature(org.openkilda.floodlight.feature.BfdFeature) BfdReviewFeature(org.openkilda.floodlight.feature.BfdReviewFeature) NoviFlowCopyFieldFeature(org.openkilda.floodlight.feature.NoviFlowCopyFieldFeature) KildaOvsPushPopMatchVxlanFeature(org.openkilda.floodlight.feature.KildaOvsPushPopMatchVxlanFeature) InaccurateSetVlanVidAction(org.openkilda.floodlight.feature.InaccurateSetVlanVidAction) NoviFlowPushPopVxlanFeature(org.openkilda.floodlight.feature.NoviFlowPushPopVxlanFeature) MatchUdpPortFeature(org.openkilda.floodlight.feature.MatchUdpPortFeature) InaccurateMeterFeature(org.openkilda.floodlight.feature.InaccurateMeterFeature) MeterFeature(org.openkilda.floodlight.feature.MeterFeature) GroupsFeature(org.openkilda.floodlight.feature.GroupsFeature) InaccurateMeterFeature(org.openkilda.floodlight.feature.InaccurateMeterFeature) PktpsFlagFeature(org.openkilda.floodlight.feature.PktpsFlagFeature)

Aggregations

FloodlightModuleConfigurationProvider (org.openkilda.floodlight.config.provider.FloodlightModuleConfigurationProvider)11 FeatureDetectorService (org.openkilda.floodlight.service.FeatureDetectorService)4 IOFSwitchService (net.floodlightcontroller.core.internal.IOFSwitchService)3 Before (org.junit.Before)3 KildaCoreConfig (org.openkilda.floodlight.KildaCoreConfig)3 KafkaChannel (org.openkilda.floodlight.KafkaChannel)2 KildaCore (org.openkilda.floodlight.KildaCore)2 KafkaUtilityService (org.openkilda.floodlight.service.kafka.KafkaUtilityService)2 SwitchManagerConfig (org.openkilda.floodlight.switchmanager.SwitchManagerConfig)2 SwitchFlowFactory (org.openkilda.floodlight.switchmanager.factory.SwitchFlowFactory)2 VisibleForTesting (com.google.common.annotations.VisibleForTesting)1 JdkProxyStaticConfigurationFactory (com.sabre.oss.conf4j.factory.jdkproxy.JdkProxyStaticConfigurationFactory)1 MapConfigurationSource (com.sabre.oss.conf4j.source.MapConfigurationSource)1 ExecutionException (java.util.concurrent.ExecutionException)1 TimeoutException (java.util.concurrent.TimeoutException)1 IFloodlightProviderService (net.floodlightcontroller.core.IFloodlightProviderService)1 IOFSwitch (net.floodlightcontroller.core.IOFSwitch)1 SwitchDescription (net.floodlightcontroller.core.SwitchDescription)1 FloodlightModuleException (net.floodlightcontroller.core.module.FloodlightModuleException)1 IRestApiService (net.floodlightcontroller.restserver.IRestApiService)1