Re: Can't write to Ignite cluster

2018-07-16 Thread Ray
Hello Pavel,

I have found out why the topology version keeps increasing.
It's because my colleague created a customized Ignite monitor system which
will fetches metrics from Ignite visor.
And this monitor system will launch a Visor client connects to the cluster
every minute, after fetching all the metrics from Visor it will shut down.
This behavior will cause the topology version increasing. (This is a bad
practice to do monitor)
This is also why you're seeing the NODE_JOINED log.

Now I've stooped this monitor system and restarted cluster.
This issue seems to be fixed.

But we need to think is launching a Visor client connects to the cluster
every minute will cause cluster freeze expected behavior?
As I observed launching a Visor client connects to the cluster is not a
simple operation, it usually takes more than 5 seconds to finish partition
exchange and other steps before Visor is connected. 

Thanks for your help, Pavel.



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


Re: Apache Flink Sink + Ignite: Ouch! Argument is invalid

2018-07-16 Thread Saikat Maitra
Hi Ray,

Thank you for validating the changes, I see that in cluster mode when I am
checking the IgniteSink it is working as desired. In stand alone mode I can
see we are getting the exception class org.apache.ignite.IgniteException:
Default Ignite instance has already been started.

Please take a look into this sample application
https://github.com/samaitra/streamers which I used to run it with flink in
cluster mode.

I am considering if I should make changes to run the IgniteSink in client
mode similar to the ways flink connector for redis and flume were
implemented in Apache Bahir

https://github.com/apache/bahir-flink

I will share update soon.

Regards,
Saikat



On Sun, Jul 15, 2018 at 10:07 PM, Ray  wrote:

> Hello Saikat,
>
> I tried your newest code and wrote a simple word count application to test
> the sink.
> It appears there's still problems.
> Here's my code.
>
>
>
> import org.apache.flink.api.scala._
> import org.apache.flink.streaming.api.scala.StreamExecutionEnvironment
> import org.apache.flink.streaming.api.scala.extensions._
> import org.apache.flink.configuration.Configuration
> import org.apache.ignite.Ignition
> import org.apache.ignite.configuration.CacheConfiguration
>
> import scala.collection.JavaConverters._
>
>
> object WordCount {
>
> def main(args: Array[String]) {
>
> val ignite = Ignition.start("ignite.xml")
> val cacheConfig = new CacheConfiguration[Any, Any]()
> ignite.destroyCache("aaa")
> cacheConfig.setName("aaa")
> cacheConfig.setSqlSchema("PUBLIC")
> ignite.createCache(cacheConfig)
> ignite.close()
>
>
> // set up the execution environment
> val env = StreamExecutionEnvironment.
> getExecutionEnvironment
>
> val igniteSink = new IgniteSink[java.util.Map[String,
> Int]]("aaa",
> "ignite.xml")
>
> igniteSink.setAllowOverwrite(false)
> igniteSink.setAutoFlushFrequency(1)
>
> igniteSink.open(new Configuration)
>
>
> // get input data
> val text = env.fromElements(
> "To be, or not to be,--that is the question:--",
> "Whether 'tis nobler in the mind to suffer",
> "The slings and arrows of outrageous fortune",
> "Or to take arms against a sea of troubles,")
>
>
> val counts = text
> // split up the lines in pairs (2-tuples)
> containing: (word,1)
> .flatMap(_.toLowerCase.split("\\W+"))
> .filter(_.nonEmpty)
> .map((_, 1))
> // group by the tuple field "0" and sum up tuple
> field "1"
> .keyBy(0)
> .sum(1)
> // Convert to key/value format before ingesting to
> Ignite
> .mapWith { case (k: String, v: Int) => Map(k ->
> v).asJava }
> .addSink(igniteSink)
>
> try
> env.execute("Streaming WordCount1")
> catch {
> case e: Exception =>
>
> // Exception handling.
> } finally igniteSink.close()
>
> }
> }
>
> I tried running this application in Idea and the error log snippet is as
> follows
>
> 07/16/2018 11:05:30 aggregation -> Map -> Sink: Unnamed(4/8) switched
> to
> FAILED
> class org.apache.ignite.IgniteException: Default Ignite instance has
> already
> been started.
> at
> org.apache.ignite.internal.util.IgniteUtils.convertException(IgniteUtils.
> java:990)
> at org.apache.ignite.Ignition.start(Ignition.java:355)
> at IgniteSink.open(IgniteSink.java:135)
> at
> org.apache.flink.api.common.functions.util.FunctionUtils.
> openFunction(FunctionUtils.java:36)
> at
> org.apache.flink.streaming.api.operators.AbstractUdfStreamOperator.open(
> AbstractUdfStreamOperator.java:111)
> at
> org.apache.flink.streaming.runtime.tasks.StreamTask.
> openAllOperators(StreamTask.java:376)
> at
> org.apache.flink.streaming.runtime.tasks.StreamTask.
> invoke(StreamTask.java:253)
> at org.apache.flink.runtime.taskmanager.Task.run(Task.java:702)
> at java.lang.Thread.run(Thread.java:745)
> Caused by: class org.apache.ignite.IgniteCheckedException: Default Ignite
> instance has already been started.
> at org.apache.ignite.internal.IgnitionEx.start0(IgnitionEx.
> java:1134)
> at
> org.apache.ignite.internal.IgnitionEx.startConfigurations(
> IgnitionEx.java:1069)
> at org.apache.ignite.internal.IgnitionEx.start(IgnitionEx.
> java:955)
> at org.apache.ignite.internal.IgnitionEx.start(IgnitionEx.
> java:854)
> at org.apache.ignite.internal.IgnitionEx.start(IgnitionEx.
> 

RE: Best practice for class versioning: marshaller error

2018-07-16 Thread Calvin KL Wong, CLSA
Got it, thanks for the info.

Thanks,
Calvin

-Original Message-
From: dkarachentsev [mailto:dkarachent...@gridgain.com] 
Sent: Monday, July 16, 2018 9:57 PM
To: user@ignite.apache.org
Subject: RE: Best practice for class versioning: marshaller error

Hi Calvin,

> Can I assume that BinaryMarshaller won't be used for any object embedded
> inside GridCacheQueryResponse? 

Yes, because Binary can fallback to Optimized, but not vice versa. 

> If I am correct, do you have any suggestion on how I can avoid this type
> of issue? 

Probably you need to avoid using incorrectly serialized objects, or
implement your own Externalizable, when you will do manual
serializing/deserializing of such fields.

Thanks!
-Dmitry



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
The content of this communication is intended for the recipient and is subject 
to CLSA Legal and Regulatory Notices.
These can be viewed at https://www.clsa.com/disclaimer.html or sent to you upon 
request.
Please consider before printing. CLSA is ISO14001 certified and committed to 
reducing its impact on the environment.



Re: Possible starvation in striped pool

2018-07-16 Thread Shailendrasinh Gohil
Please find attached thread dump as requested.

ServerThreadDump0716.txt

  



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


Re: Running Server Node in UNIX

2018-07-16 Thread Skollur
Thank you. I have all jars in lib as below and added to the cp command.

lib folder -
./lib/ignite-indexing-2.5.0.jar
./lib/ignite-rest-http-2.5.0.jar
./lib/mssql-jdbc-6.4.0.jre8.jar
./lib/ignite-slf4j-2.5.0.jar 
./ib/...jar

source code compiled as below structure(.class)
-com/cache/constant/*.class
-com/cache/domain/*.class
-com/cache/load/*.class
-com/cache/init/ServerNodeCodeStartup.class


Tried both below.
1)java -cp ./opt/lib/*.jar com/cache/init/ServerNodeCodeStartup and output
Error: Could not find or load main class
com.cache.init.ServerNodeCodeStartup

2)cd /com/cache/init/
Tried java -cp ./opt/lib/*.jar ServerNodeCodeStartup and output
Error: Could not find or load main class ServerNodeCodeStartup








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


Re: Running Server Node in UNIX

2018-07-16 Thread vkulichenko
You cannot include JARs into another JAR, Java is not going to add them to
classpath. You should list all required JARs in the '-cp' parameter, or
create an uber-JAR with all the dependencies unpacked there.

-Val



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


Re: Running Server Node in UNIX

2018-07-16 Thread Skollur
I don't have IGNITE_HOME set up from my windows- eclipse and able to run
without any issue. 
I have ignite-core, ignite-spring, ignite-indexing and ignite-rest-http in
the pom.xml.

I am trying to run same structure in UNIX. I have required libs in the jar.
Is anything am i missing?



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


Re: Running Server Node in UNIX

2018-07-16 Thread aealexsandrov
Hi,

Did you add to IGNITE_HOME to the path?

https://apacheignite.readme.io/docs/getting-started#section-with-default-configuration

In case if you are going to create maven project then you still need to
download the binaries and set the IGNITE_HOME:

https://ignite.apache.org/download.cgi

BR,
Andrei



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


Re: Tracing all SQL Queries

2018-07-16 Thread Вячеслав Коптилин
Hi,

Yes, it can be specified in your Spring configuration file as follows:



...


Thanks,
Slava.


пн, 16 июл. 2018 г. в 19:39, ApacheUser :

> Hi Slava,
> Sorry to get into this thread,I have similar problem to control long
> running
> SQLs. I want timeout SQLs running more than 500ms.
> I sthere any way to set etLongQueryWarningTimeout()  in CONFIG File?
>
> Appreciate your response.
>
> Thanks
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>


Re: Tracing all SQL Queries

2018-07-16 Thread ApacheUser
Hi Slava,
Sorry to get into this thread,I have similar problem to control long running
SQLs. I want timeout SQLs running more than 500ms.
I sthere any way to set etLongQueryWarningTimeout()  in CONFIG File?

Appreciate your response.

Thanks



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


Re: Port Assigned? Work on specific Node?

2018-07-16 Thread Ilya Kasnacheev
Hello!

I can address the immediate questions that you are having, but I'm afraid
that you will be only getting further away from optimal solution of your
case.

What is your case? Can you please tell us more about the scenario that you
are trying to implement?

Regards,

-- 
Ilya Kasnacheev

2018-07-16 18:26 GMT+03:00 monstereo :

> I have read the links that you have shared, but there is no information
> about
> different clusters
>
> I have found Ignite native persistence, can it be a solution for my case?
>
> And I have allow to create different cluster in my laptop?
>
> ilya.kasnacheev wrote
> > Hello!
> >
> > I think you could use ContinuousQuery
> > https://apacheignite.readme.io/docs/continuous-queries; (with
> > initial
> > query) to copy all data from cache in one cluster to cache in another
> > cluster.
> > It will also take care of the situation where cache on node1 is changed
> > while it is being copied.
> > If that is not a concern, a simple ScanQuery
> > https://apacheignite.readme.io/docs/cache-queries#scan-queries;
> > will do.
> >
> >
> > As for signalling client when it is appropriate to read cache from node2,
> > you could use CountDownLatch. Just always await() it in client, and on
> > server countDown() it once all data is copied.
> >
> > Regards,
> > Ilya.
> >
> > --
> > Ilya Kasnacheev
> >
> > 2018-07-16 16:42 GMT+03:00 monstereo 
>
> > mehmetozanguven@
>
> > :
> >
> >> OMG!!!
> >>
> >> Yep, If there are belonging to different cluster, there is  way to copy
> >> caches data? Especially I am looking for ignite features.
> >> Now one cluster has 1 datas
> >> I will copy these datas to another cluster
> >>
> >>
> >> Sorry man, I forget to write this.
> >>
> >>
> >>
> >>
> >>
> >> --
> >> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
> >>
>
>
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>


Re: Port Assigned? Work on specific Node?

2018-07-16 Thread monstereo
I have read the links that you have shared, but there is no information about
different clusters

I have found Ignite native persistence, can it be a solution for my case?

And I have allow to create different cluster in my laptop?

ilya.kasnacheev wrote
> Hello!
> 
> I think you could use ContinuousQuery
> https://apacheignite.readme.io/docs/continuous-queries; (with
> initial
> query) to copy all data from cache in one cluster to cache in another
> cluster.
> It will also take care of the situation where cache on node1 is changed
> while it is being copied.
> If that is not a concern, a simple ScanQuery
> https://apacheignite.readme.io/docs/cache-queries#scan-queries;
> will do.
> 
> 
> As for signalling client when it is appropriate to read cache from node2,
> you could use CountDownLatch. Just always await() it in client, and on
> server countDown() it once all data is copied.
> 
> Regards,
> Ilya.
> 
> -- 
> Ilya Kasnacheev
> 
> 2018-07-16 16:42 GMT+03:00 monstereo 

> mehmetozanguven@

> :
> 
>> OMG!!!
>>
>> Yep, If there are belonging to different cluster, there is  way to copy
>> caches data? Especially I am looking for ignite features.
>> Now one cluster has 1 datas
>> I will copy these datas to another cluster
>>
>>
>> Sorry man, I forget to write this.
>>
>>
>>
>>
>>
>> --
>> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>>





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


Re: Possible starvation in striped pool

2018-07-16 Thread Ilya Kasnacheev
Hello!

Can you please provide the thread dump of problematic cluster after removal
of close statements on caches?

Regards,

-- 
Ilya Kasnacheev

2018-07-16 17:21 GMT+03:00 Shailendrasinh Gohil <
shailendrasinh.go...@salientcrgt.com>:

> Thanks again for the response.
>
> We have tried removing the close statements but the result was same. And
> yes, other threads accessing cache from the same Dao.
>
> We also tried both the atomicityMode to see if any improvement. We also
> have
> write behind enabled for the large tables with frequent get and put
> operations.
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>


Re: Possible starvation in striped pool

2018-07-16 Thread Shailendrasinh Gohil
Thanks again for the response.

We have tried removing the close statements but the result was same. And
yes, other threads accessing cache from the same Dao.

We also tried both the atomicityMode to see if any improvement. We also have
write behind enabled for the large tables with frequent get and put
operations.



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


Re: Exception while running sql inside ignite transaction

2018-07-16 Thread dkarachentsev
Hi Akash,

First of all SQL is not transactional yet, this feature will be available
only since 2.7 [1]. Your exception might be caused if query was canceled or
node stopped.

[1] https://issues.apache.org/jira/browse/IGNITE-5934

Thanks!
-Dmitry



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


RE: Best practice for class versioning: marshaller error

2018-07-16 Thread dkarachentsev
Hi Calvin,

> Can I assume that BinaryMarshaller won't be used for any object embedded
> inside GridCacheQueryResponse? 

Yes, because Binary can fallback to Optimized, but not vice versa. 

> If I am correct, do you have any suggestion on how I can avoid this type
> of issue? 

Probably you need to avoid using incorrectly serialized objects, or
implement your own Externalizable, when you will do manual
serializing/deserializing of such fields.

Thanks!
-Dmitry



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


Re: Port Assigned? Work on specific Node?

2018-07-16 Thread Ilya Kasnacheev
Hello!

I think you could use ContinuousQuery
 (with initial
query) to copy all data from cache in one cluster to cache in another
cluster.
It will also take care of the situation where cache on node1 is changed
while it is being copied.
If that is not a concern, a simple ScanQuery
 will do.


As for signalling client when it is appropriate to read cache from node2,
you could use CountDownLatch. Just always await() it in client, and on
server countDown() it once all data is copied.

Regards,
Ilya.

-- 
Ilya Kasnacheev

2018-07-16 16:42 GMT+03:00 monstereo :

> OMG!!!
>
> Yep, If there are belonging to different cluster, there is  way to copy
> caches data? Especially I am looking for ignite features.
> Now one cluster has 1 datas
> I will copy these datas to another cluster
>
>
> Sorry man, I forget to write this.
>
>
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>


Re: Port Assigned? Work on specific Node?

2018-07-16 Thread monstereo
OMG!!!

Yep, If there are belonging to different cluster, there is  way to copy
caches data? Especially I am looking for ignite features.
Now one cluster has 1 datas
I will copy these datas to another cluster


Sorry man, I forget to write this.





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


Re: Port Assigned? Work on specific Node?

2018-07-16 Thread monstereo
thanks, but this is not the answer that I expected,
maybe this scenario can be more understandable:

1 cache is in node1,
okey, node2 is created and node2 has copy of the node1(and node2 will not be
ready until copy is done!!)
now in node2 there is cache which name is "myCache" and I iterates over
node1 cache and i am putting datas to "myCache"
when putting occuring, client node should not say myCache.get(9500), it
should wait or i say to client, cache is not ready.


Let's assume that client will always looks "myCache" not the node1 cache


ilya.kasnacheev wrote
> Hello!
> 
> I have a feeling that you are trying to perform a manual sunset:
> reimplement something which is a part of core functionality and always
> provided out of box.
> 
> * Apache Ignite will read values from primary node only unless
> "readFromBackup" property is set.
> * Anyway, Apache Ignite will not try to read values from partition on node
> where it's not completely rebalanced yet.
> * In general, Apache Ignite will make sure that you're getting relevant
> and
> fresh data from cache.
> 
> Regards,
> 
> -- 
> Ilya Kasnacheev
> 
> 2018-07-16 15:59 GMT+03:00 monstereo 

> mehmetozanguven@

> :
> 
>> thanks for your understanding,
>> Last question,
>> I want to use data rebalancing, because I have scenario like this:
>>
>> let's say node 1 has 1 datas in its caches. (Which cache mode is
>> REPLICATED)
>> Now I will invoke another node2, then node2 will copy of node1's cache
>> datas.
>> But when copying occuring, if any client node wants to get data from
>> cache
>> via node2, I should say "cache is not ready" or node2 should be
>> accessible
>> after it has all datas.
>>
>> I though that I can use data rebalancing, that's why i am interested in
>> events. But, a few minutes ago, I have noticed I can not get
>> CacheRebalanceEVENT, because of replicated mode. (I can catch other
>> events
>> for example EVT_CACHE_OBJECT_PUT.
>>
>> Now what can i do?
>>
>> here is the cache events in xml file
>>
>>
>> 
> >
>  static-field="org.apache.ignite.events.EventType.EVT_CACHE_OBJECT_PUT"/>
>> 
> >
>  static-field="org.apache.ignite.events.EventType.EVT_CACHE_OBJECT_READ"/>
>> 
> >
>  static-field="org.apache.ignite.events.EventType.EVT_
>> CACHE_OBJECT_REMOVED"/>
>> 
> >
>  static-field="org.apache.ignite.events.EventType.EVT_
>> CACHE_REBALANCE_STARTED"/>
>> 
> >
>  static-field="org.apache.ignite.events.EventType.EVT_
>> CACHE_REBALANCE_PART_LOADED"/>
>> 
> >
>  static-field="org.apache.ignite.events.EventType.EVT_
>> CACHE_REBALANCE_STOPPED"/>
>> 
> >
>  static-field="org.apache.ignite.events.EventType.EVT_
>> CACHE_REBALANCE_PART_UNLOADED"/>
>>
>>
>>
>> --
>> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>>





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


Re: Port Assigned? Work on specific Node?

2018-07-16 Thread Ilya Kasnacheev
Hello!

I have a feeling that you are trying to perform a manual sunset:
reimplement something which is a part of core functionality and always
provided out of box.

* Apache Ignite will read values from primary node only unless
"readFromBackup" property is set.
* Anyway, Apache Ignite will not try to read values from partition on node
where it's not completely rebalanced yet.
* In general, Apache Ignite will make sure that you're getting relevant and
fresh data from cache.

Regards,

-- 
Ilya Kasnacheev

2018-07-16 15:59 GMT+03:00 monstereo :

> thanks for your understanding,
> Last question,
> I want to use data rebalancing, because I have scenario like this:
>
> let's say node 1 has 1 datas in its caches. (Which cache mode is
> REPLICATED)
> Now I will invoke another node2, then node2 will copy of node1's cache
> datas.
> But when copying occuring, if any client node wants to get data from cache
> via node2, I should say "cache is not ready" or node2 should be accessible
> after it has all datas.
>
> I though that I can use data rebalancing, that's why i am interested in
> events. But, a few minutes ago, I have noticed I can not get
> CacheRebalanceEVENT, because of replicated mode. (I can catch other events
> for example EVT_CACHE_OBJECT_PUT.
>
> Now what can i do?
>
> here is the cache events in xml file
>
>
>  static-field="org.apache.ignite.events.EventType.EVT_CACHE_OBJECT_PUT"/>
>  static-field="org.apache.ignite.events.EventType.EVT_CACHE_OBJECT_READ"/>
>  static-field="org.apache.ignite.events.EventType.EVT_
> CACHE_OBJECT_REMOVED"/>
>  static-field="org.apache.ignite.events.EventType.EVT_
> CACHE_REBALANCE_STARTED"/>
>  static-field="org.apache.ignite.events.EventType.EVT_
> CACHE_REBALANCE_PART_LOADED"/>
>  static-field="org.apache.ignite.events.EventType.EVT_
> CACHE_REBALANCE_STOPPED"/>
>  static-field="org.apache.ignite.events.EventType.EVT_
> CACHE_REBALANCE_PART_UNLOADED"/>
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>


Re: Port Assigned? Work on specific Node?

2018-07-16 Thread monstereo
thanks for your understanding,
Last question,
I want to use data rebalancing, because I have scenario like this:

let's say node 1 has 1 datas in its caches. (Which cache mode is
REPLICATED)
Now I will invoke another node2, then node2 will copy of node1's cache
datas.
But when copying occuring, if any client node wants to get data from cache
via node2, I should say "cache is not ready" or node2 should be accessible
after it has all datas.

I though that I can use data rebalancing, that's why i am interested in
events. But, a few minutes ago, I have noticed I can not get
CacheRebalanceEVENT, because of replicated mode. (I can catch other events
for example EVT_CACHE_OBJECT_PUT.

Now what can i do?

here is the cache events in xml file












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


RE: Deployment of Ignite/Application upgrades to production in 100+ nodecluster

2018-07-16 Thread KR Kumar
Hi Stan - Thanks a lot for quick response on this. Yeah just checked gridgain
and looks likes exactly what I need. May be will explore this feature. Not
sure if they have a trial.

Thanx and Regards,
KR Kumar



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


Re: Port Assigned? Work on specific Node?

2018-07-16 Thread Ilya Kasnacheev
Hello!

It is stopped because it is created in try-with-resources block. It is
closed when try-block is exited.

The equivalent code is
 IgnitePredicate lsnr = new IgnitePredicate() {
public boolean apply(TaskEvent e) { ... }
}

Regards,

-- 
Ilya Kasnacheev

2018-07-16 14:59 GMT+03:00 monstereo :

> thanks,
> I am looking for some features about ignite for my case  and I am stuck
> with
> this code:
> Event Example Github Ignite
>  src/main/java/org/apache/ignite/examples/events/EventsExample.java>
>
> In this example works fine, but why ignite node is stopped even if started
> in main?
>
> And what is the equivalent of this code without using "->" this
>
>  IgnitePredicate lsnr = evt -> {
> System.out.println("Received task event [evt=" + evt.name() +
> ",
> taskName=" + evt.taskName() + ']');
>
> return true; // Return true to continue listening.
> };
>
> // Register event listener for all local task execution events.
> ignite.events().localListen(lsnr, EVTS_TASK_EXECUTION);
>
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>


Re: Port Assigned? Work on specific Node?

2018-07-16 Thread monstereo
thanks,
I am looking for some features about ignite for my case  and I am stuck with
this code:
Event Example Github Ignite

  

In this example works fine, but why ignite node is stopped even if started
in main?

And what is the equivalent of this code without using "->" this

 IgnitePredicate lsnr = evt -> {
System.out.println("Received task event [evt=" + evt.name() + ",
taskName=" + evt.taskName() + ']');

return true; // Return true to continue listening.
};

// Register event listener for all local task execution events.
ignite.events().localListen(lsnr, EVTS_TASK_EXECUTION);




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


RE: Deployment of Ignite/Application upgrades to production in 100+ nodecluster

2018-07-16 Thread Stanislav Lukyanov
The functionality you’re looking for is generally called Rolling Upgrade.
Ignite doesn’t support clusters with mixed versions out of the box.
There are third-party solutions on top of Ignite, such as GridGain, that do 
have that.

Thanks,
Stan

From: KR Kumar
Sent: 16 июля 2018 г. 12:44
To: user@ignite.apache.org
Subject: Deployment of Ignite/Application upgrades to production in 100+ 
nodecluster

Hi - I have a 100 node cluster that is going to production in next 3 months.
The problem I am trying to figure out is how do i handle version and
application upgrades i.e when I am deploying the nodes in a sequence, I will
reach a point where half of my nodes are in the old version and half in the
newer which could lead unpredictable application behavior. Are there any
ways/tricks that people have already figured out in this area that I should
be aware.  One solution I am thinking is to create cluster groups and deploy
them by one group at a time. Please share your thoughts??

Thanx and Regards,
KR Kumar




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



Re: Port Assigned? Work on specific Node?

2018-07-16 Thread Ilya Kasnacheev
Hello!

setClientMode(true) is thick client. IgniteJdbcThinDriver is an example of
thin client. Note that thin clients' functionality is limited compared to
thick client.

It is insufficient information about your use case to say which one suits
your needs.

Regards,

-- 
Ilya Kasnacheev

2018-07-16 14:01 GMT+03:00 monstereo :

> thanks,
> Q2) What is the difference between setClientMode(true) and thin client? I
> probably will embed the nodes(which is responsible for CRUD operation for
> users). Which one I should, thin client or client Node
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>


Re: Port Assigned? Work on specific Node?

2018-07-16 Thread monstereo
thanks,
Q2) What is the difference between setClientMode(true) and thin client? I
probably will embed the nodes(which is responsible for CRUD operation for
users). Which one I should, thin client or client Node



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


Re: Port Assigned? Work on specific Node?

2018-07-16 Thread Ilya Kasnacheev
Hello!

Q1) This is because you can have more than one client or server node per
host, that will make use of port range. Moreover, you only have to
discovery one node via broadcast, and it will reveal the information of all
other nodes it knows, along with addressed.

Q2) This is only possible with thin clients, such as JDBC or REST.
Otherwise, "thick" Ignite client node will communicate to both node2 and
node1.

Regards,

-- 
Ilya Kasnacheev

2018-07-16 9:09 GMT+03:00 monstereo :

> I have many question:
>
> - In local we have this line in config file:
>
> *bean
> class="org.apache.ignite.spi.discovery.tcp.ipfinder.multicast.
> TcpDiscoveryMulticastIpFinder"> name="addresses">127.0.0.1:47500..47509
> *
>
> If I understood properly, our node sends a broadcast to message to other
> nodes which have address 127.0.0.1 and port numbers range is 47500-47509,
> and those other nodes send their ip address to our nodes.
>
> *Q1) I have question about port number. Why port range is 47500-47509? We
> can determine specific port number to specific node?*
>
> *Q2) Let's say I have 2 nodes, node 1 is holding all cache data, and node 2
> is holding also all cache data (REPLICATED), then I am creating clientNode3
> (which will be client), and I want clientNode3 to operate (insert,delete
> ...) just on node2, and if there is an update on node2 caches, it will
> delegate to node1 to uptade.(therefore database underlying these nodes will
> be updated). Can I work on just one node?*
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>


Deployment of Ignite/Application upgrades to production in 100+ node cluster

2018-07-16 Thread KR Kumar
Hi - I have a 100 node cluster that is going to production in next 3 months.
The problem I am trying to figure out is how do i handle version and
application upgrades i.e when I am deploying the nodes in a sequence, I will
reach a point where half of my nodes are in the old version and half in the
newer which could lead unpredictable application behavior. Are there any
ways/tricks that people have already figured out in this area that I should
be aware.  One solution I am thinking is to create cluster groups and deploy
them by one group at a time. Please share your thoughts??

Thanx and Regards,
KR Kumar




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


Re: Can't write to Ignite cluster

2018-07-16 Thread Pavel Vinokurov
Ray,

As I see from following logs:
18/07/13 01:33:18 WARN cache.GridCachePartitionExchangeManager: >>>
GridDhtPartitionsExchangeFuture [topVer=AffinityTopologyVersion
[topVer=25309, minorTopVer=0], evt=NODE_JOINED, evtNode=TcpDiscoveryNode
[id=0caad476-3652-453f-8fc8-e8880c12eea9, addrs=[10.252.218.225,
127.0.0.1], sockAddrs=[/127.0.0.1:49501,
rpbt1ign003.webex.com/10.252.218.225:49501], discPort=49501, order=25309,
intOrder=12657, lastExchangeTime=1531445583607, loc=false,
ver=2.4.0#20180305-sha1:aa342270, isClient=false], done=false]

A new node from 10.252.218.225 was joined to the cluster with discovery
port  49501.
It means that port 49500 was busy and 49501 was chosen according
to TcpDiscoverySpi#locPortRange parameter. But this port isn't included in
TcpDiscoveryVmIpFinder#addresses.
Please check that you start only one node on host or/and configure
locPortRange and addresses parameters.

Thanks,
Pavel




2018-07-16 6:37 GMT+03:00 Ray :

> Hi Pavel,
>
> I started Ignite using this command.
> /usr/bin/java -Xmx128g -Xms128g -XX:+UseG1GC -XX:+PrintAdaptiveSizePolicy
> -XX:+ScavengeBeforeFullGC -XX:+DisableExplicitGC -XX:+AlwaysPreTouch
> -XX:+PrintGCDetails -XX:+PrintGCTimeStamps -XX:+PrintGCDateStamps
> -Xloggc:/spare/ignite/log/ignitegc-2018_07_14-02_38.log
> -DIGNITE_QUIET=true
> -DIGNITE_SUCCESS_FILE=/spare/ignite/work/ignite_success_
> c6a52b2c-db0d-4eb7-a0e6-64df5ec615c4
> -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=18999
> -Dcom.sun.management.jmxremote.authenticate=false
> -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=node1
> -DIGNITE_HOME=/opt/apache-ignite
> -DIGNITE_PROG_NAME=/opt/apache-ignite/bin/ignite.sh -cp
> /opt/apache-ignite/libs/*:/opt/apache-ignite/libs/ignite-
> indexing/*:/opt/apache-ignite/libs/ignite-log4j2/*:/opt/
> apache-ignite/libs/ignite-rest-http/*:/opt/apache-
> ignite/libs/ignite-spring/*:/opt/apache-ignite/libs/licenses/*
> org.apache.ignite.startup.cmdline.CommandLineStartup
> /opt/apache-ignite/config/persistent-config.xml
>
> And I use Spark dataframe API to ingest data into Ignite.
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>



-- 

Regards

Pavel Vinokurov


Re: Ignite AWS cluster setup

2018-07-16 Thread Pavel Vinokurov
Hi,

Could you please show the cluster configuration.

2018-07-13 17:56 GMT+03:00 Kia Rahmani :

> Hello all,
> I recently started using Ignite for benchmarking a research project on a
> local multi-node cluster. Now I need to deploy the cluster on
> geographically
> distributed nodes, but I am stuck at setting up the connection on EC2
> machines.
>
> I have closely followed the TCP-based discovery instructions with static
> IPs
> of EC2 nodes. The first node seems to be starting up perfectly fine, but
> when I launch the second node, even though it triggers a topology change in
> the first node, it is immediately bounced back to the single-node (initial)
> state (I'll attach a sample output of the node 1 at the end of the
> message).
> I have used S3 Based Discovery method as well, but the problem persists.
>
> I appreciate your time and sorry for asking a novice question
> Bests, Kia
>
> [14:28:07] Ignite node started OK (id=431973b5)
> [14:28:07] Topology snapshot [ver=1, servers=1, clients=0, CPUs=2,
> offheap=0.77GB, heap=1.0GB]
> [14:28:07]   ^-- Node [...]
> [14:28:07] Data Regions Configured:
> [14:28:07]   ...
> [14:29:40] Topology snapshot [ver=2, servers=2, clients=0, CPUs=4,
> offheap=1.5GB, heap=2.0GB]
> [14:29:40]   ^-- Node [...]
> [14:29:40] Data Regions Configured:
> [14:29:40]   ...
> [14:29:40] Topology snapshot [ver=3, servers=1, clients=0, CPUs=2,
> offheap=0.77GB, heap=1.0GB]
> [14:29:40]  ...
>
>
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>



-- 

Regards

Pavel Vinokurov


Port Assigned? Work on specific Node?

2018-07-16 Thread monstereo
I have many question:

- In local we have this line in config file: 

*bean
class="org.apache.ignite.spi.discovery.tcp.ipfinder.multicast.TcpDiscoveryMulticastIpFinder">127.0.0.1:47500..47509*

If I understood properly, our node sends a broadcast to message to other
nodes which have address 127.0.0.1 and port numbers range is 47500-47509,
and those other nodes send their ip address to our nodes.

*Q1) I have question about port number. Why port range is 47500-47509? We
can determine specific port number to specific node?*

*Q2) Let's say I have 2 nodes, node 1 is holding all cache data, and node 2
is holding also all cache data (REPLICATED), then I am creating clientNode3
(which will be client), and I want clientNode3 to operate (insert,delete
...) just on node2, and if there is an update on node2 caches, it will
delegate to node1 to uptade.(therefore database underlying these nodes will
be updated). Can I work on just one node?*



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