Hungerburg | 1 Feb 2011 01:54
Favicon

Re: [trunk regression]: util:expand() throws index out of bounds exception after recent commits

Am 2011-02-01 00:29, schrieb Ron Van den Branden:
> Hi,
>
> I noticed how in eXist-trunk (rev. 13703) util:expand() sometimes throws
> an exception on nodes that have been retrieved with ft:query(). The
> exception occurs on queries like:
>

This looks very similar to the exception with kwic:expand and lucene 
search results that I posted earlier today and also was introced very 
recently.

--

-- 
peter

------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
Jay Straw | 1 Feb 2011 03:36
Picon

Re: On Hosting

Hi Michael,

I run my instances and deployments on "VPS"es -- virtual machines.

VPSVille is out of Quebec somewhere, I was with them for many months.
They have a very good customer console and a lot of features, though
you may be able to find a better deal on hardware elsewhere.

http://vpsville.ca/ iirc

They even offer a Gentoo image, which is the reason I went with them in
the first place.

HTH,
Jay

On Mon, 31 Jan 2011 11:23:00 -0800
Michael Joyce <ubermichael <at> gmail.com> wrote:

> Hello.
> 
> What should I be looking for in a hosting company, if I'm going to
> run a website from eXist? I don't have the budget to put a box in a
> cabinet somewhere. 
> 
> Or can anyone recommend a service provider, preferably with a data
> center in Canada?
> 
> Thanks,
> 
(Continue reading)

Wolfgang Meier | 1 Feb 2011 09:59
Gravatar

Re: length limit on constructed sequences?

The problem here is how the xquery parser deals with the sequence constructor: it recursively translates the expression into nested pairs. We have to add a normalization step to flatten this. I'll put it on my todo.

Wolfgang

------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
Ron Van den Branden | 1 Feb 2011 10:26
Picon

Re: [trunk regression]: util:expand() throws *start offset* out of bounds exception after recent commits

Hi Peter,

> This looks very similar to the exception with kwic:expand and lucene 
> search results that I posted earlier today and also was introced very 
> recently. 

Oops, that had slipped from my attention, thanks for notifying. Anyway, 
good to know these issues could be related and are recent. I tried to 
cook up a XQuery Unit test file from your test case, but failed to 
trigger the error. Could you perhaps pass on the actual queries that 
do/n't produce the errors?

Kind regards,

Ron

-- 
Ron Van den Branden
Wetenschappelijk attaché / Senior Researcher

Centrum voor Teksteditie en Bronnenstudie - CTB (KANTL)
Centre for Scholarly Editing and Document Studies
Koninklijke Academie voor Nederlandse Taal- en Letterkunde
Royal Academy of Dutch Language and Literature
Koningstraat 18 / b-9000 Gent / Belgium
tel: +32 9 265 93 51 / fax: +32 9 265 93 49
E-mail : ron.vandenbranden <at> kantl.be
www.kantl.be/ctb

------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
Nicolas BUONOMO | 1 Feb 2011 10:16
Picon

Re: Building eXist Client installer

Hi,

Le 31/01/2011 14:05, Michel Lawrence a écrit :
> Hello again,
>
> I have tried both options you suggested. Unfortunately both did not work. I will post some details:
>
> First of all, here is the locally created directory and its content:
>
> c:\path\to\eXist-Client (the root directory)
> c:\path\to\eXist-Client\ exist.jnlp (Option 1: the edited jnlp file, content is published later)
> c:\path\to\eXist-Client\ eXist_Client.bat (Option 2: the batch file, content is published later)
> c:\path\to\eXist-Client\lib\ [...].jar (all required jars have been copied in this subdirectory)
>
>
> 1.      First option: jnlp locally stored and edited as follow
>
> In file exist.jnlp:
>
> <?xml version="1.0" encoding="utf-8"?>
> <jnlp spec="1.0+" codebase="" href="exist.jnlp">   //codebase has been edited and set to pointing
nowhere. This will set the codebase to the directory where the file has been set
> [...]
> <resources>
> <j2se version="1.5+"/>
>     <jar href="lib/exist.jar" size="3474733"  main="true" />     // lib/ subdirectory has been inserted
>     <jar href="lib/xmldb.jar" size="9490" />
>     <jar href="lib/xmlrpc-common-3.1.2.jar" size="108656" />
>     <jar href="lib/xmlrpc-client-3.1.2.jar" size="56965" />
>     <jar href="lib/ws-commons-util-1.0.2.jar" size="34407" />
>     <jar href="lib/commons-pool-1.5.4.jar" size="96221" />
>     <jar href="lib/excalibur-cli-1.0.jar" size="23978" />
>     <jar href="lib/jEdit-syntax.jar" size="80933" />
>     <jar href="lib/jline-0.9.94.jar" size="87325" />
>     <jar href="lib/log4j-1.2.15.jar" size="391834" />
>     <jar href="lib/stax-api-1.0.1.jar" size="26514" />
>     <jar href="lib/sunxacml-1.2.jar" size="194789" />
> </resources>
> <application-desc main-class="org.exist.client.InteractiveClient">
>     <argument>-ouri=xmldb:exist://[non-published-URI]/exist/xmlrpc</argument>
>     <argument>--no-embedded-mode</argument>
> </application-desc>
> </jnlp>
>
>
> Java starts properly and finds all required jars. An exception is then raised when check for signatures:
>
> com.sun.deploy.net.JARSigningException: Détection d'une entrée non signée dans la ressource : file:/C:/Users/michella/Documents/06_Third-Tier/eXist-DB/eXist_Client/lib/exist.jar
>           at com.sun.javaws.security.SigningInfo.getCommonCodeSignersForJar(Unknown Source)
>           at com.sun.javaws.security.SigningInfo.check(Unknown Source)
>           at com.sun.javaws.LaunchDownload.checkSignedResourcesHelper(Unknown Source)
>           at com.sun.javaws.LaunchDownload.checkSignedResources(Unknown Source)
>           at com.sun.javaws.Launcher.prepareResources(Unknown Source)
>           at com.sun.javaws.Launcher.prepareAllResources(Unknown Source)
>           at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
>           at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
>           at com.sun.javaws.Launcher.launch(Unknown Source)
>           at com.sun.javaws.Main.launchApp(Unknown Source)
>           at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
>           at com.sun.javaws.Main$1.run(Unknown Source)
>           at java.lang.Thread.run(Unknown Source)
> At that point, I'm stuck ;-)
>

