Re: [DISCUSSION] API to KILL any user started computation

2020-01-17 Thread Николай Ижиков
Hello, Andrey.

Thanks for positive feedback.
Appreciate it.

> we can't cancel service or service's method

I understand it. 
Seems, we have several obvious options here:

* Try to do it and if fail answer to the user: «I’ve tried and fail. Sorry»
* Kill hanging thread.

> This invocations not register anywhere and can't be tracked and killed.

Yes.
So we should invent tracking for those invocation to be able to kill it :)


> 17 янв. 2020 г., в 21:03, Andrey Gura  написал(а):
> 
> It would be grate.
> 
> Only one comment: we can't cancel service or service's method
> execution because service grid API doesn't imply any requirement to
> service implementation. So if user do something like infinite cycle or
> blocking but non-interruptible operation it's impossible to interrupt
> it. Also service method invocation itself isn't cluster wide or local
> node specific operation. This invocations not register anywhere and
> can't be tracked and killed.
> 
> Unfortunately, the same is valid for some jobs in sense of infinite or
> non-interruptible operations.
> 
> On Wed, Jan 15, 2020 at 9:30 PM Николай Ижиков  wrote:
>> 
>> Hello, Igniters.
>> 
>> As you may know, we put a lot of effort to improve Ignite metric and 
>> diagnostic API.
>> We have created the following API:
>>* Metric manager
>>* System view manager
>> As far as I know, we would have tracing capabilities soon.
>> 
>> I think it's time to take the next step.
>> We should provide to the administrator the API to cancel(stop, kill) 
>> arbitrary user started computation.
>> 
>> Right now we have API to do it for:
>>* transactions `TransactionsMXBean#getActiveTransactions`.
>>* SQL queries: `KILL QUERY` sql command and visor task - 
>> `VisorQueryCancelTask`
>> 
>> Please, note, these features are implemented via different API.
>> 
>> I think we should introduce uniform Cancel API for the following 
>> computations:
>> 
>>* service.
>>* specific service method execution.
>>* compute job(compute task).
>>* query(scan, continuous, text).
>> 
>> We should  also rework kill transaction and kill SQL queries API to make 
>> them similar to each other.
>> I have plans to write an IEP for it and implement it.
>> What do you think?
>> 



Re: [DISCUSSION] API to KILL any user started computation

2020-01-17 Thread Andrey Gura
It would be grate.

Only one comment: we can't cancel service or service's method
execution because service grid API doesn't imply any requirement to
service implementation. So if user do something like infinite cycle or
blocking but non-interruptible operation it's impossible to interrupt
it. Also service method invocation itself isn't cluster wide or local
node specific operation. This invocations not register anywhere and
can't be tracked and killed.

Unfortunately, the same is valid for some jobs in sense of infinite or
non-interruptible operations.

On Wed, Jan 15, 2020 at 9:30 PM Николай Ижиков  wrote:
>
> Hello, Igniters.
>
> As you may know, we put a lot of effort to improve Ignite metric and 
> diagnostic API.
> We have created the following API:
> * Metric manager
> * System view manager
> As far as I know, we would have tracing capabilities soon.
>
> I think it's time to take the next step.
> We should provide to the administrator the API to cancel(stop, kill) 
> arbitrary user started computation.
>
> Right now we have API to do it for:
> * transactions `TransactionsMXBean#getActiveTransactions`.
> * SQL queries: `KILL QUERY` sql command and visor task - 
> `VisorQueryCancelTask`
>
> Please, note, these features are implemented via different API.
>
> I think we should introduce uniform Cancel API for the following computations:
>
> * service.
> * specific service method execution.
> * compute job(compute task).
> * query(scan, continuous, text).
>
> We should  also rework kill transaction and kill SQL queries API to make them 
> similar to each other.
> I have plans to write an IEP for it and implement it.
> What do you think?
>


Re: [DISCUSSION] API to KILL any user started computation

2020-01-17 Thread Вячеслав Коптилин
Hi Alexei,

> Not sure I've understand a question. JMX supports security via password
protection and secure channel.
That is the obvious thing I missed! :) Thank you!

Thanks,
S.

пт, 17 янв. 2020 г. в 14:45, Alexei Scherbakov :

