From dev-return-43978-archive-asf-public=cust-asf.ponee.io@ignite.apache.org Fri Jan 11 17:19:30 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id 8D5CD180648 for ; Fri, 11 Jan 2019 17:19:29 +0100 (CET) Received: (qmail 26763 invoked by uid 500); 11 Jan 2019 16:19:28 -0000 Mailing-List: contact dev-help@ignite.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ignite.apache.org Delivered-To: mailing list dev@ignite.apache.org Received: (qmail 26751 invoked by uid 99); 11 Jan 2019 16:19:27 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 11 Jan 2019 16:19:27 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 905C6C222B for ; Fri, 11 Jan 2019 16:19:27 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.971 X-Spam-Level: ** X-Spam-Status: No, score=2.971 tagged_above=-999 required=6.31 tests=[DKIMWL_WL_MED=-0.141, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, URI_HEX=1.313] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id oH3ONrOHKj5g for ; Fri, 11 Jan 2019 16:19:24 +0000 (UTC) Received: from mail-qt1-f180.google.com (mail-qt1-f180.google.com [209.85.160.180]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id 4D3805F358 for ; Fri, 11 Jan 2019 16:19:24 +0000 (UTC) Received: by mail-qt1-f180.google.com with SMTP id p17so19395042qtl.5 for ; Fri, 11 Jan 2019 08:19:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=rBx1ODDJ7ifUduaL5jth06YiYQ0OPbipXHf/fbM3d20=; b=JTrwKXDM4Q4D/v2PKgJphBZMoiQiVsXOvuoQeOG8KLo+JPppltZm012xRoRrRRefXs A5+Y0Ts2CjzCTDRa8De+IYwZ7ozpem1Wvm1dr5AW/VPCjHqBd0Nz4kR/MVMljzPo/NK9 PcDWF1ZXQo/HPmTg9BjqHPH1Kk7e3Cbhp/GzyO/eky10YAI0tN5DGY/Jj2VXL2WxEKJE +63oYSIcun9p8apzfAYWT816wgsEzPh3ie9JXBtgXjiBgajM0vhX5u8wUpfYDR0nVVNN VUlzdrIbQB9+ohDVyCRrNfhE6Fa1kOMAEl0YpUNHDbwFiSOSGYhZCty1DjB4oVK9GG6U 7K5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=rBx1ODDJ7ifUduaL5jth06YiYQ0OPbipXHf/fbM3d20=; b=B1sTsFiCmuiKl3631zpRUlg3sCc+6bD6QXFiz3Ju+dipigP+VHMbNg22QMnCWs/T8T Tl3GNCRr9TV/0lDFCzzACcL5YxgCuHYWtu7EweZHAHvwkv4ykajGSD4zu6Zx6JoAY+hL i1P7Gl12rTzfBElSLdrLFPvSJC6AJ7SM2uOSabmDnaJUxD7+cGK7zyVE+/mdYUh8jr+j qBieIYsAQ0Ixxclb2XCYRkEOcrlGLN9s+MIMl4nH8DApOhn7PXCHqGFyWbLU4izjC1Wt z1FMb1e5tqupYw8Wb0Ig4gt0GdY3lQP2beYRHxJjyAQ0Qo1/ClhobUvoPT+i16IAN5Cu lLYg== X-Gm-Message-State: AJcUukdQLSJxD9yrs6dy+kUmzcg70hgXoomX5+qM+OBEj/zCW9n/pNtc HK6RH6h9+O1M8Yz2yNZMvTcgd6TioBoi1i3TlQDEMw== X-Google-Smtp-Source: ALg8bN7zLFRXczeSMxgUUm5P4eRpIjJ9C20ikhKBagGKhAQlfo0eK51NRL//aBdSNWZPKcxC2xnZfhM3R31i6ei78H4= X-Received: by 2002:a0c:e789:: with SMTP id x9mr13608970qvn.245.1547223562929; Fri, 11 Jan 2019 08:19:22 -0800 (PST) MIME-Version: 1.0 References: <624bc857.6136.15cca3f285d.Coremail.sahala232@163.com> <10F9C7AA-C71D-438E-B4EE-F7672552E4EF@me.com> In-Reply-To: From: Ilya Kasnacheev Date: Fri, 11 Jan 2019 19:19:11 +0300 Message-ID: Subject: Re: Replace Cron4J with Quartz for ignite-schedule module. To: dev@ignite.apache.org Content-Type: multipart/alternative; boundary="000000000000db4c8b057f310e51" --000000000000db4c8b057f310e51 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hello! In any case I don't see why we would keep ignite-schedule module. We could merge this change if you moved this functionality into ignite-spring (while also fixing single thread problem). The sole reason of existence of ignite-schedule module was the extra dependency, if we don't have it anymore there's no reason to have this tiny module. Regards, --=20 Ilya Kasnacheev =D0=BF=D1=82, 28 =D0=B4=D0=B5=D0=BA. 2018 =D0=B3. =D0=B2 17:18, Sergey : > Ilya, > before deciding about drop just don't forget that our scheduleLocal metho= d > extends functionality with optional prefix before standard Cron expressio= n > {n1, > n2} where n1 is delay of scheduling and n2 is number of executions. > > Also we have own protection against task that has not finished before new > execution: > Look at > org.apache.ignite.internal.processors.schedule.ScheduleFutureImpl#run > In this case a new task won't be executed (it just log warning message) > disregarding Cron4J or Spring is used. > > Best regards, > Sergey Kosarev. > > > =D0=BF=D1=82, 28 =D0=B4=D0=B5=D0=BA. 2018 =D0=B3. =D0=B2 13:51, Ilya Kasn= acheev : > > > Hello! > > > > I've spent considerable amount of time working on your patch yesterday, > but > > eventually I have come to conclusion that we should Deprecate > > IgniteScheduler and ignite-schedule module, and Remove it in 3.0. > > > > The reason for this: IgnoteScheduler interface has 5 methods, of those > > callLocal() and runLocal() should probably be moved to IgniteCompute, > > runLocal() with timeout should be moved somewhere elsewhere, and > > scheduleLocal() which we are discussing should be removed since it does > not > > offer anything that you can't already do with Spring > > ScheduledThreadPoolExecutor. It has no non-Local methods and it is hard > to > > understand why this functionality should belong to Ignite at all. WDYT? > I'd > > drop it in 3.0 and call it a day. Since then, avoid touching it. > > > > If we decide to NOT drop it, we should remove ignite-schedule module > anyway > > and move this code into ignite-spring module. As soon as we have Spring > we > > can have fully functioning IgniteScheduler so a dedicated module is NOT > > needed. Are you ready to do that? > > > > I'm not really ready to merge your patch for two additional reasons: > > - 1 thread limitation looks severe and will make scheduling more than 1= -2 > > tasks a dangerous affair - one task may block your scheduler forever an= d > > nothing else will be ran. > > - What should happen if you scheduled a task every 5 minutes, task runs > for > > 6 minutes already and it's time to start it again: will it be started > > concurrently, will it wait for the old one to finish and then start, wi= ll > > it be discarded and ran only in 10 minutes after the original one is > > started? What is the behavior of cron4j? What is the behavior of propos= ed > > impl? Unfortunately we don't have tests on this and we don't want to, > since > > they'll take a lot of wall clock time, which we try to avoid to decreas= e > TC > > run time. > > > > Regards, > > -- > > Ilya Kasnacheev > > > > > > =D1=87=D1=82, 27 =D0=B4=D0=B5=D0=BA. 2018 =D0=B3. =D0=B2 18:53, Sergey = : > > > > > Hi, Ilya! > > > It looks like Spring *ThreadPoolTaskScheduler* is bounded to JDK's > > > *ScheduledThreadPoolExecutor*, so to launch scheduled tasks on public > > pool > > > we need provide *ScheduledThreadPoolExecutor* for Public pool. > Currently > > I > > > see we create Public pool executor as *IgniteThreadPoolExecutor* and = it > > > extends *ThreadPoolExecutor*. > > > It seems we can easily introduce *IgniteScheduledThreadPoolExecutor* > and > > > extend it from *ScheduledThreadPoolExecutor* for public pool. How do > you > > > like it? > > > > > > Your idea about delegating tasks from Spring 1-threaded pool to Publi= c > > pool > > > looks also workable. > > > > > > Best regards, > > > Sergey Kosarev. > > > > > > > > > =D0=B2=D1=82, 25 =D0=B4=D0=B5=D0=BA. 2018 =D0=B3. =D0=B2 18:19, Ilya = Kasnacheev < > ilya.kasnacheev@gmail.com > > >: > > > > > > > Hello! > > > > > > > > I have started reviewing your pull request. > > > > I will expect that scheduled tasks are executed on Public pool. Is = it > > > > possible that tasks are launched on Public pool? If Spring Schedule= r > > > > insists on its own thread pool, we can have single-thread pool whic= h > > will > > > > execute put of tasks to public pool and immediately return. Is it > > > possible > > > > to do that? > > > > > > > > Regards, > > > > -- > > > > Ilya Kasnacheev > > > > > > > > > > > > =D0=B2=D1=82, 25 =D0=B4=D0=B5=D0=BA. 2018 =D0=B3. =D0=B2 17:46, Ale= xey Kuznetsov >: > > > > > > > > > Hi, Sergey! > > > > > > > > > > I think we should keep compatibility as much as possible for Igni= te > > > 2.x. > > > > > And we can do breaking changes in Ignite 3.x > > > > > > > > > > What do you think? > > > > > > > > > > > > > > > On Mon, Dec 24, 2018 at 11:58 PM Sergey > > wrote: > > > > > > > > > > > HI, Igniters! > > > > > > > > > > > > I've updated and rebased implementation to master branch and ma= de > > > some > > > > > > fixes. > > > > > > Also I have a question regarding current implementation. > > > > > > > > > > > > As I found Cron4J source code this implementation checks schedu= le > > > every > > > > > > minute (seconds not supported) but spawns a thread for every ta= sk > > > which > > > > > > scheduling pattern matches the current time. There no any limit= s > to > > > the > > > > > > number of tasks launched silmultaneously. > > > > > > > > > > > > New implementation is based on > > > > > > org.springframework.scheduling.concurrent.ThreadPoolTaskSchedul= er > > > > > > with its default parameters currently, i.e thread pool size is = 1. > > > > > > > > > > > > Could you advise me, do we need to add some system property or > > > > introduce > > > > > > some attribute to IgniteConfiguration to configure Scheduler > thread > > > > pool > > > > > > size? And what should be default value? > > > > > > > > > > > > > > > > > > Best regards, > > > > > > Sergey Kosarev. > > > > > > > > > > > > > > > > > > =D1=87=D1=82, 10 =D0=BC=D0=B0=D1=8F 2018 =D0=B3. =D0=B2 20:23, = Dmitry Pavlov >: > > > > > > > > > > > > > Hi Anton, > > > > > > > > > > > > > > Thank you for joining and review. > > > > > > > I hope all proposals will be applied. > > > > > > > > > > > > > > Sincerely, > > > > > > > Dmitriy Pavlov > > > > > > > > > > > > > > =D0=BF=D1=82, 4 =D0=BC=D0=B0=D1=8F 2018 =D0=B3. =D0=B2 16:04,= Anton Vinogradov : > > > > > > > > > > > > > > > Folks, > > > > > > > > > > > > > > > > How can it be at PATCH AVAILABLE since *none* of my latest > > > comments > > > > > > (made > > > > > > > > Feb 8) are resolved at Upsource? > > > > > > > > Changed state to IP. > > > > > > > > > > > > > > > > =D0=BF=D0=BD, 23 =D0=B0=D0=BF=D1=80. 2018 =D0=B3. =D0=B2 20= :00, Dmitry Pavlov < > > > dpavlov.spb@gmail.com > > > > >: > > > > > > > > > > > > > > > > > Hi Andrey, > > > > > > > > > > > > > > > > > > Could you please pick up review? > > > > > > > > > > > > > > > > > > Sincerely, > > > > > > > > > Dmitriy Pavlov > > > > > > > > > > > > > > > > > > =D0=BF=D0=BD, 23 =D0=B0=D0=BF=D1=80. 2018 =D0=B3. =D0=B2 = 17:39, Dmitriy Setrakyan < > > > > > > dsetrakyan@apache.org > > > > > > > >: > > > > > > > > > > > > > > > > > > > Dmitriy, who is a good candidate within the community t= o > > > review > > > > > > this > > > > > > > > > > ticket? > > > > > > > > > > > > > > > > > > > > On Mon, Apr 23, 2018 at 6:10 AM, Dmitry Pavlov < > > > > > > > dpavlov.spb@gmail.com> > > > > > > > > > > wrote: > > > > > > > > > > > > > > > > > > > > > Hi Igniters, > > > > > > > > > > > > > > > > > > > > > > it seems ticket > > > > > > https://issues.apache.org/jira/browse/IGNITE-5565 > > > > > > > is > > > > > > > > > > still > > > > > > > > > > > in PA state. What are our next steps? > > > > > > > > > > > > > > > > > > > > > > Who did review of this patch? > > > > > > > > > > > > > > > > > > > > > > Sincerely, > > > > > > > > > > > Dmitriy Pavlov > > > > > > > > > > > > > > > > > > > > > > =D1=81=D1=80, 28 =D0=B8=D1=8E=D0=BD. 2017 =D0=B3. =D0= =B2 1:40, Denis Magda < > > dmagda@apache.org > > > >: > > > > > > > > > > > > > > > > > > > > > > > Yakov, > > > > > > > > > > > > > > > > > > > > > > > > No, the mentioned discussion didn=E2=80=99t turn in= to a JIRA > > > > ticket. > > > > > > > > > > > > > > > > > > > > > > > > Alex K., please follow to some thoughts from there > and > > > wrap > > > > > > them > > > > > > > up > > > > > > > > > in > > > > > > > > > > a > > > > > > > > > > > > form of the ticket. > > > > > > > > > > > > > > > > > > > > > > > > =E2=80=94 > > > > > > > > > > > > Denis > > > > > > > > > > > > > > > > > > > > > > > > > On Jun 26, 2017, at 2:58 AM, Yakov Zhdanov < > > > > > > > yzhdanov@apache.org> > > > > > > > > > > > wrote: > > > > > > > > > > > > > > > > > > > > > > > > > > Guys, I remember we discussed this some time ago. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > http://apache-ignite-developers.2346864.n4.nabble. > > > > > > > > > > > com/Tasks-Scheduling-and-Chaining-td14293.html > > > > > > > > > > > > > > > > > > > > > > > > > > Denis, do you have any ticket or SoW? > > > > > > > > > > > > > > > > > > > > > > > > > > --Yakov > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > Alexey Kuznetsov > > > > > > > > > > > > > > > --000000000000db4c8b057f310e51--