ignite-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Cherkasov <michael.cherka...@gmail.com>
Subject Re: using JDBC with Ignite cluster, configured with persistent storage
Date Tue, 05 Dec 2017 10:29:49 GMT
Hi,

I can not understand from your email what was wrong, could you please
provide more details about your case?
Maybe you can send me a demo app that will show the exception you have?

Thanks,
Mike.


2017-12-05 1:45 GMT+03:00 soroka21 <soroka21@gmail.com>:

> Hi,
> I'm trying to use JDBC connection to run SQL on cluster, configured with
> Persistent storage.
> Persistent storage means what I have to make cluster active before I can do
> any DDL (or even request list of tables?)
> below is the output of sqlline, I'm trying to use, :
>
>
> 0: jdbc:ignite:thin://10.238.42.86/> !tables
> Error: Failed to handle JDBC request because node is stopping.
> (state=50000,code=0)
> java.sql.SQLException: Failed to handle JDBC request because node is
> stopping.
>         at
> org.apache.ignite.internal.jdbc.thin.JdbcThinConnection.sendRequest(
> JdbcThinConnection.java:671)
>         at
> org.apache.ignite.internal.jdbc.thin.JdbcThinDatabaseMetadata.getTables(
> JdbcThinDatabaseMetadata.java:740)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:
> 62)
>         at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(
> DelegatingMethodAccessorImpl.java:43)
>         at java.lang.reflect.Method.invoke(Method.java:497)
>         at sqlline.Reflector.invoke(Reflector.java:75)
>         at sqlline.Commands.metadata(Commands.java:194)
>         at sqlline.Commands.tables(Commands.java:332)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:
> 62)
>         at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(
> DelegatingMethodAccessorImpl.java:43)
>         at java.lang.reflect.Method.invoke(Method.java:497)
>         at
> sqlline.ReflectiveCommandHandler.execute(ReflectiveCommandHandler.java:38)
>         at sqlline.SqlLine.dispatch(SqlLine.java:791)
>         at sqlline.SqlLine.begin(SqlLine.java:668)
>         at sqlline.SqlLine.start(SqlLine.java:373)
>         at sqlline.SqlLine.main(SqlLine.java:265)
>
>
> 0: jdbc:ignite:thin://10.238.42.86/> CREATE TABLE table4(_id varchar,F00
> varchar,F01 bigint,F02 double,F03 timestamp,F04 varchar,F05 bigint,F06
> double,F07 timestamp,F08 varchar,F09 bigint, PRIMARY KEY(_id)) WITH
> "cache_name=table4, value_type=table4";
> Error: Failed to handle JDBC request because node is stopping.
> (state=50000,code=0)
> java.sql.SQLException: Failed to handle JDBC request because node is
> stopping.
>         at
> org.apache.ignite.internal.jdbc.thin.JdbcThinConnection.sendRequest(
> JdbcThinConnection.java:671)
>         at
> org.apache.ignite.internal.jdbc.thin.JdbcThinStatement.
> execute0(JdbcThinStatement.java:130)
>         at
> org.apache.ignite.internal.jdbc.thin.JdbcThinStatement.
> execute(JdbcThinStatement.java:299)
>         at sqlline.Commands.execute(Commands.java:823)
>         at sqlline.Commands.sql(Commands.java:733)
>         at sqlline.SqlLine.dispatch(SqlLine.java:795)
>         at sqlline.SqlLine.begin(SqlLine.java:668)
>         at sqlline.SqlLine.start(SqlLine.java:373)
>         at sqlline.SqlLine.main(SqlLine.java:265)
>
> Cluster configuration looks like this:
> <?xml version="1.0" encoding="UTF-8"?>
>
> <beans xmlns="http://www.springframework.org/schema/beans"
>        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>        xsi:schemaLocation="
>        http://www.springframework.org/schema/beans
>        http://www.springframework.org/schema/beans/spring-beans.xsd">
>
>     <bean id="grid.cfg"
> class="org.apache.ignite.configuration.IgniteConfiguration">
>         <property name="discoverySpi">
>             <bean
> class="org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi">
>                 <property name="ipFinder">
>                     <bean
> class="org.apache.ignite.spi.discovery.tcp.ipfinder.vm.
> TcpDiscoveryVmIpFinder">
>                         <property name="addresses">
>                             <list>
>                                 <value>xxx.xxx.xxx.xxx:47500..
> 47509</value>
>                                 <value>yyy.yyy.yyy.yyy:47500..
> 47509</value>
>                                 ....
>                             </list>
>                         </property>
>                     </bean>
>                 </property>
>             </bean>
>         </property>
>         <property name="dataStorageConfiguration">
>             <bean
> class="org.apache.ignite.configuration.DataStorageConfiguration">
>                 <property name="dataRegionConfigurations">
>                     <list>
>                         <bean
> class="org.apache.ignite.configuration.DataRegionConfiguration">
>
>                             <property name="name" value="500MB_Region"/>
>
>
>                             <property name="initialSize" value="#{100L *
> 1024 * 1024}"/>
>
>
>                             <property name="maxSize" value="#{500L * 1024 *
> 1024}"/>
>
>
>                             <property name="persistenceEnabled"
> value="true"/>
>                         </bean>
>                     </list>
>                 </property>
>             </bean>
>         </property>
>     </bean>
> </beans>
>
>
>
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>

Mime
View raw message