> Slava,
>
> Not sure I've understand a question. JMX supports security via password
> protection and secure channel.
>
> пт, 17 янв. 2020 г. в 14:30, Вячеслав Коптилин :
>
> > Hello Nikolay,
> >
> > I'm not sure we need JMX API for this case. If I’m not mistaken, it’s
> about
> > the administrator’s ability to cancel any task/query in the cluster, and
> in
> > my opinion, such action must require administrator permission.
> > Could you please clarify how it can be done via JMX? I mean permission
> > check and etc. Perhaps, I'm missing something obvious...
> >
> > Thanks,
> > S.
> >
> > чт, 16 янв. 2020 г. в 15:46, Николай Ижиков :
> >
> > > Alexey.
> > >
> > > I think, yes.
> > > We certainly should be able to use system view data for the new KILL
> API.
> > >
> > > I think we should support both SQL and Java(JMX) API for this KILL
> > command.
> > >
> > >
> > > > 16 янв. 2020 г., в 15:28, Alexei Scherbakov <
> > > alexey.scherbak...@gmail.com> написал(а):
> > > >
> > > > Nikolaj,
> > > >
> > > > Can we use system views instead of implementing something new ?
> > > >
> > > > Each user operation has an unique ID.
> > > >
> > > > It's possible to introduce universal SQL kill something like:
> > > >
> > > > kill transaction ID
> > > >
> > > > where id is taken from system view.
> > > >
> > > >
> > > > чт, 16 янв. 2020 г. в 14:19, Николай Ижиков :
> > > >
> > > >> Hello, Alexey.
> > > >>
> > > >> I’m talking about *administrator* API.
> > > >>
> > > >> For example, the User has a cluster that is used by several
> > > applications.
> > > >> Some application starts buggy compute tasks that consume all CPU
> > > resources.
> > > >> Right now, administrator doesn’t have the ability to kill this task.
> > > >>
> > > >> This can lead to instability of the whole cluster.
> > > >>
> > > >>
> > > >>> 16 янв. 2020 г., в 13:42, Alexei Scherbakov <
> > > >> alexey.scherbak...@gmail.com> написал(а):
> > > >>>
> > > >>> Transactions can be also rolled back using tx.close where close is
> > > >>> java.lang.AutoCloseable#close
> > > >>> It looks for me to the definition of uniform cancel API.
> > > >>>
> > > >>>
> > > >>>
> > > >>> чт, 16 янв. 2020 г. в 13:37, Alexei Scherbakov <
> > > >> alexey.scherbak...@gmail.com
> > >  :
> > > >>>
> > >  Nikolaj,
> > > 
> > >  We already have cancellation possibilities for almost every user
> > >  computation.
> > >  Transactions are cancelled using tx.rollback()
> > >  Queries are cancelled using query.close()
> > >  Task is cancellable through ComputeTaskSession
> > > 
> > >  What is uniform cancel API ? Why do we need it ?
> > > 
> > > 
> > > 
> > >  ср, 15 янв. 2020 г. в 21:30, Николай Ижиков  >:
> > > 
> > > > Hello, Igniters.
> > > >
> > > > As you may know, we put a lot of effort to improve Ignite metric
> > and
> > > > diagnostic API.
> > > > We have created the following API:
> > > >   * Metric manager
> > > >   * System view manager
> > > > As far as I know, we would have tracing capabilities soon.
> > > >
> > > > I think it's time to take the next step.
> > > > We should provide to the administrator the API to cancel(stop,
> > kill)
> > > > arbitrary user started computation.
> > > >
> > > > Right now we have API to do it for:
> > > >   * transactions `TransactionsMXBean#getActiveTransactions`.
> > > >   * SQL queries: `KILL QUERY` sql command and visor task -
> > > > `VisorQueryCancelTask`
> > > >
> > > > Please, note, these features are implemented via different API.
> > > >
> > > > I think we should introduce uniform Cancel API for the following
> > > > computations:
> > > >
> > > >   * service.
> > > >   * specific service method execution.
> > > >   * compute job(compute task).
> > > >   * query(scan, continuous, text).
> > > >
> > > > We should  also rework kill transaction and kill SQL queries API
> to
> > > >> make
> > > > them similar to each other.
> > > > I have plans to write an IEP for it and implement it.
> > > > What do you think?
> > > >
> > > >
> > > 
> > >  --
> > > 
> > >  Best regards,
> > >  Alexei Scherbakov
> > > 
> > > >>>
> > > >>>
> > > >>> --
> > > >>>
> > > >>> Best regards,
> > > >>> Alexei Scherbakov
> > > >>
> > > >>
> > > >
> > > > --
> > > >
> > > > Best regards,
> > > > Alexei Scherbakov
> > >
> > >
> >
>
>
> --
>
> Best regards,
> Alexei Scherbakov
>


