How can I only get the local data

classic Classic list List threaded Threaded
8 messages Options
smile smile
Reply | Threaded
Open this post in threaded view
|

How can I only get the local data

This post has NOT been accepted by the mailing list yet.
CONTENTS DELETED
The author has deleted this message.
smilehong smilehong
Reply | Threaded
Open this post in threaded view
|

How can I only get the local data

Hi, all

  when I use the “select * from XX where XX” in ignite, how can I only get the local data ? because it obtain data on all nodes default. And I have configure the cache modes is partitioned mode.

 Thank you very much!

Denis Magda Denis Magda
Reply | Threaded
Open this post in threaded view
|

Re: How can I only get the local data

Hi,

Presently there is no a reliable way to execute a SQL query over local collocated data.
Even if you set Query.setLocal to "true" there is a chance that you will get incomplete result set if re-partitioning happened at some point of the query execution.

However, it's planned to support the feature that will execute a query on a specific machine if it's know that all the data is located there.
Igniters, have we already created a ticket for this feature?

--
Denis

On 2/29/2016 10:52 AM, smilehong(洪利平) wrote:

Hi, all

  when I use the “select * from XX where XX” in ignite, how can I only get the local data ? because it obtain data on all nodes default. And I have configure the cache modes is partitioned mode.

 Thank you very much!


smilehong smilehong
Reply | Threaded
Open this post in threaded view
|

答复: How can I only get the local data

In reply to this post by smile

Yes, You are right,  but I will use the “ignite.compute().broadcast()” method to get all data(for example, aggregate in server node),  so I want to know that  set Query.setLocal to "true" can solute this problem ( Get data only from local node) ?

Or, Is there another method to use “select * from XX where XX” to get the local data in partition cache method ?

 

发件人: Denis Magda [mailto:[hidden email]]
发送时间: 2016229 19:12
收件人: [hidden email]
主题: Re: How can I only get the local data(Internet mail)

 

Hi,

Presently there is no a reliable way to execute a SQL query over local collocated data.
Even if you set Query.setLocal to "true" there is a chance that you will get incomplete result set if re-partitioning happened at some point of the query execution.

However, it's planned to support the feature that will execute a query on a specific machine if it's know that all the data is located there.
Igniters, have we already created a ticket for this feature?

--
Denis

On 2/29/2016 10:52 AM, smilehong(洪利平) wrote:

Hi, all

  when I use the “select * from XX where XX” in ignite, how can I only get the local data ? because it obtain data on all nodes default. And I have configure the cache modes is partitioned mode.

 Thank you very much!

 

Denis Magda Denis Magda
Reply | Threaded
Open this post in threaded view
|

Re: 答复: How can I only get the local data

> but I will use the “ignite.compute().broadcast()” method to get all data(for example, aggregate in server node)

There is no sense to use compute.broadcast() and local query at all because SQL engine does this properly for you out of the box. So in such a case just execute query and all the nodes that store cache XX data will receive the request and return their portion of data.

> Or, Is there another method to use “select * from XX where XX” to get the local data in partition cache method ?

Give me an example of a real SQL you're executing.

--
Denis

On 2/29/2016 2:30 PM, smilehong(洪利平) wrote:

Yes, You are right,  but I will use the “ignite.compute().broadcast()” method to get all data(for example, aggregate in server node),  so I want to know that  set Query.setLocal to "true" can solute this problem ( Get data only from local node) ?

Or, Is there another method to use “select * from XX where XX” to get the local data in partition cache method ?

 

发件人: Denis Magda [[hidden email]]
发 送时间: 2016229 19:12
收件人: [hidden email]
主题: Re: How can I only get the local data(Internet mail)

 

Hi,

Presently there is no a reliable way to execute a SQL query over local collocated data.
Even if you set Query.setLocal to "true" there is a chance that you will get incomplete result set if re-partitioning happened at some point of the query execution.

However, it's planned to support the feature that will execute a query on a specific machine if it's know that all the data is located there.
Igniters, have we already created a ticket for this feature?

--
Denis

On 2/29/2016 10:52 AM, smilehong(洪利平) wrote:

