本文整理汇总了Java中org.graylog2.plugin.inputs.transports.NettyTransport类的典型用法代码示例。如果您正苦于以下问题:Java NettyTransport类的具体用法?Java NettyTransport怎么用?Java NettyTransport使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
NettyTransport类属于org.graylog2.plugin.inputs.transports包,在下文中一共展示了NettyTransport类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getRequestedConfiguration
import org.graylog2.plugin.inputs.transports.NettyTransport; //导入依赖的package包/类
@Override
public ConfigurationRequest getRequestedConfiguration() {
final ConfigurationRequest cr = super.getRequestedConfiguration();
if (cr.containsField(NettyTransport.CK_PORT)) {
cr.getField(NettyTransport.CK_PORT).setDefaultValue(5044);
}
return cr;
}
示例2: getRequestedConfigurationOverridesDefaultPort
import org.graylog2.plugin.inputs.transports.NettyTransport; //导入依赖的package包/类
@Test
public void getRequestedConfigurationOverridesDefaultPort() throws Exception {
final BeatsTransport.Config config = new BeatsTransport.Config();
final ConfigurationRequest requestedConfiguration = config.getRequestedConfiguration();
assertThat(requestedConfiguration.containsField(NettyTransport.CK_PORT)).isTrue();
assertThat(requestedConfiguration.getField(NettyTransport.CK_PORT).getDefaultValue()).isEqualTo(5044);
}
示例3: overrideDefaultValues
import org.graylog2.plugin.inputs.transports.NettyTransport; //导入依赖的package包/类
@Override
public void overrideDefaultValues(@Nonnull ConfigurationRequest cr)
{
if (cr.containsField(NettyTransport.CK_PORT))
{
cr.getField(NettyTransport.CK_PORT).setDefaultValue(DEFAULT_SFLOW_PORT);
}
}
示例4: overrideDefaultValues
import org.graylog2.plugin.inputs.transports.NettyTransport; //导入依赖的package包/类
@Override
public void overrideDefaultValues(@Nonnull ConfigurationRequest cr) {
if (cr.containsField(NettyTransport.CK_PORT)) {
cr.getField(NettyTransport.CK_PORT).setDefaultValue(2055);
}
}