Re: [DISCUSSION] API to KILL any user started computation

2020-01-17 Thread Alexei Scherbakov
Slava,

Not sure I've understand a question. JMX supports security via password
protection and secure channel.

пт, 17 янв. 2020 г. в 14:30, Вячеслав Коптилин :

> Hello Nikolay,
>
> I'm not sure we need JMX API for this case. If I’m not mistaken, it’s about
> the administrator’s ability to cancel any task/query in the cluster, and in
> my opinion, such action must require administrator permission.
> Could you please clarify how it can be done via JMX? I mean permission
> check and etc. Perhaps, I'm missing something obvious...
>
> Thanks,
> S.
>
> чт, 16 янв. 2020 г. в 15:46, Николай Ижиков :
>
> > Alexey.
> >
> > I think, yes.
> > We certainly should be able to use system view data for the new KILL API.
> >
> > I think we should support both SQL and Java(JMX) API for this KILL
> command.
> >
> >
> > > 16 янв. 2020 г., в 15:28, Alexei Scherbakov <
> > alexey.scherbak...@gmail.com> написал(а):
> > >
> > > Nikolaj,
> > >
> > > Can we use system views instead of implementing something new ?
> > >
> > > Each user operation has an unique ID.
> > >
> > > It's possible to introduce universal SQL kill something like:
> > >
> > > kill transaction ID
> > >
> > > where id is taken from system view.
> > >
> > >
> > > чт, 16 янв. 2020 г. в 14:19, Николай Ижиков :
> > >
> > >> Hello, Alexey.
> > >>
> > >> I’m talking about *administrator* API.
> > >>
> > >> For example, the User has a cluster that is used by several
> > applications.
> > >> Some application starts buggy compute tasks that consume all CPU
> > resources.
> > >> Right now, administrator doesn’t have the ability to kill this task.
> > >>
> > >> This can lead to instability of the whole cluster.
> > >>
> > >>
> > >>> 16 янв. 2020 г., в 13:42, Alexei Scherbakov <
> > >> alexey.scherbak...@gmail.com> написал(а):
> > >>>
> > >>> Transactions can be also rolled back using tx.close where close is
> > >>> java.lang.AutoCloseable#close
> > >>> It looks for me to the definition of uniform cancel API.
> > >>>
> > >>>
> > >>>
> > >>> чт, 16 янв. 2020 г. в 13:37, Alexei Scherbakov <
> > >> alexey.scherbak...@gmail.com
> >  :
> > >>>
> >  Nikolaj,
> > 
> >  We already have cancellation possibilities for almost every user
> >  computation.
> >  Transactions are cancelled using tx.rollback()
> >  Queries are cancelled using query.close()
> >  Task is cancellable through ComputeTaskSession
> > 
> >  What is uniform cancel API ? Why do we need it ?
> > 
> > 
> > 
> >  ср, 15 янв. 2020 г. в 21:30, Николай Ижиков :
> > 
> > > Hello, Igniters.
> > >
> > > As you may know, we put a lot of effort to improve Ignite metric
> and
> > > diagnostic API.
> > > We have created the following API:
> > >   * Metric manager
> > >   * System view manager
> > > As far as I know, we would have tracing capabilities soon.
> > >
> > > I think it's time to take the next step.
> > > We should provide to the administrator the API to cancel(stop,
> kill)
> > > arbitrary user started computation.
> > >
> > > Right now we have API to do it for:
> > >   * transactions `TransactionsMXBean#getActiveTransactions`.
> > >   * SQL queries: `KILL QUERY` sql command and visor task -
> > > `VisorQueryCancelTask`
> > >
> > > Please, note, these features are implemented via different API.
> > >
> > > I think we should introduce uniform Cancel API for the following
> > > computations:
> > >
> > >   * service.
> > >   * specific service method execution.
> > >   * compute job(compute task).
> > >   * query(scan, continuous, text).
> > >
> > > We should  also rework kill transaction and kill SQL queries API to
> > >> make
> > > them similar to each other.
> > > I have plans to write an IEP for it and implement it.
> > > What do you think?
> > >
> > >
> > 
> >  --
> > 
> >  Best regards,
> >  Alexei Scherbakov
> > 
> > >>>
> > >>>
> > >>> --
> > >>>
> > >>> Best regards,
> > >>> Alexei Scherbakov
> > >>
> > >>
> > >
> > > --
> > >
> > > Best regards,
> > > Alexei Scherbakov
> >
> >
>


