Skip to content

Commit

Permalink
More letter renaming.
Browse files Browse the repository at this point in the history
  • Loading branch information
houseofcat committed Mar 31, 2024
1 parent 1bfc7ba commit 9247aeb
Show file tree
Hide file tree
Showing 9 changed files with 9 additions and 15 deletions.
2 changes: 1 addition & 1 deletion src/HouseofCat.RabbitMQ/Options/PublisherOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ namespace HouseofCat.RabbitMQ;
public class PublisherOptions
{
public bool CreatePublishReceipts { get; set; }
public int LetterQueueBufferSize { get; set; } = 10_000;
public int MessageQueueBufferSize { get; set; } = 10_000;
public BoundedChannelFullMode BehaviorWhenFull { get; set; } = BoundedChannelFullMode.Wait;

public bool Compress { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion src/HouseofCat.RabbitMQ/Publisher/Publisher.cs
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ public async Task StartAutoPublishAsync(Func<IPublishReceipt, ValueTask> process
private void SetupPublisher(Func<IPublishReceipt, ValueTask> processReceiptAsync = null)
{
_messageQueue = Channel.CreateBounded<IMessage>(
new BoundedChannelOptions(Options.PublisherOptions.LetterQueueBufferSize)
new BoundedChannelOptions(Options.PublisherOptions.MessageQueueBufferSize)
{
FullMode = Options.PublisherOptions.BehaviorWhenFull
});
Expand Down
5 changes: 2 additions & 3 deletions src/HouseofCat.RabbitMQ/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Review tutorials and documentation under `./guides/rabbitmq`.

Sample Config File
```javascript
```json
{
"FactoryOptions": {
"Uri": "amqp://guest:guest@localhost:5672/",
Expand All @@ -27,8 +27,7 @@ Sample Config File
"UseTransientChannels": false
},
"PublisherOptions": {
"LetterQueueBufferSize": 100,
"PriorityLetterQueueBufferSize": 100,
"MessageQueueBufferSize": 100,
"BehaviorWhenFull": 0,
"AutoPublisherSleepInterval": 1,
"CreatePublishReceipts": true,
Expand Down
3 changes: 1 addition & 2 deletions src/HouseofCat.RabbitMQ/SampleRabbitOptions.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@
"UseTransientChannels": false
},
"PublisherOptions": {
"LetterQueueBufferSize": 100,
"PriorityLetterQueueBufferSize": 100,
"MessageQueueBufferSize": 100,
"BehaviorWhenFull": 0,
"AutoPublisherSleepInterval": 0,
"CreatePublishReceipts": true,
Expand Down
3 changes: 1 addition & 2 deletions tests/RabbitMQ.Console.Tests/RabbitMQ.PubSubTests.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@
"UseTransientChannels": false
},
"PublisherOptions": {
"LetterQueueBufferSize": 100,
"PriorityLetterQueueBufferSize": 100,
"MessageQueueBufferSize": 100,
"BehaviorWhenFull": 0,
"AutoPublisherSleepInterval": 1,
"CreatePublishReceipts": true,
Expand Down
1 change: 0 additions & 1 deletion tests/RabbitMQ.Console.Tests/RabbitMQ.PublisherTests.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
},
"PublisherOptions": {
"LetterQueueBufferSize": 100,
"PriorityLetterQueueBufferSize": 100,
"BehaviorWhenFull": 0,
"AutoPublisherSleepInterval": 1,
"CreatePublishReceipts": true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@
"UseTransientChannels": false
},
"PublisherOptions": {
"LetterQueueBufferSize": 100,
"PriorityLetterQueueBufferSize": 100,
"MessageQueueBufferSize": 100,
"BehaviorWhenFull": 0,
"AutoPublisherSleepInterval": 1,
"CreatePublishReceipts": true,
Expand Down
2 changes: 1 addition & 1 deletion tests/RabbitMQ.Console.Tests/Tests/PublisherTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public static async Task RunAutoPublisherStandaloneAsync()
PublisherOptions = new PublisherOptions
{
CreatePublishReceipts = true,
LetterQueueBufferSize = 10_000,
MessageQueueBufferSize = 10_000,
BehaviorWhenFull = BoundedChannelFullMode.Wait,
Compress = false,
Encrypt = false,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@
"UseTransientChannels": false
},
"PublisherOptions": {
"LetterQueueBufferSize": 100,
"PriorityLetterQueueBufferSize": 100,
"MessageQueueBufferSize": 100,
"BehaviorWhenFull": 0,
"AutoPublisherSleepInterval": 1,
"CreatePublishReceipts": true,
Expand Down

0 comments on commit 9247aeb

Please sign in to comment.