Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Performance got degraded after upgrade from 1.5.7 version to 1.5.8 for the SAXScanner. #39

Closed
dharmendra027 opened this issue Jan 5, 2020 · 10 comments

Comments

@dharmendra027
Copy link

After upgrading antisamy jar version from 1.5.7 to 1.5.8 performance got down by 40-50%.
After comparing the 1.5.8 version of code with the 1.5.7. I found that in case of SAXScanner, in the class AntiSamySAXScanner after doing all the scanning process the cached item is not being added to the cachedItems Queue, because of which for every scan call object of CachedItem class is being created.
And this create operation for every scan is lowering down the performance.

@davewichers
Copy link
Collaborator

I think we need @davidbarbrowatwork to review your requested change because I believe it was his changes to 1.5.8 that affected the code you are trying to fix. Can you try to find/nudge him to get him to review/approve your requested change?

@dharmendra027
Copy link
Author

dharmendra027 commented Jan 20, 2020

Hi @davidbarbrowatwork, I found the performance is down by almost 50% in the 1.5.8 antisamy version comapre to 1.5.7.
I have debugged the issue and raised a pull request for it on @davewichers repository.
Can you please review it once as it is urgent for me.

@dharmendra027
Copy link
Author

Hi @davewichers , can you please try to connect to @davidbarbrowatwork to review this PR, as I couldn't get any response from.

@davewichers
Copy link
Collaborator

davewichers commented Feb 4, 2020 via email

@dharmendra027
Copy link
Author

Hi @davewichers, if you have twitter id of @davidbarbrowatwork can you please share.

Thanks

@davewichers
Copy link
Collaborator

I think it is @ dbarbrow.

@dharmendra027
Copy link
Author

Hi @davewichers,
Is the master branch of this repo is 1.5.8? I found the pom.xml of master master branch have project version 1.5.8 and could not find any specific branch for 1.5.8.

@davewichers
Copy link
Collaborator

This is the 1.5.8 release: https://github.com/nahsra/antisamy/releases and I believe there is a checkin tag for that release.
I've created a 1.5.9 branch, so I suggest you make any suggested changes to that branch. Hopefully you can add test cases that show the slowdown you are talking about, but correct behavior otherwise. And then when we add your requested change we can see a significant performance improvement but the same correct functionality verified by the test case.

@dharmendra027
Copy link
Author

dharmendra027 commented Mar 5, 2020

Hi @davewichers, Change that i have made was present in the branches below 1.5.8.

For example

And I got an instruction to use 1.5.8 version of the Antisamy.So I request to please consider it for version 1.5.8.
Thanks

davewichers added a commit that referenced this issue Mar 9, 2020
…ing prep for 1.5.8 release to address

issue #39. Upgrade a few components in pom that have been released since 1.5.8 release.
This should be the 1.5.9 release.
@davewichers
Copy link
Collaborator

The requested line has been added, and this fix was just released in version v1.5.9 of AntiSamy, along with a few dependency upgrades.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants