You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@linkis.apache.org by GitBox <gi...@apache.org> on 2022/08/30 09:11:30 UTC

[GitHub] [incubator-linkis] binbinCheng opened a new pull request, #3131: [linkis-gateway-core] Modification of scala file floating red

binbinCheng opened a new pull request, #3131:
URL: https://github.com/apache/incubator-linkis/pull/3131

   [linkis-gateway-core] Modification of scala file floating red
   Related issues: #2875 


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

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@linkis.apache.org
For additional commands, e-mail: notifications-help@linkis.apache.org


[GitHub] [incubator-linkis] codecov[bot] commented on pull request #3131: [linkis-gateway-core] Modification of scala file floating red

Posted by GitBox <gi...@apache.org>.
codecov[bot] commented on PR #3131:
URL: https://github.com/apache/incubator-linkis/pull/3131#issuecomment-1231423217

   # [Codecov](https://codecov.io/gh/apache/incubator-linkis/pull/3131?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#3131](https://codecov.io/gh/apache/incubator-linkis/pull/3131?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (31af73a) into [dev-1.3.0](https://codecov.io/gh/apache/incubator-linkis/commit/0dd3915c0b515f8e31610c29688f58c99638e031?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (0dd3915) will **not change** coverage.
   > The diff coverage is `n/a`.
   
   ```diff
   @@             Coverage Diff              @@
   ##             dev-1.3.0    #3131   +/-   ##
   ============================================
     Coverage        15.14%   15.14%           
     Complexity        1209     1209           
   ============================================
     Files              777      777           
     Lines            25256    25256           
     Branches          3574     3574           
   ============================================
     Hits              3824     3824           
     Misses           20915    20915           
     Partials           517      517           
   ```
   
   
   
   :mega: We’re building smart automated test selection to slash your CI/CD build times. [Learn more](https://about.codecov.io/iterative-testing/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   


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

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@linkis.apache.org
For additional commands, e-mail: notifications-help@linkis.apache.org


[GitHub] [incubator-linkis] binbinCheng closed pull request #3131: [linkis-gateway-core] Modification of scala file floating red

Posted by GitBox <gi...@apache.org>.
binbinCheng closed pull request #3131: [linkis-gateway-core] Modification of scala file floating red
URL: https://github.com/apache/incubator-linkis/pull/3131


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

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@linkis.apache.org
For additional commands, e-mail: notifications-help@linkis.apache.org


[GitHub] [incubator-linkis] peacewong commented on a diff in pull request #3131: [linkis-gateway-core] Modification of scala file floating red

Posted by GitBox <gi...@apache.org>.
peacewong commented on code in PR #3131:
URL: https://github.com/apache/incubator-linkis/pull/3131#discussion_r958376447


##########
linkis-spring-cloud-services/linkis-service-gateway/linkis-gateway-core/src/main/scala/org/apache/linkis/gateway/route/GatewayRouter.scala:
##########
@@ -88,7 +89,7 @@ abstract class AbstractGatewayRouter extends GatewayRouter with Logging {
       tooManyDeal: List[String] => Option[String]
   ): Option[String] = {
     val services = SpringCloudFeignConfigurationCache.getDiscoveryClient.getServices
-      .filter(_.toLowerCase.contains(parsedServiceId.toLowerCase))
+      .filter(_.toLowerCase(Locale.ROOT).contains(parsedServiceId.toLowerCase(Locale.ROOT)))

Review Comment:
   Is it better to modify it to Locale.getDefault



##########
linkis-spring-cloud-services/linkis-service-gateway/linkis-gateway-core/src/main/scala/org/apache/linkis/gateway/parser/GatewayParser.scala:
##########
@@ -93,7 +95,7 @@ class DefaultGatewayParser(gatewayParsers: Array[GatewayParser]) extends Abstrac
     s"/api/rest_[a-zA-Z]+/(v\\d+)/${AbstractGatewayParser.GATEWAY_HEART_BEAT_URL.mkString("/")}".r
 
   override def shouldContainRequestBody(gatewayContext: GatewayContext): Boolean =
-    gatewayContext.getRequest.getMethod.toUpperCase != "GET" &&
+    gatewayContext.getRequest.getMethod.toUpperCase(Locale.ROOT) != "GET" &&

Review Comment:
   Is it better to modify it to Locale.getDefault



##########
linkis-spring-cloud-services/linkis-service-gateway/linkis-gateway-core/src/main/scala/org/apache/linkis/gateway/security/SecurityFilter.scala:
##########
@@ -90,7 +90,7 @@ object SecurityFilter extends Logging {
         return false
       }
       // Security certification support, solving verb tampering(安全认证支持,解决动词篡改)
-      gatewayContext.getRequest.getMethod.toUpperCase match {
+      gatewayContext.getRequest.getMethod.toUpperCase(Locale.ROOT) match {

Review Comment:
   Is it better to modify it to Locale.getDefault



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

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@linkis.apache.org
For additional commands, e-mail: notifications-help@linkis.apache.org