sean0407 commented on PR #2231: URL: https://github.com/apache/stormcrawler/pull/2231#issuecomment-6390847519
Thanks for the focused suggestions. I updated the implementation and tests in 70a050f:\n\n- Return immediately when the URL has no `&`, before extracting the fragment; inspect only the URL before `#` and preserve the fragment verbatim.\n- Find the last path segment with `lastIndexOf`/`indexOf` and build the repaired URL with `substring`, without `split`, `String.join`, or regex replacement.\n- Parameterize the slash-in-query cases (including the issue URL with an empty removal list) and the trailing-slash cases; clarify the unchanged-URL assertion.\n- Add regression cases for repairing `http://a.example/p&a=b&c=d` and leaving `http://a.example/p#a&b=c` unchanged.\n\nVerification: `mvn -B -ntp -pl core -Dtest=BasicURLNormalizerTest test` passed in an isolated Java 25 environment (34 tests, 0 failures/errors); `git diff --check` passed. GitHub currently reports no checks for the branch. -- 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. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
