Skip to content

使用com.alibaba.dubbo.config.annotation.Service作为元注解,@AliasFor覆盖group属性失败 #7122

@jiangyongbing24

Description

@jiangyongbing24
  • I have searched the issues of this repository and believe that this is not a duplicate.
  • I have checked the FAQ of this repository and believe that this is not a duplicate.

Environment

  • Dubbo version: 2.6.2
  • Operating System version: windows 10
  • Java version: 1.8.0_241

Steps to reproduce this issue

创建一个以com.alibaba.dubbo.config.annotation.Service为元注解的注解,并且使用@aliasfor覆盖group属性

@Documented
@Service
@Target({ElementType.TYPE})
@Retention(RetentionPolicy.RUNTIME)
public @interface ContentService {
    @AliasFor(annotation = Service.class,attribute = "group")
    String value();
}

Expected Result

@ContentService注解能够正确的使用value属性给提供者设置对应的group。

Actual Result

提供者能够注册,但是group属性无法正确解析。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions