Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Bug: openFeatureAPI.client.onProviderReady invoked twice or not at all, instead of once

Đang mở
#2,053 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
48/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
java, kotlin
Lĩnh vực
api

Hướng nghiên cứu

Start with the reproducer linked in the issue and run gradle test to observe the duplicate callback. Trace the lifecycle from OpenFeatureAPI.createIsolated() through setProviderAndWait(flagdProvider) to client.onProviderReady(handler), including the in-process resolver. Done means the cause of the second invocation is identified and the expected single-callback behavior is covered by a regression test.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

I am using the following setup:

val openFeatureAPI = OpenFeatureAPI.createIsolated()
openFeatureAPI.setProviderAndWait(flagdProvider)
openFeatureAPI.client.onProviderReady(handler)

The flagdProvider is configured to use an in-process resolver.

I expect onProviderReady to be called exactly once. However, during testing, I noticed that it is occasionally invoked twice or not at all. Why does this happen?

I have created a reproducer to demonstrate this issue.

To reproduce run:

gradle test
Ngôn ngữ chính
Java
Star
128
Fork
60
Merge trung bình
19 giờ 11 phút
Pull request đã merge (30 ngày)
19

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của open-feature/java-sdk

Tất cả issue của open-feature/java-sdk

Issue tương tự

Thêm issue về Java

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.