midnight2104 opened a new issue, #3317:
URL: https://github.com/apache/incubator-shenyu/issues/3317

   ### Question
   
   1. org.apache.shenyu.client.apache.dubbo.ApacheDubboServiceBeanListener
   ```java
       public ApacheDubboServiceBeanListener(final PropertiesConfig 
clientConfig, final ShenyuClientRegisterRepository 
shenyuClientRegisterRepository) {
           Properties props = clientConfig.getProps();
           String contextPath = 
props.getProperty(ShenyuClientConstants.CONTEXT_PATH);
           String appName = props.getProperty(ShenyuClientConstants.APP_NAME);
           if (StringUtils.isBlank(contextPath)) {
               throw new ShenyuClientIllegalArgumentException("apache dubbo 
client must config the contextPath or appName");
           }
           this.contextPath = contextPath;
           this.appName = appName;
           this.host = props.getProperty(ShenyuClientConstants.HOST);
           this.port = props.getProperty(ShenyuClientConstants.PORT);
           executorService = Executors.newSingleThreadExecutor(new 
ThreadFactoryBuilder().setNameFormat("shenyu-apache-dubbo-client-thread-pool-%d").build());
           publisher.start(shenyuClientRegisterRepository);
       }
   ```
   
   A thread pool(executorService ) was created in the constructor, but not 
used. Is it possible to delete it?
   
   2. ShenyuDubboClient
   Does ShenyuDubboClient only work on methods and not on classes?
   The current definitions are as follows:
   ```java
   
   @Retention(RetentionPolicy.RUNTIME)
   @Target({ElementType.TYPE, ElementType.METHOD})
   @Inherited
   public @interface ShenyuDubboClient {
   
       /**
        * Path string.
        *
        * @return the string
        */
       String path();
   
       /**
        * Rule name string.
        *
        * @return the string
        */
       String ruleName() default "";
   
       /**
        * Desc string.
        *
        * @return String string
        */
       String desc() default "";
   
       /**
        * Enabled boolean.
        *
        * @return the boolean
        */
       boolean enabled() default true;
   }
   ```
   Shouldn't we change `@Target({ElementType.TYPE, ElementType.METHOD}) ` to 
`@Target({ElementType.METHOD})`?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@shenyu.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to