Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(bindings): remove pulsar binding #70

Merged
merged 2 commits into from
Nov 24, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,6 @@ internal static IChannelBinding LoadChannelBinding(ParseNode node)
{
case BindingType.Kafka:
return LoadBinding("ChannelBinding", property.Value, kafkaChannelBindingFixedFields);
case BindingType.Pulsar:
return LoadBinding("ChannelBinding", property.Value, pulsarChannelBindingFixedFields);
case BindingType.Websockets:
return LoadBinding("ChannelBinding", property.Value, webSocketsChannelBindingFixedFields);
default:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,6 @@ internal static IServerBinding LoadServerBinding(ParseNode node)
{
case BindingType.Kafka:
return LoadBinding("ServerBinding", property.Value, kafkaServerBindingFixedFields);
case BindingType.Pulsar:
return LoadBinding("ServerBinding", property.Value, pulsarServerBindingFixedFields);
default:
throw new System.Exception("ServerBinding not found");
}
Expand Down

This file was deleted.

3 changes: 0 additions & 3 deletions src/LEGO.AsyncAPI/Models/Bindings/BindingType.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,5 @@ public enum BindingType

[Display("websockets")]
Websockets,

[Display("pulsar")]
Pulsar,
}
}

This file was deleted.

66 changes: 0 additions & 66 deletions src/LEGO.AsyncAPI/Models/Bindings/Pulsar/PulsarServerBinding.cs

This file was deleted.

28 changes: 0 additions & 28 deletions src/LEGO.AsyncAPI/Models/Bindings/Pulsar/RetentionDefinition.cs

This file was deleted.

36 changes: 2 additions & 34 deletions test/LEGO.AsyncAPI.Tests/AsyncApiDocumentTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
using LEGO.AsyncAPI.Models.Bindings;
using LEGO.AsyncAPI.Models.Bindings.Http;
using LEGO.AsyncAPI.Models.Bindings.Kafka;
using LEGO.AsyncAPI.Models.Bindings.Pulsar;
using LEGO.AsyncAPI.Models.Interfaces;
using LEGO.AsyncAPI.Readers;
using LEGO.AsyncAPI.Writers;
Expand Down Expand Up @@ -463,9 +462,6 @@ public void Serialize_WithBindings_Serializes()
url: example.com
protocol: pulsar+ssl
description: test description
bindings:
pulsar:
tenant: contoso
channels:
testChannel:
publish:
Expand All @@ -480,14 +476,8 @@ public void Serialize_WithBindings_Serializes()
bindings:
kafka:
partitions: 2
replicas: 1
pulsar:
persistence: persistent
compaction: 9223372036854775807
retention:
time: 4
size: 1
deduplication: true";
replicas: 1";

var doc = new AsyncApiDocument();
doc.Info = new AsyncApiInfo()
{
Expand All @@ -498,15 +488,6 @@ public void Serialize_WithBindings_Serializes()
Description = "test description",
Protocol = "pulsar+ssl",
Url = "example.com",
Bindings = new AsyncApiBindings<IServerBinding>
{
{
new PulsarServerBinding
{
Tenant = "contoso",
}
},
}
});
doc.Channels.Add("testChannel",
new AsyncApiChannel
Expand All @@ -520,19 +501,6 @@ public void Serialize_WithBindings_Serializes()
Replicas = 1,
}
},
{
new PulsarChannelBinding
{
Compaction = long.MaxValue,
Deduplication = true,
Persistence = "persistent",
Retention = new RetentionDefinition()
{
Time = 4,
Size = 1,
},
}
},
},
Publish = new AsyncApiOperation
{
Expand Down