-- 

Best regards,
Alexei Scherbakov


Re: [DISCUSSION] API to KILL any user started computation

2020-01-17 Thread Вячеслав Коптилин
Hello Nikolay,

I'm not sure we need JMX API for this case. If I’m not mistaken, it’s about
the administrator’s ability to cancel any task/query in the cluster, and in
my opinion, such action must require administrator permission.
Could you please clarify how it can be done via JMX? I mean permission
check and etc. Perhaps, I'm missing something obvious...

Thanks,
S.

чт, 16 янв. 2020 г. в 15:46, Николай Ижиков :

> Alexey.
>
> I think, yes.
> We certainly should be able to use system view data for the new KILL API.
>
> I think we should support both SQL and Java(JMX) API for this KILL command.
>
>
> > 16 янв. 2020 г., в 15:28, Alexei Scherbakov <
> alexey.scherbak...@gmail.com> написал(а):
> >
> > Nikolaj,
> >
> > Can we use system views instead of implementing something new ?
> >
> > Each user operation has an unique ID.
> >
> > It's possible to introduce universal SQL kill something like:
> >
> > kill transaction ID
> >
> > where id is taken from system view.
> >
> >
> > чт, 16 янв. 2020 г. в 14:19, Николай Ижиков :
> >
> >> Hello, Alexey.
> >>
> >> I’m talking about *administrator* API.
> >>
> >> For example, the User has a cluster that is used by several
> applications.
> >> Some application starts buggy compute tasks that consume all CPU
> resources.
> >> Right now, administrator doesn’t have the ability to kill this task.
> >>
> >> This can lead to instability of the whole cluster.
> >>
> >>
> >>> 16 янв. 2020 г., в 13:42, Alexei Scherbakov <
> >> alexey.scherbak...@gmail.com> написал(а):
> >>>
> >>> Transactions can be also rolled back using tx.close where close is
> >>> java.lang.AutoCloseable#close
> >>> It looks for me to the definition of uniform cancel API.
> >>>
> >>>
> >>>
> >>> чт, 16 янв. 2020 г. в 13:37, Alexei Scherbakov <
> >> alexey.scherbak...@gmail.com
>  :
> >>>
>  Nikolaj,
> 
>  We already have cancellation possibilities for almost every user
>  computation.
>  Transactions are cancelled using tx.rollback()
>  Queries are cancelled using query.close()
>  Task is cancellable through ComputeTaskSession
> 
>  What is uniform cancel API ? Why do we need it ?
> 
> 
> 
>  ср, 15 янв. 2020 г. в 21:30, Николай Ижиков :
> 
> > Hello, Igniters.
> >
> > As you may know, we put a lot of effort to improve Ignite metric and
> > diagnostic API.
> > We have created the following API:
> >   * Metric manager
> >   * System view manager
> > As far as I know, we would have tracing capabilities soon.
> >
> > I think it's time to take the next step.
> > We should provide to the administrator the API to cancel(stop, kill)
> > arbitrary user started computation.
> >
> > Right now we have API to do it for:
> >   * transactions `TransactionsMXBean#getActiveTransactions`.
> >   * SQL queries: `KILL QUERY` sql command and visor task -
> > `VisorQueryCancelTask`
> >
> > Please, note, these features are implemented via different API.
> >
> > I think we should introduce uniform Cancel API for the following
> > computations:
> >
> >   * service.
> >   * specific service method execution.
> >   * compute job(compute task).
> >   * query(scan, continuous, text).
> >
> > We should  also rework kill transaction and kill SQL queries API to
> >> make
> > them similar to each other.
> > I have plans to write an IEP for it and implement it.
> > What do you think?
> >
> >
> 
>  --
> 
>  Best regards,
>  Alexei Scherbakov
> 
> >>>
> >>>
> >>> --
> >>>
> >>> Best regards,
> >>> Alexei Scherbakov
> >>
> >>
> >
> > --
> >
> > Best regards,
> > Alexei Scherbakov
>
>


