Thanks Sergio
just to clarify - the error comes from a different app that also does
something similar - its just when I load Marmotta that app stops working
with this message (so it might be that app - but any impact Marmotta does
have on the environment ought to be known and explained - even if its
legitimate!
Marmotta seems to run fine. if I reload the app it still fails, and
marnotta still runs - maybe it is sensitive to the order tomcat starts them
in - but I dont know how to control this.
both are accessing postgres, but different databases using different JDBC
urls./
<Context>
<!-- Default set of monitored resources. If one of these changes, the
-->
<!-- web application will be reloaded.
-->
<WatchedResource>WEB-INF/web.xml</WatchedResource>
<WatchedResource>${catalina.base}/conf/web.xml</WatchedResource>
<!-- Uncomment this to disable session persistence across Tomcat
restarts -->
<!--
<Manager pathname="" />
-->
<Resource
name="jdbc/pidsvc"
auth="Container"
type="javax.sql.DataSource"
driverClassName="org.postgresql.Driver"
url="jdbc:postgresql://localhost:5432/pidsvc"
username="pidsvc-admin"
password=XXXXX
maxActive="-1"
minIdle="0"
maxIdle="10"
maxWait="10000"
minEvictableIdleTimeMillis="300000"
timeBetweenEvictionRunsMillis="300000"
numTestsPerEvictionRun="20"
poolPreparedStatements="true"
maxOpenPreparedStatements="100"
testOnBorrow="true"
accessToUnderlyingConnectionAllowed="true"
validationQuery="SELECT VERSION();"
/>
On Tue, 23 Feb 2016 at 01:48 Sergio Fernández <[email protected]> wrote:
> Hi Rob.
>
> On Mon, Feb 22, 2016 at 3:58 AM, Rob Atkinson <[email protected]>
> wrote:
>
> > Hi
> > this may not be a Marmotta issue at all - but maybe it is -
> >
> > I have another application deployed using a JNDI connection - defined in
> > TOMCAT/conf/Catalina/localhost/myapp.xml
> >
> > When I deploy marmotta - this application stops working - and throws an
> > exception:
> > *default context factory java.naming.factory.initial could not be
> > initialised*
> >
> > *Can anyone identify the problem and whether its a Marmotta issue at
> all?*
> >
>
> Marmotta uses its custom JNDI factory, see
>
> https://github.com/apache/marmotta/blob/develop/launchers/marmotta-webapp/src/main/webapp/WEB-INF/web.xml#L26
>
> So it might be the source of your issues, because the error log that you
> see looks to come from Marmotta:
>
> https://github.com/apache/marmotta/blob/develop/platform/marmotta-core/src/main/java/org/apache/marmotta/platform/core/jndi/MarmottaInitialContextFactoryBuilder.java#L48
>
> Which comes to say that Marmotta was not able to retrieve the system
> default context factory. So we should find a solution for environments like
> yours...
>
> Anybody around here with experience on JNDI at that level?
>
> --
> Sergio Fernández
> Partner Technology Manager
> Redlink GmbH
> m: +43 6602747925
> e: [email protected]
> w: http://redlink.co
>