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

simple escaper performance #45

Closed
aravorn6 opened this issue Jan 31, 2017 · 3 comments
Closed

simple escaper performance #45

aravorn6 opened this issue Jan 31, 2017 · 3 comments

Comments

@aravorn6
Copy link

I got a worse performance with v0.88

                long startTrainTime = System.currentTimeMillis();

		EmptyTag c =	img().withClass("image").withSrc(sb.toString());
	
		long endTrainTime = System.currentTimeMillis();
		DecimalFormat df = new DecimalFormat("#.#####");
		System.out.println(df.format((endTrainTime - startTrainTime) / 1000. / 60.));

v.0.7: 0,00007
v.0.88: 0,06715

looks like the last simple escaper change

@tipsy
Copy link
Owner

tipsy commented Jan 31, 2017

Wow, that's horrible. I went for a pretty slow implementation because of readability, but I guess I have to rewrite it.

@tipsy
Copy link
Owner

tipsy commented Mar 28, 2017

@aravorn6 Fixed in 29e16df

SimpleEscaper#short: 3ms
SimpleEscaper#long:  45ms
ApacheEscaper#short: 35ms
ApacheEscaper#long:  202ms

@tipsy tipsy closed this as completed Apr 12, 2017
@tipsy
Copy link
Owner

tipsy commented Apr 21, 2017

@aravorn6 0.99 is now out.

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