Re: [DISCUSSION] API to KILL any user started computation

2020-01-16 Thread Alexei Scherbakov
Sounds good.

JMX API should be very similar: accept operation type and ID.

чт, 16 янв. 2020 г. в 15:46, Николай Ижиков :

> Alexey.
>
> I think, yes.
> We certainly should be able to use system view data for the new KILL API.
>
> I think we should support both SQL and Java(JMX) API for this KILL command.
>
>
> > 16 янв. 2020 г., в 15:28, Alexei Scherbakov <
> alexey.scherbak...@gmail.com> написал(а):
> >
> > Nikolaj,
> >
> > Can we use system views instead of implementing something new ?
> >
> > Each user operation has an unique ID.
> >
> > It's possible to introduce universal SQL kill something like:
> >
> > kill transaction ID
> >
> > where id is taken from system view.
> >
> >
> > чт, 16 янв. 2020 г. в 14:19, Николай Ижиков :
> >
> >> Hello, Alexey.
> >>
> >> I’m talking about *administrator* API.
> >>
> >> For example, the User has a cluster that is used by several
> applications.
> >> Some application starts buggy compute tasks that consume all CPU
> resources.
> >> Right now, administrator doesn’t have the ability to kill this task.
> >>
> >> This can lead to instability of the whole cluster.
> >>
> >>
> >>> 16 янв. 2020 г., в 13:42, Alexei Scherbakov <
> >> alexey.scherbak...@gmail.com> написал(а):
> >>>
> >>> Transactions can be also rolled back using tx.close where close is
> >>> java.lang.AutoCloseable#close
> >>> It looks for me to the definition of uniform cancel API.
> >>>
> >>>
> >>>
> >>> чт, 16 янв. 2020 г. в 13:37, Alexei Scherbakov <
> >> alexey.scherbak...@gmail.com
>  :
> >>>
>  Nikolaj,
> 
>  We already have cancellation possibilities for almost every user
>  computation.
>  Transactions are cancelled using tx.rollback()
>  Queries are cancelled using query.close()
>  Task is cancellable through ComputeTaskSession
> 
>  What is uniform cancel API ? Why do we need it ?
> 
> 
> 
>  ср, 15 янв. 2020 г. в 21:30, Николай Ижиков :
> 
> > Hello, Igniters.
> >
> > As you may know, we put a lot of effort to improve Ignite metric and
> > diagnostic API.
> > We have created the following API:
> >   * Metric manager
> >   * System view manager
> > As far as I know, we would have tracing capabilities soon.
> >
> > I think it's time to take the next step.
> > We should provide to the administrator the API to cancel(stop, kill)
> > arbitrary user started computation.
> >
> > Right now we have API to do it for:
> >   * transactions `TransactionsMXBean#getActiveTransactions`.
> >   * SQL queries: `KILL QUERY` sql command and visor task -
> > `VisorQueryCancelTask`
> >
> > Please, note, these features are implemented via different API.
> >
> > I think we should introduce uniform Cancel API for the following
> > computations:
> >
> >   * service.
> >   * specific service method execution.
> >   * compute job(compute task).
> >   * query(scan, continuous, text).
> >
> > We should  also rework kill transaction and kill SQL queries API to
> >> make
> > them similar to each other.
> > I have plans to write an IEP for it and implement it.
> > What do you think?
> >
> >
> 
>  --
> 
>  Best regards,
>  Alexei Scherbakov
> 
> >>>
> >>>
> >>> --
> >>>
> >>> Best regards,
> >>> Alexei Scherbakov
> >>
> >>
> >
> > --
> >
> > Best regards,
> > Alexei Scherbakov
>
>

-- 

Best regards,
Alexei Scherbakov


Re: [DISCUSSION] API to KILL any user started computation

2020-01-16 Thread Николай Ижиков
Alexey.

I think, yes.
We certainly should be able to use system view data for the new KILL API.

