CodeGenieApp / CodeGenieApp/serverless-express
Req.url incorrectly evaluated for paths with nested proxy - ApiGateway
- Lingua principale
- JavaScript
- Stelle
- 5.3k
- Fork
- 676
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
GIven the following resource `/testing/{proxy+}` a call to `/testing/creategroup` is evaluated to `/creategroup` rather than `/testing/creatgroup`.
Looking at [getPathWithQueryStringParams](https://github.com/vendia/serverless-express/blob/671f914429e9708bfb1ee6ba76b5947a917592df/src/event-sources/utils.js#L7), it appears that if proxy pathParameter is present, it is simply used, discarding the other parts. Would substituting the value for proxy for the token {proxxy+} into `event.resource` (/testing/{proxy+}) be a potential approach to fixing this?
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Start in src/event-sources/utils.js at getPathWithQueryStringParams, using the reported resource /testing/{proxy+} and request path /testing/creategroup as the reproduction case. Trace how the proxy path parameter is combined with event.resource, then verify that the resulting Req.url retains the /testing prefix for nested proxy paths.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- aws, express, javascript
- Ambito
- api, backend
- Tipo di issue
- Bug
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Stato di attività
- Ferma
- Chiarezza
- Specificata chiaramente
- Idoneità per principianti
- 42/100