ron.vandenbranden@kantl.be | 18 Sep 01:13 2014
Picon

how to "hide" resources (from eXide)?

Hi,

Apologies if I'm missing something obvious, but I'm wondering if it's 
possible to "hide" collections from the outside world (in eXide). For 
example, with default permissions, an anonymous user can browse the 
entire content of the db with eXide, and open files. Only writing 
requires relevant permissions. Is it possible to restrict this, so that 
resources can't be opened, or aren't shown to the world? Is there 
perhaps an eXide setting?

Of course, it should remain possible to execute the code publicly in a 
web app, without requiring users of the app to authenticate. When 
tightening resource permissions so that only the "owner" can 
read/write/execute, this blocks the web app too, since it needs to 
access the resources as the "other" user. The only thing I could think 
of was to make the controller.xql authenticate as the owner, or a group 
member, but I'm wondering if there is a more elegant way.

So, is there a way to "hide" resources from non-authenticated users, 
while keeping them executable at the same time?

Thanks for your advice,

Ron

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
(Continue reading)

Martin Holmes | 18 Sep 01:36 2014
Picon
Picon

Trapping for http status 500

Hi there,

[Using eXist 2.1, built last year, running under Tomcat 7.]

For reasons too obscure to be worth explaining, an Apache front end 
which I don't directly control is very occasionally feeding to my eXist 
app a URL that ends in a "page name" that like this:

  CAST2&title=Castle Baynard/.htm

This triggers this sort of error:

HTTP Status 500 - An error occurred while processing request to 
[...]/CAST2&title=Castle Baynard/.htm: err:XPST0003 Invalid character 
(=) in entity name (title) or missing ;

The error appears to originate in the XQueryURLRewrite module (short 
stacktrace below).

I've tried to trap for this in the controller.xql, but I'm pretty sure 
the error is raised before the URL reaches the controller code. Am I 
right about this? Is there anything I could do to catch this error and 
redirect to a more user-friendly response page?

All help appreciated,
Martin

Stacktrace:
root cause

(Continue reading)

W.S. Hager | 17 Sep 16:52 2014
Picon

remote update of permissions+ACE

Hi,

How can I add ACE's to remote collections? I discovered that Ant doesn't store the files with the correct permissions.

Thanks.

--

W.S. Hager
Lagua Web Solutions
http://lagua.nl

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
W.S. Hager | 17 Sep 16:19 2014
Picon

sm:find-users-by-name returns nothing

Hi,

The function sm:find-users-by-name doesn't return anything in my recent build of the eXist develop branch.

Thanks.

--

W.S. Hager
Lagua Web Solutions
http://lagua.nl

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
Ivan Lagunov | 17 Sep 15:01 2014
Picon

How to test XQuery function with map argument

I'd like to test an eXist-db XQuery function that takes Map datatype argument. According to the eXist-db test framework guide:

XQuery annotation parameters need to be literal values, so only strings and numbers are allowed. XQSuite thus applies type conversion to every argument as well as to values used in assertions.

However, I could not find how to specify a Map datatype as a string. Here is an example code that I have:

declare %test:arg("input", "{p1}?id={id}") %test:arg("props", "id") %test:arg("props", "ABC") %test:assertEquals("{p1}?id=ABC") function properties:substitute($input as xs:string, $props as map (xs:string, xs:string)) as xs:string { let $keys := map:keys($props) let $tokens := $keys ! concat('\{', ., '\}') let $replacements := $keys ! $props(.) return functx:replace-multi($input, $tokens, $replacements) };

The test fails with the following error:

<testcase name="substitute" class="properties:substitute"> <error type="java:org.exist.xquery.XPathException" message="exerr:ERROR XPTY0004: The actual cardinality for parameter 2 does not match the cardinality declared in the function's signature: properties:substitute($input as xs:string, $props as map) xs:string. Expected cardinality: exactly one, got 3. [at line 7, column 5] In function: properties:substitute(xs:string, map) [7:5:/db/apps/ssg/modules/properties.xql] test:apply(function, item()*) [327:9:jar:file:/C:/Programs/eXist-db/exist.jar!/org/exist/xquery/lib/xqsuite/xqsuite.xql] test:apply(function, element(), item()*) [234:9:jar:file:/C:/Programs/eXist-db/exist.jar!/org/exist/xquery/lib/xqsuite/xqsuite.xql] test:call-test(function, element(), element()*) [135:32:jar:file:/C:/Programs/eXist-db/exist.jar!/org/exist/xquery/lib/xqsuite/xqsuite.xql]"/> </testcase>