I think we should support both SQL and Java(JMX) API for this KILL command.


> 16 янв. 2020 г., в 15:28, Alexei Scherbakov  
> написал(а):
> 
> Nikolaj,
> 
> Can we use system views instead of implementing something new ?
> 
> Each user operation has an unique ID.
> 
> It's possible to introduce universal SQL kill something like:
> 
> kill transaction ID
> 
> where id is taken from system view.
> 
> 
> чт, 16 янв. 2020 г. в 14:19, Николай Ижиков :
> 
>> Hello, Alexey.
>> 
>> I’m talking about *administrator* API.
>> 
>> For example, the User has a cluster that is used by several applications.
>> Some application starts buggy compute tasks that consume all CPU resources.
>> Right now, administrator doesn’t have the ability to kill this task.
>> 
>> This can lead to instability of the whole cluster.
>> 
>> 
>>> 16 янв. 2020 г., в 13:42, Alexei Scherbakov <
>> alexey.scherbak...@gmail.com> написал(а):
>>> 
>>> Transactions can be also rolled back using tx.close where close is
>>> java.lang.AutoCloseable#close
>>> It looks for me to the definition of uniform cancel API.
>>> 
>>> 
>>> 
>>> чт, 16 янв. 2020 г. в 13:37, Alexei Scherbakov <
>> alexey.scherbak...@gmail.com
 :
>>> 
 Nikolaj,
 
 We already have cancellation possibilities for almost every user
 computation.
 Transactions are cancelled using tx.rollback()
 Queries are cancelled using query.close()
 Task is cancellable through ComputeTaskSession
 
 What is uniform cancel API ? Why do we need it ?
 
 
 
 ср, 15 янв. 2020 г. в 21:30, Николай Ижиков :
 
> Hello, Igniters.
> 
> As you may know, we put a lot of effort to improve Ignite metric and
> diagnostic API.
> We have created the following API:
>   * Metric manager
>   * System view manager
> As far as I know, we would have tracing capabilities soon.
> 
> I think it's time to take the next step.
> We should provide to the administrator the API to cancel(stop, kill)
> arbitrary user started computation.
> 
> Right now we have API to do it for:
>   * transactions `TransactionsMXBean#getActiveTransactions`.
>   * SQL queries: `KILL QUERY` sql command and visor task -
> `VisorQueryCancelTask`
> 
> Please, note, these features are implemented via different API.
> 
> I think we should introduce uniform Cancel API for the following
> computations:
> 
>   * service.
>   * specific service method execution.
>   * compute job(compute task).
>   * query(scan, continuous, text).
> 
> We should  also rework kill transaction and kill SQL queries API to
>> make
> them similar to each other.
> I have plans to write an IEP for it and implement it.
> What do you think?
> 
> 
 
 --
 
 Best regards,
 Alexei Scherbakov
 
>>> 
>>> 
>>> --
>>> 
>>> Best regards,
>>> Alexei Scherbakov
>> 
>> 
> 
> -- 
> 
> Best regards,
> Alexei Scherbakov



Re: [DISCUSSION] API to KILL any user started computation

2020-01-16 Thread Alexei Scherbakov
Nikolaj,

Can we use system views instead of implementing something new ?

Each user operation has an unique ID.

It's possible to introduce universal SQL kill something like:

kill transaction ID

where id is taken from system view.


чт, 16 янв. 2020 г. в 14:19, Николай Ижиков :