You can try to sign the jar this
./build.sh -f build/scripts/jarsigner.xml
in the $EXIST_HOME directory

This work for me

nicolas

------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
Ron Van den Branden | 1 Feb 2011 11:54
Picon

Re: [trunk regression]: util:expand() throws start offset out of bounds exception after recent commits

Hi,

On 1/02/2011 0:29, Ron Van den Branden wrote:
> This error doesn't occur in eXist-1.4.x (up to rev. 13705), and seems 
> to have been introduced in trunk after rev. 13592. Unfortunatly, I'm 
> apparently not SVN savvy enough to trace down the exact revision that 
> introduced it, but I suspect it might have something to do with recent 
> commits affecting symbols.dbx or the lucene index.
>

Correction: this exception *does* appear to affect eXist-1.4.x as well 
(which actually reinforces above suspicion that the backported symbols / 
lucene changes might be responsible).

Kind regards,

Ron

------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
Hungerburg | 1 Feb 2011 12:17
Favicon

Re: [trunk regression]: util:expand() throws *start offset* out of bounds exception after recent commits

Am 2011-02-01 10:26, schrieb Ron Van den Branden:
> I tried tocook up a XQuery Unit test file from your test case, but failed to
> trigger the error. Could you perhaps pass on the actual queries that
> do/n't produce the errors?

Hello Ron,

the lines a, b in the query, that fetches and displays lucene search 
results produce the error, I have to yank both to make the query pass:

let $hits := collection($coll)//foo[ft:query-field("bar", $query)]
for $hit in $hits

	a) let $expanded := kwic:expand($hit)
	b) { kwic:summarize($hit, <config width="40"/>) }

the error only happens, when the document, where the hit occurs, has 
empty elements above the location of the hit, and only if the string 
that produces the hit should have the hilight start at the beginning of 
the xml-element, that contains the string. This works reliably.

It looks to me like util:expand and some other function, or even 
util:expand itself, treat empty elements differently when counting 
offsets: either one or zero chars. If there is one empty element before 
the search hit, then (when the hit should start in the middle of a 
string from an element) the hilight will be off by one to the left, if 
two then two, etc. so it may become less than 0 if it hits somewhere 
later in the document?

The stack trace starts like that:

> 2011-02-01 11:51:02,509 [eXistThread-24] DEBUG (Expand.java [eval]:97) - Setting serialization
property: expand-xincludes = no
> 2011-02-01 11:51:02,510 [eXistThread-24] DEBUG (LuceneMatchListener.java [scanMatches]:205) -
Analyzer: org.apache.lucene.analysis.de.GermanAnalyzer <at> 4a415b46 for path: /produkt
> 2011-02-01 11:51:02,511 [eXistThread-24] DEBUG (RESTServer.java [doGet]:484) - start offset out of
bounds [at line 216, column 5, source: jar:file:/opt/eXist/exist.jar!/org/exist/xquery/lib/kwic.xql]
> In function:
> 	kwic:expand(element()) [63:42:jar:file:/opt/eXist/exist.jar!/org/exist/xquery/lib/kwic.xql]
> org.exist.xquery.XPathException: start offset out of bounds [at line 216, column 5, source: jar:file:/opt/eXist/exist.jar!/org/exist/xquery/lib/kwic.xql]
> In function:
> 	kwic:expand(element()) [63:42:jar:file:/opt/eXist/exist.jar!/org/exist/xquery/lib/kwic.xql]
> 	at org.exist.xquery.functions.util.Expand.eval(Expand.java:116)
> 	at org.exist.xquery.BasicFunction.eval(BasicFunction.java:68)
> 	at org.exist.xquery.InternalFunctionCall.eval(InternalFunctionCall.java:55)

