Azure / Azure/azure-functions-java-worker
ServiceBus support with partition and duplicate detection
- Ngôn ngữ chính
- Java
- Star
- 103
- Fork
- 74
- Merge trung bình
- 4 ngày 8 giờ
- Pull request đã merge (30 ngày)
- 2
Mô tả
We try to send messages to ServiceBus using functions binding. Bellow Code worked without partitions. But we are facing issues with partition and duplicate detection.
@ServiceBusQueueOutput
@ServiceBusTopicOutput
Sample code to reproduce this issue
```
@FunctionName("QueueTrigger")
public void run(
@ServiceBusQueueTrigger(name = "inMessage", queueName = "%sbInputQueue%", connection = "sbconnection") Message inMessage,
@ServiceBusTopicOutput(name = "topicMessage", topicName = "fx-demo-topic", subscriptionName = "fx-demo-subscription", connection = "sbconnection") OutputBinding topicMessage,
final ExecutionContext context) {
context.getLogger().info("Queue Msg Received " + inMessage.toString());
topicMessage.setValue(inMessage);
context.getLogger().info("Java Service Bus Listing Queue trigger executed.");
}
}
```
Error message :
System.Private.CoreLib: Exception while executing function: Functions.QueueTrigger. Microsoft.Azure.ServiceBus: Message to a partitioned entity with duplicate detection enabled must have either PartitionKey or MessageId
Hướng dẫn đóng góp
Hướng nghiên cứu
Bắt đầu với binding @ServiceBusTopicOutput trong hàm QueueTrigger đã tái hiện và ngoại lệ Service Bus được báo cáo. Theo dõi cách worker Java tạo Message gửi đi cho các thực thể được phân vùng khi tính năng phát hiện trùng lặp được bật. Được xem là hoàn tất khi bản tái hiện được cung cấp không còn thất bại mà vẫn giữ nguyên hành vi phân vùng và phát hiện trùng lặp như mong đợi.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- azure, java
- Lĩnh vực
- backend, distributed-systems
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Cần làm rõ
- Mức phù hợp với người mới
- 25/100