You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Marcel Reutegger (JIRA)" <ji...@apache.org> on 2007/04/22 13:42:15 UTC
[jira] Created: (JCR-859) rep:excerpt() may return malformed XML
rep:excerpt() may return malformed XML
--------------------------------------
Key: JCR-859
URL: https://issues.apache.org/jira/browse/JCR-859
Project: Jackrabbit
Issue Type: Bug
Components: query
Affects Versions: 1.3
Reporter: Marcel Reutegger
Priority: Minor
Fix For: 1.4
The rep:excerpt() function does not encode the prefined XML entities but writes them as is into the excerpt XML. This may produce malformed XML.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
Re: Fwd: [jira] Created: (JCR-859) rep:excerpt() may return malformed
XML
Posted by Marcel Reutegger <ma...@gmx.net>.
Alexandru Popescu ☀ wrote:
> My next question would
> be: how is the fragment chosen (on what basis is the decission taken
> from where to where is the fragment to be returned - or is it the
> whole property value?).
The current function does not support arguments to influence the fragment size
or the number of fragments created for an excerpt. the defaults currently are:
- a maximum of 3 fragments in an excerpt
- approximately 150 characters in a fragment
A fragment is chosen based on the number of terms it contains that matched and
as a second criteria which one occurs first in the text.
regards
marcel
Re: Fwd: [jira] Created: (JCR-859) rep:excerpt() may return malformed XML
Posted by Alexandru Popescu ☀ <th...@gmail.com>.
On 4/25/07, Marcel Reutegger <ma...@gmx.net> wrote:
> Alexandru Popescu ☀ wrote:
> > Sorry to ask a beginner question but what is rep:excerpt() function
> > meant for?
>
> It creates a small XML fragment with text fragments where the query matches are
> marked up.
>
> example:
>
> //element(*, nt:resource)[jcr:contains(., 'peeter')]/rep:excerpt()
>
> on the jcr spec will returns something like:
>
> <excerpt><fragment>Acknowledgements This specification is the collaborative
> product of David Nuescheler (specification lead, Day Software),
> <highlight>Peeter</highlight> Piegaze (author, Day Software),
> and other members of the JSR 170 expert group, including</fragement><excerpt>
>
Thanks a lot for the explanations. I have also found this that
provides an explanation:
https://issues.apache.org/jira/browse/JCR-820. My next question would
be: how is the fragment chosen (on what basis is the decission taken
from where to where is the fragment to be returned - or is it the
whole property value?).
bests,
./alex
--
.w( the_mindstorm )p.
> regards
> marcel
>
Re: Fwd: [jira] Created: (JCR-859) rep:excerpt() may return malformed
XML
Posted by Marcel Reutegger <ma...@gmx.net>.
Alexandru Popescu ☀ wrote:
> Sorry to ask a beginner question but what is rep:excerpt() function
> meant for?
It creates a small XML fragment with text fragments where the query matches are
marked up.
example:
//element(*, nt:resource)[jcr:contains(., 'peeter')]/rep:excerpt()
on the jcr spec will returns something like:
<excerpt><fragment>Acknowledgements This specification is the collaborative
product of David Nuescheler (specification lead, Day Software),
<highlight>Peeter</highlight> Piegaze (author, Day Software),
and other members of the JSR 170 expert group, including</fragement><excerpt>
regards
marcel
Fwd: [jira] Created: (JCR-859) rep:excerpt() may return malformed XML
Posted by Alexandru Popescu ☀ <th...@gmail.com>.
Sorry to ask a beginner question but what is rep:excerpt() function meant for?
TIA,
./alex
--
.w( the_mindstorm )p.
_____________________________________
Alexandru Popescu, OSS Evangelist
TestNG/Groovy/AspectJ/WebWork/more...
Information Queue ~ www.InfoQ.com
---------- Forwarded message ----------
From: Marcel Reutegger (JIRA) <ji...@apache.org>
Date: Apr 22, 2007 2:42 PM
Subject: [jira] Created: (JCR-859) rep:excerpt() may return malformed XML
To: dev@jackrabbit.apache.org
rep:excerpt() may return malformed XML
--------------------------------------
Key: JCR-859
URL: https://issues.apache.org/jira/browse/JCR-859
Project: Jackrabbit
Issue Type: Bug
Components: query
Affects Versions: 1.3
Reporter: Marcel Reutegger
Priority: Minor
Fix For: 1.4
The rep:excerpt() function does not encode the prefined XML entities
but writes them as is into the excerpt XML. This may produce malformed
XML.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (JCR-859) rep:excerpt() may return malformed XML
Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/JCR-859?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jukka Zitting updated JCR-859:
------------------------------
Fix Version/s: (was: 1.4)
1.3.1
Merged to the 1.3 branch in revision 544281.
> rep:excerpt() may return malformed XML
> --------------------------------------
>
> Key: JCR-859
> URL: https://issues.apache.org/jira/browse/JCR-859
> Project: Jackrabbit
> Issue Type: Bug
> Components: query
> Affects Versions: 1.3
> Reporter: Marcel Reutegger
> Priority: Minor
> Fix For: 1.3.1
>
>
> The rep:excerpt() function does not encode the prefined XML entities but writes them as is into the excerpt XML. This may produce malformed XML.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (JCR-859) rep:excerpt() may return malformed XML
Posted by "Marcel Reutegger (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/JCR-859?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Marcel Reutegger resolved JCR-859.
----------------------------------
Resolution: Fixed
Fixed in revision: 531165
> rep:excerpt() may return malformed XML
> --------------------------------------
>
> Key: JCR-859
> URL: https://issues.apache.org/jira/browse/JCR-859
> Project: Jackrabbit
> Issue Type: Bug
> Components: query
> Affects Versions: 1.3
> Reporter: Marcel Reutegger
> Priority: Minor
> Fix For: 1.4
>
>
> The rep:excerpt() function does not encode the prefined XML entities but writes them as is into the excerpt XML. This may produce malformed XML.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.