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

Optimize escape functions #188

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Optimize escape functions #188

wants to merge 1 commit into from

Conversation

isaacl
Copy link

@isaacl isaacl commented Aug 20, 2018

  • Use java.lang.StringBuilder instead of scala wrapper
  • Rewrite Html.buildString to use bulk copy methods
    when possible.

@lightbend-cla-validator

Hi @isaacl,

Thank you for your contribution! We really value the time you've taken to put this together.

Before we proceed with reviewing this pull request, please sign the Lightbend Contributors License Agreement:

http://www.lightbend.com/contribute/cla

@isaacl
Copy link
Author

isaacl commented Aug 20, 2018

cla signed

- Use java.lang.StringBuilder instead of scala wrapper
- Rewrite Html.buildString to use bulk copy methods
  when possible.
@isaacl
Copy link
Author

isaacl commented Aug 25, 2018

ping... I also posted in chat and got no response....

@marcospereira
Copy link
Member

Hi @isaacl,

I think it would be good to have JHM benchmarks added to the project so that we can better see/prove/check performance numbers when doing such optimizations:

https://github.com/ktoso/sbt-jmh

Basically, you write a benchmark for the function and run it before and after the optimization to see how the code change affected performance.

Do you have the time to do it?

Best.

@isaacl
Copy link
Author

isaacl commented Aug 27, 2018

if you're willing to do it, that would be easier for me, but I will get to it eventually.

@mkurz
Copy link
Member

mkurz commented Nov 10, 2018

@isaacl Do you have time to add the benchmarks?

@isaacl
Copy link
Author

isaacl commented Feb 28, 2019

Do you have a benchmark framework to use or are you asking for simple jmh?

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

Successfully merging this pull request may close these issues.

None yet

5 participants