BC: Add server params (REMOTE_ADDR) to PSR request - #3
Conversation
|
Hello @bohanyang Thank you for your PR. Have you checked if there is no way getting this information from the workerman request itself? Regards Dominik |
|
Yeah, it has to cause a BC break since the WorkermanRequest contains no information beyond HTTP header lines and body. I've updated the parameter order according to your suggestion. |
|
Please update https://github.com/chubbyphp/chubbyphp-workerman-request-handler/blob/master/composer.json#L53 and the version in the readme |
|
Version updated |
|
@bohanyang sorry, i should have been more precise, version needs to be 2.0 |
|
Oh sorry it's a major version update, my fault. |
|
@bohanyang it seems that the CI doesn't get started on the CI, have you run the tests locally? I guess the OnMessageTest should fail. |
|
Tests will pass now. |
|
@bohanyang thanks for your contribution |
Because we need the client IP.
Even if
X-Forwarded-FororX-Real-IPheader can be used,it's important to use the
REMOTE_ADDRto determine whetherthe request comes from a trusted edge server/proxy.