[jbosstools-issues] [JBoss JIRA] Updated: (JBIDE-9588) Poor performance of XHTML template validation

Alexey Kazakov (JIRA) jira-events at lists.jboss.org
Mon Aug 29 21:12:26 EDT 2011


     [ https://issues.jboss.org/browse/JBIDE-9588?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alexey Kazakov updated JBIDE-9588:
----------------------------------

    Fix Version/s: 3.3.0.M4
                       (was: 3.3.0.M3)
         Priority: Critical  (was: Blocker)


IMO we should rewrite our XHTML Syntax validator at all.
We can't reuse WTP XML Validator since it connect to internet if the page has any DTD declaration which is not declared in XML Catalog.
Just try the following code with incorrect public ID and XML Validator will try to download the DTD from http://hans-moleman.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd:
{code}
<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTMLs 1.0 Transitional//EN"
    "http://hans-moleman.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    template="layout/template.xhtml">

</ui:composition>
{code}
I didn't find a way to avoid it.
I disabled XHTML Syntax validator for M3. Let's refactor our XHTML Syntax validator. We could use SAX parser to mark the text if it's not well-formed. We *don't* need to validate XHTML at all. And it seems that the only way to control document parsing is to use our own validator which didn't use WTP XML validator at all.

> Poor performance of XHTML template validation
> ---------------------------------------------
>
>                 Key: JBIDE-9588
>                 URL: https://issues.jboss.org/browse/JBIDE-9588
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: JSF, Seam2
>    Affects Versions: 3.3.0.M3
>         Environment: jbdevstudio-product-linux-gtk-5.0.0.v201108200628N-H743-M3.jar with extras:springide,git,m2e  EAP 5.1
>            Reporter: Libor Zoubek
>            Assignee: Victor Rubezhny
>            Priority: Critical
>             Fix For: 3.3.0.M4
>
>         Attachments: 2011-08-26-182513.png
>
>
> Right now it is almost impossible to create seam 2 project. Validation of XHTML templates takes too long (about 1-3minutes per 1 template)

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jbosstools-issues mailing list