Return-Path: Delivered-To: apmail-jackrabbit-dev-archive@www.apache.org Received: (qmail 51991 invoked from network); 12 Jul 2009 20:12:27 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 12 Jul 2009 20:12:27 -0000 Received: (qmail 16305 invoked by uid 500); 12 Jul 2009 20:12:36 -0000 Delivered-To: apmail-jackrabbit-dev-archive@jackrabbit.apache.org Received: (qmail 16228 invoked by uid 500); 12 Jul 2009 20:12:36 -0000 Mailing-List: contact dev-help@jackrabbit.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@jackrabbit.apache.org Delivered-To: mailing list dev@jackrabbit.apache.org Received: (qmail 16220 invoked by uid 99); 12 Jul 2009 20:12:36 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 12 Jul 2009 20:12:36 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of jukka.zitting@gmail.com designates 209.85.220.224 as permitted sender) Received: from [209.85.220.224] (HELO mail-fx0-f224.google.com) (209.85.220.224) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 12 Jul 2009 20:12:28 +0000 Received: by fxm24 with SMTP id 24so1544666fxm.43 for ; Sun, 12 Jul 2009 13:12:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=2BXMWYEK8Svmqvscaed3Us4p1xMG1YzZUawCyBhxqWs=; b=GV/7jAXvCEH3vSqlF2XOOBJuXs/EGNCFwdZi3PDxIE8zUC8IIYL/NZ89BSgykJtmd7 zqr9Uvr1Z+Y6Rx7IVLUkY7UNwm9ZcJ5iHxjS5EGrkgmTqEDiqcmmLr+HYlnZtM89ne7K 2571YVv7WOY8xZ0vWx1rU38hWwslDplnBuqkc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=urlOiZtSwHP8eCW9i3hfrP2M4jvt2lHfVmG3MNIa++wH6p//S0oU3ec16AJi6bxc33 lvOGaiAIo5rr3u/5+uwlAw9aiHcqGv4NDlhYq3E2qMoYpKSZBTZv1i89Wai7I1e47zWp XxUzmi9g2oBqWwdJE5kB+VSzmvhjVSS6L7xw0= MIME-Version: 1.0 Received: by 10.204.52.135 with SMTP id i7mr4419276bkg.154.1247429526900; Sun, 12 Jul 2009 13:12:06 -0700 (PDT) In-Reply-To: References: <510143ac0907080537n465db1d7r192d4d417a025de3@mail.gmail.com> Date: Sun, 12 Jul 2009 22:12:06 +0200 Message-ID: <510143ac0907121312h4f084672sdbdf9413907d8485@mail.gmail.com> Subject: Re: Per-repository thread pool in Jackrabbit From: Jukka Zitting To: dev Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Hi, 2009/7/8 Marcel Reutegger : > - paralleled execution of some work. this is primarily to make use of > multi-core processors. execution should be distributed over and > executed by N threads which is a factor of the available processors. If I recall correctly we debated this already earlier. My point was that limiting the number of tasks to the number of available processors may not be a good approach as the tasks may be IO-bound or block for other reasons, in which case having more task threads would give you better throughput. But I recall being proven wrong, did we have some benchmark for that? Do you remember where this discussion was? > - Timers used in TransactionContext and MultiIndex. This could be > turned into a scheduling mechanism that could also be used by the > ClusterNode sync. Other classes that use periodic checks in a > background thread: DatabaseJournal (ClusterRevisionJanitor), > CooperativeFileLock (watch dog). Yep. Perhaps we could also reuse some of the scheduling functionality in Sling. > the more I think about it, the more I like your idea. but we should be > careful with a maximum size for a repository wide pool. extensive use > of the pool by a module should not lock up another module just because > there are no more idle threads. maybe that global pool shouldn't have > a maximum size... That might make sense. Perhaps we should have some concept of sub-pools (that borrow from the main pool) with fixed limits for tasks that need them (see above). BR, Jukka Zitting