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

Service Bus settlement support #1945

Merged
merged 18 commits into from
Oct 19, 2023
Merged
Show file tree
Hide file tree
Changes from 3 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 @@ -4,5 +4,5 @@
using System.Runtime.CompilerServices;
using Microsoft.Azure.Functions.Worker.Extensions.Abstractions;

[assembly: ExtensionInformation("Microsoft.Azure.WebJobs.Extensions.ServiceBus", "5.13.0")]
[assembly: ExtensionInformation("Microsoft.Azure.WebJobs.Extensions.ServiceBus", "5.13.1")]
[assembly: InternalsVisibleTo("Microsoft.Azure.Functions.Worker.Extensions.Tests, PublicKey=00240000048000009400000006020000002400005253413100040000010001005148be37ac1d9f58bd40a2e472c9d380d635b6048278f7d47480b08c928858f0f7fe17a6e4ce98da0e7a7f0b8c308aecd9e9b02d7e9680a5b5b75ac7773cec096fbbc64aebd429e77cb5f89a569a79b28e9c76426783f624b6b70327eb37341eb498a2c3918af97c4860db6cdca4732787150841e395a29cfacb959c1fd971c1")]
30 changes: 5 additions & 25 deletions extensions/Worker.Extensions.ServiceBus/src/Proto/settlement.proto
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ syntax = "proto3";

import "google/protobuf/timestamp.proto";
import "google/protobuf/empty.proto";
import "google/protobuf/wrappers.proto";

// this namespace will be shared between isolated worker and WebJobs extension so make it somewhat generic
option csharp_namespace = "Microsoft.Azure.ServiceBus.Grpc";
Expand Down Expand Up @@ -30,38 +29,19 @@ message CompleteRequest {
// The abandon message request containing the locktoken and properties to modify.
message AbandonRequest {
string locktoken = 1;
map<string, SettlementProperties> propertiesToModify = 2;
bytes propertiesToModify = 2;
}

// The deadletter message request containing the locktoken and properties to modify along with the reason/description.
message DeadletterRequest {
string locktoken = 1;
map<string, SettlementProperties> propertiesToModify = 2;
google.protobuf.StringValue deadletterReason= 3;
google.protobuf.StringValue deadletterErrorDescription = 4;
bytes propertiesToModify = 2;
string deadletterReason = 3;
JoshLove-msft marked this conversation as resolved.
Show resolved Hide resolved
string deadletterErrorDescription = 4;
}

// The defer message request containing the locktoken and properties to modify.
message DeferRequest {
string locktoken = 1;
map<string, SettlementProperties> propertiesToModify = 2;
}

// The settlement property can be of any type listed below, which
// corresponds to the types specified in
// https://learn.microsoft.com/dotnet/api/azure.messaging.servicebus.servicebusmessage.applicationproperties?view=azure-dotnet#remarks
// Note: this list doesn't match 1:1 with the supported Service Bus types, so compatible types are used in some cases - e.g.
// short uses int, TimeSpan uses string, etc. The full list of transforms can be found in the isolated worker extension source code.
message SettlementProperties {
oneof values {
string stringValue = 1;
int32 intValue = 2;
uint32 uintValue = 3;
int64 longValue = 4;
uint64 ulongValue = 5;
bool boolValue = 6;
float floatValue = 7;
double doubleValue = 8;
google.protobuf.Timestamp timestampValue = 9;
}
bytes propertiesToModify = 2;
}
Loading