[ 
https://issues.apache.org/jira/browse/IGNITE-21047?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Evgeny Stanilovsky updated IGNITE-21047:
----------------------------------------
    Fix Version/s: 3.2
                       (was: 3.1)

> Sql. Avoid spamming execution tasks when possible
> -------------------------------------------------
>
>                 Key: IGNITE-21047
>                 URL: https://issues.apache.org/jira/browse/IGNITE-21047
>             Project: Ignite
>          Issue Type: Improvement
>          Components: sql
>            Reporter: Konstantin Orlov
>            Assignee: Konstantin Orlov
>            Priority: Major
>              Labels: ignite-3
>             Fix For: 3.2
>
>         Attachments: 
> IGNITE-21047__Sql__Avoid_spamming_execution_tasks_when_possible.patch
>
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> Need to revise all usages of 
> {{org.apache.ignite.internal.sql.engine.exec.ExecutionContext#execute}} and 
> check whether spawning a new task is legit in every particular case or it's 
> better to do the work right now.
> For example, lets take a look at 
> {{org.apache.ignite.internal.sql.engine.exec.rel.ScanNode#request}}: 
>     
> {code:java}
> @Override
>     public void request(int rowsCnt) throws Exception {
>         assert rowsCnt > 0 && requested == 0 : "rowsCnt=" + rowsCnt + ", 
> requested=" + requested;
>         checkState();
>         requested = rowsCnt;
>         if (!inLoop) {
>             context().execute(this::push, this::onError);
>         }
>     }
> {code}
> in case of the very first request we will spawn a new task, but it would be 
> better to drain the first batch of rows as well.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to