You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by "linghengqian (via GitHub)" <gi...@apache.org> on 2024/08/03 07:20:11 UTC

[I] `shardingsphere-logging-core` should not set the scope of `logback-classic` to `compile` [shardingsphere]

linghengqian opened a new issue, #32377:
URL: https://github.com/apache/shardingsphere/issues/32377

   ## Feature Request
   
   **For English only**, other languages will not be accepted.
   
   Please pay attention on issues you submitted, because we maybe need more details. 
   If no response anymore and we cannot make decision by current information, we will **close it**.
   
   Please answer these questions before submitting your issue. Thanks!
   
   ### Is your feature request related to a problem?
   
   - This is one of the investigations into #31526, with the introduction of the HiveServer2 JDBC Driver, Log4j1, Log4j2 and Logback started to appear on the classpath at the same time.
   - This also involves further investigation into #32347 .
   > ShardingSphere-JDBC is a SDK.
   
   - External authentication is at https://github.com/apache/hive/pull/5375 on the apache/hive side.
   
   ### Describe the feature you would like.
   
   - `org.apache.shardingsphere:shardingsphere-logging-core` should not set the scope of `ch.qos.logback:logback-classic` to `compile`.
   - The following clarification exists at https://www.slf4j.org/codes.html#multiple_bindings .
   
   > Embedded components such as libraries or frameworks should not declare a dependency on any SLF4J binding but only depend on slf4j-api. When a library declares a compile-time dependency on a SLF4J binding, it imposes that binding on the end-user, thus negating SLF4J's purpose. When you come across an embedded component declaring a compile-time dependency on any SLF4J binding, please take the time to contact the authors of said component/library and kindly ask them to mend their ways.
   
   - I think the scope of `ch.qos.logback:logback-classic` should be set to provided to stop the Slf4j implementation from being passed on. Downstream applications should always manually import their favorite Slf4j implementation.
   


-- 
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-unsubscribe@shardingsphere.apache.org.apache.org

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


Re: [I] `shardingsphere-logging-core` should not set the scope of `logback-classic` to `compile` [shardingsphere]

Posted by "RaigorJiang (via GitHub)" <gi...@apache.org>.
RaigorJiang commented on issue #32377:
URL: https://github.com/apache/shardingsphere/issues/32377#issuecomment-2267249767

   Yes, the design of logging rule is flawed. I think it can be disabled (temporarily removed from modules) before it is actually available.


-- 
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-unsubscribe@shardingsphere.apache.org

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


Re: [I] `shardingsphere-logging-core` should not set the scope of `logback-classic` to `compile` [shardingsphere]

Posted by "RaigorJiang (via GitHub)" <gi...@apache.org>.
RaigorJiang closed issue #32377: `shardingsphere-logging-core` should not set the scope of `logback-classic` to `compile`
URL: https://github.com/apache/shardingsphere/issues/32377


-- 
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-unsubscribe@shardingsphere.apache.org

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


Re: [I] `shardingsphere-logging-core` should not set the scope of `logback-classic` to `compile` [shardingsphere]

Posted by "RaigorJiang (via GitHub)" <gi...@apache.org>.
RaigorJiang closed issue #32377: `shardingsphere-logging-core` should not set the scope of `logback-classic` to `compile`
URL: https://github.com/apache/shardingsphere/issues/32377


-- 
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-unsubscribe@shardingsphere.apache.org

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


Re: [I] `shardingsphere-logging-core` should not set the scope of `logback-classic` to `compile` [shardingsphere]

Posted by "linghengqian (via GitHub)" <gi...@apache.org>.
linghengqian commented on issue #32377:
URL: https://github.com/apache/shardingsphere/issues/32377#issuecomment-2271230114

   - The handling of #32389 is not reasonable, because now the operation of using ShardingSphere of master branch becomes as follows.
   ```xml
   <dependency>
       <groupId>org.apache.shardingsphere</groupId>
       <artifactId>shardingsphere-jdbc</artifactId>
       <version>5.1.0-SNAPSHOT</version>
   </dependency>
   <dependency>
       <groupId>ch.qos.logback</groupId>
       <artifactId>logback-classic</artifactId>
       <version>1.2.13</version>
   </dependency>
   ```
   - In fact, we need to change all the calls to Logback Java API in `shardingsphere-logging-core` to calls to Slf4j Java API.


-- 
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-unsubscribe@shardingsphere.apache.org

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


Re: [I] `shardingsphere-logging-core` should not set the scope of `logback-classic` to `compile` [shardingsphere]

Posted by "linghengqian (via GitHub)" <gi...@apache.org>.
linghengqian commented on issue #32377:
URL: https://github.com/apache/shardingsphere/issues/32377#issuecomment-2267390504

   - I opened #32389 to activate CI. Once merged, logging behavior for most modules will look the same as if the following dependencies were added.
   
   ```xml
   <dependency>
       <groupId>org.slf4j</groupId>
       <artifactId>slf4j-nop</artifactId>
       <version>1.7.36</version>
   </dependency>
   ```


-- 
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-unsubscribe@shardingsphere.apache.org

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