Any ideas how to make it working?

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
Winona Salesky | 15 Sep 19:34 2014
Picon

Lucene ICUFoldingFilter

Hi All, 
I have been spending attempting to customize Lucene for our needs. It looks to me like the ICUFoldingFilter will be very useful for our searches, but I am having some trouble getting it to work. 

I am working with the development branch: version 2.2 build 2014915
I have used ./build.sh download-icu4j to include the icu4j library. I then tried dropping the lucene-analyzers-icu-4.4.0.jar onto EXIST-HOME/extensions/indexes/lucene/lib

I then created a custom analyzer (essentially by copying the code from the NoDiacriticsStandardAnalyzer) and switching in the ICUFoldingFilter in place of the  ASCIIFoldingFilter. 

However I get an error when trying to reindex with my new analyzer. It looks like perhaps the icu4j library is not being found? I do not know any java and this is my first foray into customizing the Lucene analyzers, so any help would be greatly appreciated. 

Thanks,
-Winona

Error kicked up:

org.exist.EXistException: com.ibm.icu.impl.ICUBinary.readHeaderAndDataVersion(Ljava/io/InputStream;[BLcom/ibm/icu/impl/ICUBinary$Authenticate;)Lcom/ibm/icu/util/VersionInfo;

at org.exist.storage.BrokerPool.initialize(BrokerPool.java:1073)

at org.exist.storage.BrokerPool.<init>(BrokerPool.java:729)

at org.exist.storage.BrokerPool.configure(BrokerPool.java:248)

at org.exist.storage.BrokerPool.configure(BrokerPool.java:224)

at org.exist.jetty.JettyStart.run(JettyStart.java:165)

at org.exist.jetty.JettyStart.main(JettyStart.java:73)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:601)

at org.exist.start.Main.invokeMain(Main.java:126)

at org.exist.start.Main.run(Main.java:448)

at org.exist.start.Main.main(Main.java:50)

