ignite.sh spring xml file secret.properties file not found error

classic Classic list List threaded Threaded
3 messages Options
Ganesh Kumar Ganesh Kumar
Reply | Threaded
Open this post in threaded view
|

ignite.sh spring xml file secret.properties file not found error

Hi,
I have specified secret.properties file location in the spring xml file and
when it start ignite.sh, I see the below error as its not able to find the
secret.properties file.
- Where does ignite.sh look for this file? & how do I specify the right path
for this file.

$bin/ignite.sh ganesh.xml
class org.apache.ignite.IgniteException: Failed to instantiate Spring XML
application context [springUrl=file:/opt/vdp/ignite/config/ganesh.xml,
err=Could not load properties; nested exception is
java.io.FileNotFoundException: class path resource [secret.properties]
cannot be opened because it does not exist]
        at
org.apache.ignite.internal.util.IgniteUtils.convertException(IgniteUtils.java:966)
        at org.apache.ignite.Ignition.start(Ignition.java:350)
        at
org.apache.ignite.startup.cmdline.CommandLineStartup.main(CommandLineStartup.java:302)
Caused by: class org.apache.ignite.IgniteCheckedException: Failed to
instantiate Spring XML application context
[springUrl=file:/opt/vdp/ignite/config/ganesh.xml, err=Could not load
properties; nested exception is java.io.FileNotFoundException: class path
resource [secret.properties] cannot be opened because it does not exist]




--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
vkulichenko vkulichenko
Reply | Threaded
Open this post in threaded view
|

Re: ignite.sh spring xml file secret.properties file not found error

Ganesh,

ignite.sh itself doesn't look for any properties files, it's your XML that
has a reference to one. Looks like currently it's looking for a classpath
resource. Make sure it's available there, or fix the path in the XML is
location should be different.

-Val



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
Ganesh Kumar Ganesh Kumar
Reply | Threaded
Open this post in threaded view
|

Re: ignite.sh spring xml file secret.properties file not found error

I have tried setting CLASSPATH
$ echo $CLASSPATH
/opt/vdp/ignite/config

and also providing the full path of secret.properties in my spring xml file.
Still I am getting the same error when I try to start the ignite instance.
**code snippet from the xml file :
   
    <bean id="placeholderConfig"
class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
        <property value="classpath:/opt/vdp/ignite/config/secret.properties"
name="location"/>
    </bean>


Error :
class org.apache.ignite.IgniteException: Failed to instantiate Spring XML
application context
[springUrl=file:/opt/vdp/apache-ignite-fabric-2.3.0-bin/config/ganesh.xml,
err=Could not load properties; nested exception is
java.io.FileNotFoundException: class path resource
[opt/vdp/ignite/config/secret.properties] cannot be opened because it does
not exist]
        at
org.apache.ignite.internal.util.IgniteUtils.convertException(IgniteUtils.java:966)

Any thoughts on how to solve this??

Thanks - Ganesh Kumar




--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/