> Hello, Alexey.
>
> I’m talking about *administrator* API.
>
> For example, the User has a cluster that is used by several applications.
> Some application starts buggy compute tasks that consume all CPU resources.
> Right now, administrator doesn’t have the ability to kill this task.
>
> This can lead to instability of the whole cluster.
>
>
> > 16 янв. 2020 г., в 13:42, Alexei Scherbakov <
> alexey.scherbak...@gmail.com> написал(а):
> >
> > Transactions can be also rolled back using tx.close where close is
> > java.lang.AutoCloseable#close
> > It looks for me to the definition of uniform cancel API.
> >
> >
> >
> > чт, 16 янв. 2020 г. в 13:37, Alexei Scherbakov <
> alexey.scherbak...@gmail.com
> >> :
> >
> >> Nikolaj,
> >>
> >> We already have cancellation possibilities for almost every user
> >> computation.
> >> Transactions are cancelled using tx.rollback()
> >> Queries are cancelled using query.close()
> >> Task is cancellable through ComputeTaskSession
> >>
> >> What is uniform cancel API ? Why do we need it ?
> >>
> >>
> >>
> >> ср, 15 янв. 2020 г. в 21:30, Николай Ижиков :
> >>
> >>> Hello, Igniters.
> >>>
> >>> As you may know, we put a lot of effort to improve Ignite metric and
> >>> diagnostic API.
> >>> We have created the following API:
> >>>* Metric manager
> >>>* System view manager
> >>> As far as I know, we would have tracing capabilities soon.
> >>>
> >>> I think it's time to take the next step.
> >>> We should provide to the administrator the API to cancel(stop, kill)
> >>> arbitrary user started computation.
> >>>
> >>> Right now we have API to do it for:
> >>>* transactions `TransactionsMXBean#getActiveTransactions`.
> >>>* SQL queries: `KILL QUERY` sql command and visor task -
> >>> `VisorQueryCancelTask`
> >>>
> >>> Please, note, these features are implemented via different API.
> >>>
> >>> I think we should introduce uniform Cancel API for the following
> >>> computations:
> >>>
> >>>* service.
> >>>* specific service method execution.
> >>>* compute job(compute task).
> >>>* query(scan, continuous, text).
> >>>
> >>> We should  also rework kill transaction and kill SQL queries API to
> make
> >>> them similar to each other.
> >>> I have plans to write an IEP for it and implement it.
> >>> What do you think?
> >>>
> >>>
> >>
> >> --
> >>
> >> Best regards,
> >> Alexei Scherbakov
> >>
> >
> >
> > --
> >
> > Best regards,
> > Alexei Scherbakov
>
>

-- 

Best regards,
Alexei Scherbakov


Re: [DISCUSSION] API to KILL any user started computation

2020-01-16 Thread Николай Ижиков
Hello, Alexey.

I’m talking about *administrator* API.

For example, the User has a cluster that is used by several applications.
Some application starts buggy compute tasks that consume all CPU resources.
Right now, administrator doesn’t have the ability to kill this task.

This can lead to instability of the whole cluster.


> 16 янв. 2020 г., в 13:42, Alexei Scherbakov  
> написал(а):
> 
> Transactions can be also rolled back using tx.close where close is
> java.lang.AutoCloseable#close
> It looks for me to the definition of uniform cancel API.
> 
> 
> 
> чт, 16 янв. 2020 г. в 13:37, Alexei Scherbakov > :
> 
>> Nikolaj,
>> 
>> We already have cancellation possibilities for almost every user
>> computation.
>> Transactions are cancelled using tx.rollback()
>> Queries are cancelled using query.close()
>> Task is cancellable through ComputeTaskSession
>> 
>> What is uniform cancel API ? Why do we need it ?
>> 
>> 
>> 
>> ср, 15 янв. 2020 г. в 21:30, Николай Ижиков :
>> 
>>> Hello, Igniters.
>>> 
>>> As you may know, we put a lot of effort to improve Ignite metric and
>>> diagnostic API.
>>> We have created the following API:
>>>* Metric manager
>>>* System view manager
>>> As far as I know, we would have tracing capabilities soon.
>>> 
>>> I think it's time to take the next step.
>>> We should provide to the administrator the API to cancel(stop, kill)
>>> arbitrary user started computation.
>>> 
>>> Right now we have API to do it for:
>>>* transactions `TransactionsMXBean#getActiveTransactions`.
>>>* SQL queries: `KILL QUERY` sql command and visor task -
>>> `VisorQueryCancelTask`
>>> 
>>> Please, note, these features are implemented via different API.
>>> 
>>> I think we should introduce uniform Cancel API for the following
>>> computations:
>>> 
>>>* service.
>>>* specific service method execution.
>>>* compute job(compute task).
>>>* query(scan, continuous, text).
>>> 
>>> We should  also rework kill transaction and kill SQL queries API to make
>>> them similar to each other.
>>> I have plans to write an IEP for it and implement it.
>>> What do you think?
>>> 
>>> 
>> 
>> --
>> 
>> Best regards,
>> Alexei Scherbakov
>> 
> 
> 
> -- 
> 
> Best regards,
> Alexei Scherbakov



