You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicecomb.apache.org by GitBox <gi...@apache.org> on 2020/03/03 14:07:51 UTC
[GitHub] [servicecomb-java-chassis] zhangbeiyuan-hw opened a new issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
zhangbeiyuan-hw opened a new issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
URL: https://github.com/apache/servicecomb-java-chassis/issues/1614
前后调用后台,启动tls后,cse调用报 490错误
response: {"message":"Cse Internal Bad Request"}
求助该如何定位解决,配置文件如下
前台配置:
```yaml
# all interconnected microservices must belong to an application wth the same ID
APPLICATION_ID: openMec
service_description:
# name of the declaring microservice
name: meo-website
version: 1.0.0
environment: development
servicecomb:
service:
registry:
address: http://127.0.0.1:30100
rest:
address: 0.0.0.0:8081?sslEnabled=true #Rest通信地址
tracing:
enabled: false
http:
dispatcher:
edge:
default:
enabled: false
prefix: api
withVersion: false
prefixSegmentCount: 1
url:
enabled: true
mappings:
user-mgmt-be:
prefixSegmentCount: 1
path: "/user-mgmt-be/.*"
microserviceName: user-mgmt-be
versionRule: 0.0.0+
cors:
enabled: true
origin: "*"
allowCredentials: false
allowedMethod: GET,POST,HEAD,OPTIONS,PUT,DELETE
allowedHeader: x-rest-version,Content-Type,X-Requested-With,accept,Origin,Access-Control-Request-Method,Access-Control-Request-Headers,Authorization
exposedHeader: Location
#########SSL options
ssl.protocols: TLSv1.2
ssl.authPeer: false
ssl.checkCN.host: false
#########certificates config
ssl.trustStore: openmep.truststore
ssl.trustStoreType: JKS
ssl.trustStoreValue: 111111
ssl.keyStore: openmep.p12
ssl.keyStoreType: PKCS12
ssl.keyStoreValue: 111111
#ssl.crl: revoke.crl
ssl.sslCustomClass: org.mec.website.OpenMecSSLCustom
```
后台配置:
```yaml
servicecomb-config-order: 1
APPLICATION_ID: openMec #应用名
service_description:
name: user-mgmt-be #微服务名
version: 1.0.0 #微服务版本
environment: development
servicecomb:
service:
registry:
address: http://127.0.0.1:30100 #连接SC(Service Center,注册中心)的地址
# address: http://service-center:30100 #连接SC(Service Center,注册中心)的地址
rest:
address: 0.0.0.0:8067?sslEnabled=true #Rest通信地址
handler:
chain:
Provider:
default: bizkeeper-provider
cors:
enabled: true
origin: "*"
allowCredentials: false
allowedMethod: GET,POST,HEAD,OPTIONS,PUT,DELETE
allowedHeader: x-rest-version,Content-Type,X-Requested-With,accept,Origin,Access-Control-Request-Method,Access-Control-Request-Headers,Authorization
exposedHeader: Location
#########SSL options
ssl.protocols: TLSv1.2
ssl.authPeer: false
ssl.checkCN.host: true
#########certificates config
ssl.trustStore: openmep.truststore
ssl.trustStoreType: JKS
ssl.trustStoreValue: 111111
ssl.keyStore: openmep.p12
ssl.keyStoreType: PKCS12
ssl.keyStoreValue: 111111
#ssl.crl: revoke.crl
ssl.sslCustomClass: org.mec.houp.user.tls.OpenMecSSLCustom
```
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [servicecomb-java-chassis] zhangbeiyuan-hw commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
Posted by GitBox <gi...@apache.org>.
zhangbeiyuan-hw commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
URL: https://github.com/apache/servicecomb-java-chassis/issues/1614#issuecomment-594249256
### 补充调用接口
Request URL: https://openmep.org:8081/user-mgmt-be/v1/users/auth
Request Method: POST
Status Code: 490 Cse Internal Bad Request
Remote Address: 127.0.0.1:8081
Referrer Policy: no-referrer-when-downgrade
### Response Headers:
access-control-allow-origin: *
access-control-expose-headers: Location
content-length: 38
Content-Type: application/json; charset=utf-8
### Request Headers:
Accept: application/json, text/plain, */*
Accept-Encoding: gzip, deflate, br
Accept-Language: zh-CN,zh;q=0.9
Connection: keep-alive
Content-Length: 39
Content-Type: application/json;charset=UTF-8
Cookie: token=BasiclW7vuUlSr/8y7xt5L9Y8nQ==
Host: openmep.org:8081
Origin: https://openmep.org:8081
Referer: https://openmep.org:8081/index.html
Sec-Fetch-Dest: empty
Sec-Fetch-Mode: cors
Sec-Fetch-Site: same-origin
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.122 Safari/537.36
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [servicecomb-java-chassis] zhangbeiyuan-hw commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
Posted by GitBox <gi...@apache.org>.
zhangbeiyuan-hw commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
URL: https://github.com/apache/servicecomb-java-chassis/issues/1614#issuecomment-594282699
请教一下,下面这个配置是不是做路由的,应该如何配置,有没有指导?
```yaml
http:
dispatcher:
edge:
default:
enabled: false
prefix: api
withVersion: false
prefixSegmentCount: 1
url:
enabled: true
mappings:
user-mgmt-be:
prefixSegmentCount: 1
path: "/user-mgmt-be/.*"
microserviceName: user-mgmt-be
versionRule: 0.0.0+
```
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [servicecomb-java-chassis] zhangbeiyuan-hw commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
Posted by GitBox <gi...@apache.org>.
zhangbeiyuan-hw commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
URL: https://github.com/apache/servicecomb-java-chassis/issues/1614#issuecomment-594282283
早上重启服务又好了,没有昨晚那个异常了。现在可以访问
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [servicecomb-java-chassis] heyile commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
Posted by GitBox <gi...@apache.org>.
heyile commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
URL: https://github.com/apache/servicecomb-java-chassis/issues/1614#issuecomment-594251538
SDK 的版本提供下. 还有 你只把配置贴上来, 很多细节都不知道. 可以给一个链接, 连接到自己的github demo 仓库吗.
例如
```
ssl.sslCustomClass: org.mec.houp.user.tls.OpenMecSSLCustom
```
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [servicecomb-java-chassis] heyile commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
Posted by GitBox <gi...@apache.org>.
heyile commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
URL: https://github.com/apache/servicecomb-java-chassis/issues/1614#issuecomment-594298507
可以参考下这个文档. 类似问题可以尝试自助在文档里面搜索
http://1v96us.coding-pages.com/docs/java-chassis/zh_CN/edge/by-servicecomb-sdk/
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [servicecomb-java-chassis] zhangbeiyuan-hw commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
Posted by GitBox <gi...@apache.org>.
zhangbeiyuan-hw commented on issue #1614: 启动TLS后,前台通过cse调用后台接口,返回490错误
URL: https://github.com/apache/servicecomb-java-chassis/issues/1614#issuecomment-594309560
删除证书重新添加后,又报490错了,帮忙看一下,在我的私有库上
https://github.com/zhangbeiyuan-hw/test-project
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services