apache/dubbo

[Bug] Dubbo3.3.2 ,Can not Use broadcast and Tag same time

Open

#15.850 aperta il 15 dic 2025

Vedi su GitHub
 (0 commenti) (0 reazioni) (0 assegnatari)Java (26.453 fork)batch import
help wantedtype/enhancement

Metriche repository

Star
 (41.524 star)
Metriche merge PR
 (Merge medio 7g 14h) (20 PR mergiate in 30 g)

Descrizione

Pre-check

  • I am sure that all the content I provide is in English.

Search before asking

  • I had searched in the issues and found no similar issues.

Apache Dubbo Component

Java SDK (apache/dubbo)

Dubbo Version

Dubbo 3.3.2

Steps to reproduce this issue

Start 4 service provider instances, each configured with different dubbo.provider.tag (e.g., t-01, t-02...) Consumer uses the following Reference configuration: @DubboReference( interfaceClass = BpRcvMsgApi.class, version = "1.0.0", group = "all-t", cluster = "broadcast" ) private ApiTest api; Invoke api.test() method Exception thrown: No provider available for the service

What you expected to happen

The broadcast call should succeed and send requests to all 4 provider instances.

Anything else

TagStateRouter filters out all providers in the router chain and returns an empty list, causing the call to fail. The issue is in org.apache.dubbo.rpc.cluster.router.tag.TagStateRouter.filterUsingStaticTag(),if tag is Null: result = filterInvoker( invokers, invoker -> StringUtils.isEmpty(invoker.getUrl().getParameter(TAG_KEY))); When tagRouterRule is not configured, this method performs static tag filtering with exact string matching. Since providers have tag=t-01 and broadcast requests don't specify a tag, the matching fails and eventually returns an empty list. Can at least one wildcard * be added?like: result = filterInvoker(invokers, invoker -> "*".equals(tag) || tag.equals(invoker.getUrl().getParameter(TAG_KEY)) );

Are you willing to submit a pull request to fix on your own?

  • Yes I am willing to submit a pull request on my own!

Code of Conduct

Guida contributor