Re: [DISCUSSION] API to KILL any user started computation

2020-01-16 Thread Alexei Scherbakov
Transactions can be also rolled back using tx.close where close is
java.lang.AutoCloseable#close
It looks for me to the definition of uniform cancel API.



чт, 16 янв. 2020 г. в 13:37, Alexei Scherbakov :

> Nikolaj,
>
> We already have cancellation possibilities for almost every user
> computation.
> Transactions are cancelled using tx.rollback()
> Queries are cancelled using query.close()
> Task is cancellable through ComputeTaskSession
>
> What is uniform cancel API ? Why do we need it ?
>
>
>
> ср, 15 янв. 2020 г. в 21:30, Николай Ижиков :
>
>> Hello, Igniters.
>>
>> As you may know, we put a lot of effort to improve Ignite metric and
>> diagnostic API.
>> We have created the following API:
>> * Metric manager
>> * System view manager
>> As far as I know, we would have tracing capabilities soon.
>>
>> I think it's time to take the next step.
>> We should provide to the administrator the API to cancel(stop, kill)
>> arbitrary user started computation.
>>
>> Right now we have API to do it for:
>> * transactions `TransactionsMXBean#getActiveTransactions`.
>> * SQL queries: `KILL QUERY` sql command and visor task -
>> `VisorQueryCancelTask`
>>
>> Please, note, these features are implemented via different API.
>>
>> I think we should introduce uniform Cancel API for the following
>> computations:
>>
>> * service.
>> * specific service method execution.
>> * compute job(compute task).
>> * query(scan, continuous, text).
>>
>> We should  also rework kill transaction and kill SQL queries API to make
>> them similar to each other.
>> I have plans to write an IEP for it and implement it.
>> What do you think?
>>
>>
>
> --
>
> Best regards,
> Alexei Scherbakov
>


-- 

Best regards,
Alexei Scherbakov


Re: [DISCUSSION] API to KILL any user started computation

2020-01-16 Thread Alexei Scherbakov
Nikolaj,

We already have cancellation possibilities for almost every user
computation.
Transactions are cancelled using tx.rollback()
Queries are cancelled using query.close()
Task is cancellable through ComputeTaskSession

What is uniform cancel API ? Why do we need it ?



ср, 15 янв. 2020 г. в 21:30, Николай Ижиков :

> Hello, Igniters.
>
> As you may know, we put a lot of effort to improve Ignite metric and
> diagnostic API.
> We have created the following API:
> * Metric manager
> * System view manager
> As far as I know, we would have tracing capabilities soon.
>
> I think it's time to take the next step.
> We should provide to the administrator the API to cancel(stop, kill)
> arbitrary user started computation.
>
> Right now we have API to do it for:
> * transactions `TransactionsMXBean#getActiveTransactions`.
> * SQL queries: `KILL QUERY` sql command and visor task -
> `VisorQueryCancelTask`
>
> Please, note, these features are implemented via different API.
>
> I think we should introduce uniform Cancel API for the following
> computations:
>
> * service.
> * specific service method execution.
> * compute job(compute task).
> * query(scan, continuous, text).
>
> We should  also rework kill transaction and kill SQL queries API to make
> them similar to each other.
> I have plans to write an IEP for it and implement it.
> What do you think?
>
>

-- 

Best regards,
Alexei Scherbakov


[DISCUSSION] API to KILL any user started computation

2020-01-15 Thread Николай Ижиков
Hello, Igniters.

As you may know, we put a lot of effort to improve Ignite metric and diagnostic 
API.
We have created the following API:
* Metric manager
* System view manager
As far as I know, we would have tracing capabilities soon.

I think it's time to take the next step.
We should provide to the administrator the API to cancel(stop, kill) arbitrary 
user started computation.

Right now we have API to do it for:
* transactions `TransactionsMXBean#getActiveTransactions`.
* SQL queries: `KILL QUERY` sql command and visor task - 
`VisorQueryCancelTask` 

Please, note, these features are implemented via different API.

I think we should introduce uniform Cancel API for the following computations:

* service.
* specific service method execution.
* compute job(compute task).
* query(scan, continuous, text).

We should  also rework kill transaction and kill SQL queries API to make them 
similar to each other.
I have plans to write an IEP for it and implement it. 
What do you think?