apache / apache/servicecomb-java-chassis
CommonHttpDispatcher does not invoke handler chain and Configured Auth handler is not triggered
Ninguém assumiu esta issue ainda.
- Linguagem predominante
- Java
- Estrelas
- 1.9k
- Forks
- 813
- Merge médio
- 8d 23h
- PRs com merge (30d)
- 1
Descrição
I have an issue in CommonHttpDispatcher in that the consumer auth handlers configured for the registered third party microservice are not triggered.
Can you help here? Why handlers are not triggered on using this dispatcher?
This is my configuration. Here authClientGrant is a consumer auth handler configured for the registered third party service mfa-login-service . At run time after CommonHttpDispatcher picks the path for routing, the request is forwarded to the mfa-login-service . But none of the handlers are triggered before invocation.
servicecomb-config-order: 100
servicecomb:
service:
application: m1-services
name: gateway
properties:
allowCrossApp: true #whether to allow calls across applications
version: 0.0.4
registry:
# Default using local service center
address: http://localhost:30100
instance:
watch: false
edge:
filter:
addHeader:
enabled: true
allowedHeaders: xxx
handler:
chain:
Consumer:
default: loadbalance,tracing-consumer
service:
mfa-login-service: authClientGrant,loadbalance,tracing-consumer
Provider:
default: bizkeeper-provider,tracing-provider
rest:
address: 0.0.0.0:9091?sslEnabled=false
tracing:
enabled: true
http:
dispatcher:
edge:
http:
enabled: true
order: 1
mappings:
oauthAdmin:
path: "/admin/oauth/.*"
microserviceName: oauth-service
prefixSegmentCount: 1
versionRule: 0.0.0+
mfaServices:
path: "/a/mfa/login/.*"
microserviceName: mfa-login-service
prefixSegmentCount: 1
versionRule: 0.0.0+
Guia de contribuição
Nenhum guia de contribuição indexado para este repositório
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Direção de pesquisa
Comece rastreando o CommonHttpDispatcher desde o roteamento de edge até a cadeia de handlers Consumer configurada, usando a configuração da issue como setup de reprodução. Determine por que authClientGrant não é invocado antes do encaminhamento para mfa-login-service; considera-se concluído quando o handler Consumer configurado é executado para esse caminho do dispatcher, com o comportamento verificado por um teste de regressão, se o repositório fornecer um.
Escrita pelo modelo de indexação a partir do texto da issue.
Avaliação
- Stack de tecnologia
- java
- Domínio
- api, backend
- Tipo de issue
- Bug
- Dificuldade
- 4/5
- Tempo estimado
- 3-5 dias
- Status de atividade
- Estagnada
- Clareza
- Precisa de esclarecimento
- Facilidade para iniciantes
- 35/100