Yours

--

-- 
peter

------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
Ron Van den Branden | 1 Feb 2011 13:35
Picon

Re: [trunk regression]: util:expand() throws *start offset* out of bounds exception after recent commits

Hi Peter,

Thanks for your description; it helped me isolate the problem with 
util:expand(). I'll focus on that function, as a) I'm not too familiar 
with the  kwic functions, and b) suspect the latter functions depend on 
util:expand(). Please feel free to add / comment your findings.

On 1/02/2011 12:17, Hungerburg wrote:
> the error only happens, when the document, where the hit occurs, has 
> empty elements above the location of the hit, and only if the string 
> that produces the hit should have the hilight start at the beginning 
> of the xml-element, that contains the string. This works reliably.
>

Attached is a XQuery Unit test file illustrating the problem 
(startOffsetTest.xml). In my tests, it seems that the problem rather is 
related to the complexity of elements that happen to precede a 
ft:query() hit. I only see problems when a hit is preceded by a complex 
element containing another element (either empty or with text content). 
Both clearly produce mismatched start offsets (see failing tests 
#7-#10). When the query matches the first string after such a complex 
node, an exception is thrown (failing tests #7, #9); when the second 
word is matched, the offset appears to be one position early (failing 
tests #8, #10). Note that the exception differs when match is 
immediately preceded by a complex element with text content (failing 
test #7: "start offset out of bounds"), or by a complex element with an 
empty element (failing test #9: just "Compilation error: -1").

OTOH, there are no problems:
   -when the matching node does not contain any elements preceding the 
match (succeeding tests #1-#2)
   -when the elements immediately preceding a match do not contain 
nesting elements, be they empty or having just text content (succeeding 
tests #3-#6)

I can confirm that eXist-1.4.x and trunk behave identical on this test file.

Kind regards,

Ron

-- 
Ron Van den Branden
Wetenschappelijk attaché / Senior Researcher

Centrum voor Teksteditie en Bronnenstudie - CTB (KANTL)
Centre for Scholarly Editing and Document Studies
Koninklijke Academie voor Nederlandse Taal- en Letterkunde
Royal Academy of Dutch Language and Literature
Koningstraat 18 / b-9000 Gent / Belgium
tel: +32 9 265 93 51 / fax: +32 9 265 93 49
E-mail : ron.vandenbranden <at> kantl.be
www.kantl.be/ctb

Attachment (startOffsetTest.xml): text/xml, 6372 bytes
------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
Markus Stefan Kaindl | 1 Feb 2011 13:36
Picon
Favicon

update insert without namespace?

Hello,

is it possible to perform an "update insert" using the eXist XQuery Update Extensions without having to
specify a namespace?

All the documents in my DB are stored with a TEI namespace (document root <TEI xmlns="http://www.tei-c.org/ns/1.0">...</TEI>).
When performing an update insert without using the TEI namespace declaration, the new element has an empty
xmlns="" attribute.
I could also insert the new node with TEI:element but then the added node will not have the same structure as
the others in the document.
Furthermore, it is not necessary to add an additional namespace to this element because it is already in the
scope of that particular namespace.

The following example should illustrate the problem. The newly created elements will either be
<TEI:element xmlns:TEI="http://www.tei-c.org/ns/1.0">...</TEI:element>
or
<element xmlns="">...</placeName>
while all I need is a simple
<element>...</element>.

I am using eXist 1.4.1dev, build 20101211. Thank you for your help.
Regards,
Markus

Digitale Bibliothek/Münchener
Digitalisierungszentrum (MDZ)
Digital Library/Munich Digitization Centre
Bayerische Staatsbibliothek
Ludwigstraße 16
80539 München

E-Mail: markus.kaindl <at> bsb-muenchen.de
Tel. +89/28638-2465
URL: www.bsb-muenchen.de

------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
Leif-Jöran Olsson | 1 Feb 2011 13:56

Re: On Hosting


Den 2011-01-31 20:23, Michael Joyce skrev:
> Hello.
> 
> What should I be looking for in a hosting company, if I'm going to run a website from eXist? I don't have the
budget to put a box in a cabinet somewhere. 
> 
> Or can anyone recommend a service provider, preferably with a data center in Canada?

Hi Michael, in addition to the other answers you already got I can tell
you we have some advanced plans for eXist-db specific hosting not too
long in the future with very flexible options. But I can already offer
you some shared hosting here in Sweden. It would therefore be nice to
hear about your requirements, wishes and price level expectations.

Cheers,
Leif-Jöran

Gmane