-
1. Re: Stop parsing every page?
ilya_shaikovsky Aug 5, 2008 5:47 AM (in response to bwobbones)developer guide
chapter 5
section 6
"5.6. Filter Configuration" -
2. Re: Stop parsing every page?
bwobbones Aug 5, 2008 8:48 AM (in response to bwobbones)Thanks for the reply!
Yep - read it, tried every combination of the context params that I can think of, but it seems that most of the options relate to the parsing of the html after an AJAX request has been done.
No matter what combination I use, NEKO or TIDY or NONE in whatever order, the FastHtmlParser is invoked for *every* page. Can anyone tell me why it's necessary for this to be done for pages that don't have any rich: or a4j: tags? -
3. Re: Stop parsing every page?
ronanker Aug 19, 2008 5:53 AM (in response to bwobbones)Hi bwobbones,
Have you tried to set to false the 'forceparser' parameter ?
If yes have you notice changes ?
By the way, how do you know that "the filter runs a parser on *every* page" ? -
4. Re: Stop parsing every page?
bwobbones Aug 19, 2008 8:38 PM (in response to bwobbones)It's easy to see in the debug that the FastHtmlParser is run on every request, whether it's an AJAX request or a http request. I've been through the code trying (unsuccessfully) to prevent this behaviour for pages that don't have any rich: or a4j: tags (see my other post over in the dev forum).
The forceparser init param does nothing to prevent this. Such a pain, it's really easy to get Richfaces running, but the performance makes it unuseable in an enterprise environment. -
5. Re: Stop parsing every page?
bwobbones Aug 19, 2008 8:40 PM (in response to bwobbones)My post: http://jboss.com/index.html?module=bb&op=viewtopic&t=140337
And the JIRA spawned from it: https://jira.jboss.org/jira/browse/RF-4095 -
6. Re: Stop parsing every page?
ronanker Aug 20, 2008 12:40 PM (in response to bwobbones)I don't really understand: what the 'forceparser' is for ?
In the doc it is said :Force parsing by a filter HTML syntax checker on any JSF page. If "false", only Ajax responses are parsed to syntax check and conversion to well-formed XML. Setting to "false" improves performance, but can provide visual effects on Ajax updates
.
Is it a bug ? The jira you 're talking about is about a new parameter.
What will be the differences between 'forceparser' and this new one ?
I also got performance problem. Not with ajax requests (they are fast) but with regular http requests. Loading an entire page is a pain, especially during the render response phase and on the client side. The javascript initialisation seems very heavy too.
-
7. Re: Stop parsing every page?
sergeysmirnov Aug 20, 2008 5:02 PM (in response to bwobbones)Where you find the bug? In the doc quote?
-
8. Re: Stop parsing every page?
bwobbones Aug 20, 2008 8:50 PM (in response to bwobbones)From what I can see in the code, the forceparser param is only used in the Tidy parser. I think that if don't have it set, tidy will only parse on AJAX requests and if you do it will parse for all requests. Otherwise, the FastHtmlParser is used. There's no getting away from parsing.
-
9. Re: Stop parsing every page?
nbelaevski Aug 21, 2008 8:05 PM (in response to bwobbones)Not by Tidy only, please see in ConfigurableXMLFilter:
if (isAjax || isForcexml()) { parser = parsers.getParser(viewId, mimetype); } else { parser = new FastHtmlParser(); }
isForcexml() == forceparser