Skip to content

Commit

Permalink
Update to latest signature (#207)
Browse files Browse the repository at this point in the history
* Update to latest signature

* Changed IP to another internal local network
  • Loading branch information
masesdevelopers committed Jan 27, 2024
1 parent 108184e commit abc56e2
Show file tree
Hide file tree
Showing 27 changed files with 38 additions and 26 deletions.
12 changes: 12 additions & 0 deletions src/net/KEFCore/Infrastructure/Internal/KafkaOptionsExtension.cs
Original file line number Diff line number Diff line change
Expand Up @@ -417,6 +417,18 @@ public virtual Properties StreamsOptions(string applicationId)
return props;
}
/// <summary>
/// Build <see cref="ProducerConfigBuilder"/> for producers
/// </summary>
public virtual ProducerConfigBuilder ProducerOptionsBuilder()
{
ProducerConfigBuilder props = _producerConfigBuilder ?? new();
props.BootstrapServers = BootstrapServers;
props.Acks = ProducerConfigBuilder.AcksTypes.All;
props.Retries = 0;
props.LingerMs = 1;
return props;
}
/// <summary>
/// Build <see cref="Properties"/> for producers
/// </summary>
public virtual Properties ProducerOptions()
Expand Down
2 changes: 1 addition & 1 deletion src/net/KEFCore/Storage/Internal/EntityTypeProducer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ public EntityTypeProducer(IEntityType entityType, IKafkaCluster cluster)
}
else
{
_kafkaProducer = new KNetProducer<TKey, TValueContainer>(_cluster.Options.ProducerOptions(), _keySerdes, _valueSerdes);
_kafkaProducer = new KNetProducer<TKey, TValueContainer>(_cluster.Options.ProducerOptionsBuilder(), _keySerdes, _valueSerdes);
_streamData = _cluster.Options.UseKNetStreams ? new KNetStreamsRetriever<TKey, TValueContainer>(cluster, entityType)
: new KafkaStreamsTableRetriever<TKey, TValueContainer>(cluster, entityType, _keySerdes!, _valueSerdes!);
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"UseAvro": true,
"DatabaseName": "TestDBBenchmarkAvro",
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"NumberOfExecutions": 10
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
"UseAvro": true,
"DatabaseName": "TestDBBenchmarkAvro",
"UseCompactedReplicator": false,
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"NumberOfExecutions": 10
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
"DatabaseName": "TestDBBenchmarkAvro",
"UseCompactedReplicator": false,
"UseKNetStreams": false,
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"NumberOfExecutions": 10
}
2 changes: 1 addition & 1 deletion test/KEFCore.Benchmark.Test/Benchmark.KNetReplicator.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"DatabaseName": "TestDBBenchmark",
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"NumberOfExecutions": 10
}
2 changes: 1 addition & 1 deletion test/KEFCore.Benchmark.Test/Benchmark.KNetStreams.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"DatabaseName": "TestDBBenchmark",
"UseCompactedReplicator": false,
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"NumberOfExecutions": 10
}
2 changes: 1 addition & 1 deletion test/KEFCore.Benchmark.Test/Benchmark.KafkaStreams.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
"DatabaseName": "TestDBBenchmark",
"UseCompactedReplicator": false,
"UseKNetStreams": false,
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"NumberOfExecutions": 10
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"UseProtobuf": true,
"DatabaseName": "TestDBBenchmarkProtobuf",
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"NumberOfExecutions": 10
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
"UseProtobuf": true,
"DatabaseName": "TestDBBenchmarkProtobuf",
"UseCompactedReplicator": false,
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"NumberOfExecutions": 10
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
"DatabaseName": "TestDBBenchmarkProtobuf",
"UseCompactedReplicator": false,
"UseKNetStreams": false,
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"NumberOfExecutions": 10
}
2 changes: 1 addition & 1 deletion test/KEFCore.Complex.Test/ComplexTest.KNetReplicator.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"DatabaseName": "TestDBComplex",
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"NumberOfElements": 10,
"NumberOfExtraElements": 1
}
2 changes: 1 addition & 1 deletion test/KEFCore.Extractor.Test/Extractor.Test.Blog.Avro.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"TopicToSubscribe": "TestDBBenchmarkAvro.MASES.EntityFrameworkCore.KNet.Test.Blog"
}
2 changes: 1 addition & 1 deletion test/KEFCore.Extractor.Test/Extractor.Test.Blog.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"TopicToSubscribe": "TestDBBenchmark.MASES.EntityFrameworkCore.KNet.Test.Blog"
}
2 changes: 1 addition & 1 deletion test/KEFCore.StreamTest/StreamTest.KafkaStreams.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"UseCompactedReplicator": false,
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"UseCompactedReplicator": false,
"UseModelBuilder": true,
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}
2 changes: 1 addition & 1 deletion test/KEFCore.StreamTest/StreamTest.KafkaStreamsNoLoad.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
"DeleteApplicationData": false,
"LoadApplicationData": false,
"UseCompactedReplicator": false,
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
"DeleteApplicationData": false,
"LoadApplicationData": false,
"UseCompactedReplicator": false,
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}
2 changes: 1 addition & 1 deletion test/KEFCore.Test/Test.KNetReplicator.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}
2 changes: 1 addition & 1 deletion test/KEFCore.Test/Test.KNetReplicatorModelBuilder.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"UseModelBuilder": true,
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}
2 changes: 1 addition & 1 deletion test/KEFCore.Test/Test.KNetReplicatorNoLoad.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"DeleteApplicationData": false,
"LoadApplicationData": false,
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}
2 changes: 1 addition & 1 deletion test/KEFCore.Test/Test.KNetReplicatorWithEvents.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"BootstrapServers": "192.168.1.108:9092",
"BootstrapServers": "192.168.0.101:9092",
"DatabaseName": "TestDBWithEvents",
"NumberOfElements": 10,
"WithEvents": true
Expand Down
2 changes: 1 addition & 1 deletion test/KEFCore.Test/Test.KafkaStreams.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"UseCompactedReplicator": false,
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}
2 changes: 1 addition & 1 deletion test/KEFCore.Test/Test.KafkaStreamsModelBuilder.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"UseCompactedReplicator": false,
"UseModelBuilder": true,
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}
2 changes: 1 addition & 1 deletion test/KEFCore.Test/Test.KafkaStreamsNoLoad.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
"DeleteApplicationData": false,
"LoadApplicationData": false,
"UseCompactedReplicator": false,
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}
2 changes: 1 addition & 1 deletion test/KEFCore.Test/Test.KafkaStreamsPersisted.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
"DeleteApplicationData": false,
"LoadApplicationData": false,
"UseCompactedReplicator": false,
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}
2 changes: 1 addition & 1 deletion test/KEFCore.Test/TestAvro.KNetReplicatorModelBuilder.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"UseAvro": true,
"UseModelBuilder": true,
"BootstrapServers": "192.168.1.108:9092"
"BootstrapServers": "192.168.0.101:9092"
}

0 comments on commit abc56e2

Please sign in to comment.