Hi, all

  when I use the “select * from XX where XX” in ignite, how can I only get the local data ? because it obtain data on all nodes default. And I have configure the cache modes is partitioned mode.

 Thank you very much!

 


dsetrakyan dsetrakyan
Reply | Threaded
Open this post in threaded view
|

Re: How can I only get the local data

In reply to this post by Denis Magda
I think the answer is to use Query.setLocal(true) flag which will return correct results on the stable topology. The issue with changing topology is being addressed right now and should become part of the next release.

D.

On Mon, Feb 29, 2016 at 3:11 AM, Denis Magda <[hidden email]> wrote:
Hi,

Presently there is no a reliable way to execute a SQL query over local collocated data.
Even if you set Query.setLocal to "true" there is a chance that you will get incomplete result set if re-partitioning happened at some point of the query execution.

However, it's planned to support the feature that will execute a query on a specific machine if it's know that all the data is located there.
Igniters, have we already created a ticket for this feature?

--
Denis


On 2/29/2016 10:52 AM, smilehong(洪利平) wrote:

Hi, all

  when I use the “select * from XX where XX” in ignite, how can I only get the local data ? because it obtain data on all nodes default. And I have configure the cache modes is partitioned mode.

 Thank you very much!



smilehong smilehong
Reply | Threaded
Open this post in threaded view
|

答复: How can I only get the local data(Internet mail)

thank you, and you means that use Query.setLocal(true) can achieve this goal ?

 

发件人: Dmitriy Setrakyan [mailto:[hidden email]]
发送时间: 201631 5:30
收件人: user
主题: Re: How can I only get the local data(Internet mail)

 

I think the answer is to use Query.setLocal(true) flag which will return correct results on the stable topology. The issue with changing topology is being addressed right now and should become part of the next release.

 

D.

 

On Mon, Feb 29, 2016 at 3:11 AM, Denis Magda <[hidden email]> wrote:

Hi,

Presently there is no a reliable way to execute a SQL query over local collocated data.
Even if you set Query.setLocal to "true" there is a chance that you will get incomplete result set if re-partitioning happened at some point of the query execution.

However, it's planned to support the feature that will execute a query on a specific machine if it's know that all the data is located there.
Igniters, have we already created a ticket for this feature?

--
Denis

 

On 2/29/2016 10:52 AM, smilehong(洪利平) wrote:

Hi, all

  when I use the “select * from XX where XX” in ignite, how can I only get the local data ? because it obtain data on all nodes default. And I have configure the cache modes is partitioned mode.

 Thank you very much!

 

 

dsetrakyan dsetrakyan
Reply | Threaded
Open this post in threaded view
|

Re: 答复: How can I only get the local data(Internet mail)



On Mon, Feb 29, 2016 at 5:27 PM, smilehong(洪利平) <[hidden email]> wrote:

thank you, and you means that use Query.setLocal(true) can achieve this goal ?


As Denis suggested, using SQL directly is the best option, as the query will be broadcast within the cluster automatically.

If you need to execute a broadcast compute closure instead, then Query.setLocal(true) is the best option to do so, as it will execute only on the node that is executing the computation.
 

 

发件人: Dmitriy Setrakyan [mailto:[hidden email]]
发送时间: 201631 5:30
收件人: user
主题: Re: How can I only get the local data(Internet mail)

 

I think the answer is to use Query.setLocal(true) flag which will return correct results on the stable topology. The issue with changing topology is being addressed right now and should become part of the next release.

 

D.

 

On Mon, Feb 29, 2016 at 3:11 AM, Denis Magda <[hidden email]> wrote:

Hi,

Presently there is no a reliable way to execute a SQL query over local collocated data.
Even if you set Query.setLocal to "true" there is a chance that you will get incomplete result set if re-partitioning happened at some point of the query execution.

However, it's planned to support the feature that will execute a query on a specific machine if it's know that all the data is located there.
Igniters, have we already created a ticket for this feature?

--
Denis

 

On 2/29/2016 10:52 AM, smilehong(洪利平) wrote:

Hi, all

  when I use the “select * from XX where XX” in ignite, how can I only get the local data ? because it obtain data on all nodes default. And I have configure the cache modes is partitioned mode.

 Thank you very much!