servicecomb-java-chassis icon indicating copy to clipboard operation
servicecomb-java-chassis copied to clipboard

servlet.urlPattern is not effect when bind to additionalPorts

Open lalicw opened this issue 3 years ago • 1 comments

we use java-chassis-spring-boot-starter-servlet

and we config like this in the yml file:

# spring boot configurations
server:
  port: 9092  # should be same with servicecomb.rest.address to use web container
  additionalPorts: 8082

servicecomb:
    rest:
      servlet:
        urlPattern: /rest/*
      address: 0.0.0.0:8082  # use the additionalPorts
    provider:
      rest:
        scanRestController: false

but the urlPattern is not effect, we can just use this url to access the service. http://localhost:8082/sayHello?name=XXX

but we expect this http://localhost:8082/rest/sayHello?name=XXX

lalicw avatar Aug 25 '23 13:08 lalicw

Which version do you use?

liubao68 avatar Aug 26 '23 01:08 liubao68