Caused by: java.lang.NoSuchMethodError: com.ibm.icu.impl.ICUBinary.readHeaderAndDataVersion(Ljava/io/InputStream;[BLcom/ibm/icu/impl/ICUBinary$Authenticate;)Lcom/ibm/icu/util/VersionInfo;

at com.ibm.icu.impl.Normalizer2Impl.load(Normalizer2Impl.java:400)

at com.ibm.icu.impl.Norm2AllModes$1.createInstance(Norm2AllModes.java:334)

at com.ibm.icu.impl.Norm2AllModes$1.createInstance(Norm2AllModes.java:328)

at com.ibm.icu.impl.SoftCache.getInstance(SoftCache.java:55)

at com.ibm.icu.impl.Norm2AllModes.getInstance(Norm2AllModes.java:325)

at com.ibm.icu.text.Normalizer2.getInstance(Normalizer2.java:130)

at org.apache.lucene.analysis.icu.ICUFoldingFilter.<clinit>(ICUFoldingFilter.java:64)

at java.lang.Class.forName0(Native Method)

at java.lang.Class.forName(Class.java:188)

at org.exist.indexing.lucene.AnalyzerConfig.configureAnalyzer(AnalyzerConfig.java:151)

at org.exist.indexing.lucene.AnalyzerConfig.addAnalyzer(AnalyzerConfig.java:98)

at org.exist.indexing.lucene.LuceneConfig.parseConfig(LuceneConfig.java:240)

at org.exist.indexing.lucene.LuceneConfig.parseConfig(LuceneConfig.java:236)

at org.exist.indexing.lucene.LuceneConfig.<init>(LuceneConfig.java:55)

at org.exist.indexing.lucene.LuceneIndexWorker.configure(LuceneIndexWorker.java:140)

at org.exist.indexing.IndexController.configure(IndexController.java:88)

at org.exist.storage.IndexSpec.read(IndexSpec.java:117)

at org.exist.storage.IndexSpec.<init>(IndexSpec.java:75)

at org.exist.collections.CollectionConfiguration.read(CollectionConfiguration.java:151)

at org.exist.collections.CollectionConfigurationManager.loadConfiguration(CollectionConfigurationManager.java:286)

at org.exist.collections.CollectionConfigurationManager.loadAllConfigurations(CollectionConfigurationManager.java:260)

at org.exist.collections.CollectionConfigurationManager.loadAllConfigurations(CollectionConfigurationManager.java:268)

at org.exist.collections.CollectionConfigurationManager.loadAllConfigurations(CollectionConfigurationManager.java:268)

at org.exist.collections.CollectionConfigurationManager.loadAllConfigurations(CollectionConfigurationManager.java:268)

at org.exist.collections.CollectionConfigurationManager.loadAllConfigurations(CollectionConfigurationManager.java:252)

at org.exist.collections.CollectionConfigurationManager.<init>(CollectionConfigurationManager.java:85)

at org.exist.storage.BrokerPool.initCollectionConfigurationManager(BrokerPool.java:1380)

at org.exist.storage.BrokerPool.initialize(BrokerPool.java:946)
------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
W.S. Hager | 15 Sep 14:15 2014
Picon

java.io.IOException: Collection cannot be created.

Hi,

Since just now eXist won't start. I get this error:

/db/system/security/exist/accounts/removed

I tried to pull and build the most recent code, but to no avail. What to do?


--

W.S. Hager
Lagua Web Solutions
http://lagua.nl

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
Paterson, Duncan | 15 Sep 12:12 2014
Picon

maxClauseCount is set to 1024

Hello List, 

i m trying to run a task of about 350k inserts, and for the first time I’m seeing this warning.  

Is there a way to increase this (even only temporary) or will it be 350 x 1000 records are a time? <-- This works fine 
Can i sidestep this by using something other then update insert?
Would it help if i try to find conditionals in my functions that i can live without, since java docu tells me this is connected to the  max number of boolean values  in lucene?
Please save me from clicking run 350 x every 90s….

Java 7-r7, OS x 10.9.4, Exist 2.2 develop github branch

Thanks 
Duncan




------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
Loren Cahlander | 14 Sep 20:41 2014
Picon

[Presentation] Adding Dynamic Menus to eXist-db Templating Apps

Hello folks,

I have created another presentation and this one is on adding dynamic menus to an app in eXist-db utilizing the templating framework.

It is available here: http://youtu.be/ByHjvX8ULig

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
W.S. Hager | 12 Sep 16:43 2014
Picon

can't read environment variable

Hi,

I'm trying to read an environment variable using fn:environment-variable() in Linux, but the function doesn't return anything. How should I set it so that eXist can access it?

Thanks.
Wouter

--

W.S. Hager
Lagua Web Solutions
http://lagua.nl

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
filtered | 12 Sep 11:55 2014
Picon

Automatic deployment of exist-db 2.2

Hi there,

I raised a similar question some weeks ago related about using eXist-db in automatic deployments. The main goal is to download and install exist-db automatically and provision it depending on some environment parameters.

I automated the download and installation process so far with some Python script
using 'expect'. This allows me to configure the installation and data directory.
For configuring the ports I need to copy over the jetty.xml template over to the installation directory. For modifying the auto-generated conf.xml file I need to read the file and modify it using an XML parser on the Python level..lots of fragile code and various configuration options in various places....not very nice.

You might argue that the typical solution would be using a package mechanism like RPM or so.  Yes and no....in general: it should be possible to install multiple instances of eXist-db on a system in dedicated installation directories, dedicated data directories etc. We call this self-contained environments that we can build automatically - we are using a provisioning tool called zc.buildout in the Python world)...some insights how to ease and automate  the configuration of eXist-db in a better way)?

Andreas

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open

Gmane