Return-Path: X-Original-To: apmail-thrift-user-archive@www.apache.org Delivered-To: apmail-thrift-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E07064DD8 for ; Thu, 7 Jul 2011 14:15:40 +0000 (UTC) Received: (qmail 55904 invoked by uid 500); 7 Jul 2011 14:15:40 -0000 Delivered-To: apmail-thrift-user-archive@thrift.apache.org Received: (qmail 55835 invoked by uid 500); 7 Jul 2011 14:15:39 -0000 Mailing-List: contact user-help@thrift.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@thrift.apache.org Delivered-To: mailing list user@thrift.apache.org Received: (qmail 55827 invoked by uid 99); 7 Jul 2011 14:15:39 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 Jul 2011 14:15:39 +0000 X-ASF-Spam-Status: No, hits=-1.4 required=5.0 tests=FREEMAIL_FROM,RCVD_IN_DNSWL_MED,RCVD_NUMERIC_HELO,SPF_HELO_PASS,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of gcltu-thrift-user@m.gmane.org designates 80.91.229.12 as permitted sender) Received: from [80.91.229.12] (HELO lo.gmane.org) (80.91.229.12) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 Jul 2011 14:15:31 +0000 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1QepMA-000096-Ph for user@thrift.apache.org; Thu, 07 Jul 2011 16:15:06 +0200 Received: from 65.49.68.164 ([65.49.68.164]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 07 Jul 2011 16:15:06 +0200 Received: from zhangyingneng by 65.49.68.164 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 07 Jul 2011 16:15:06 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: user@thrift.apache.org From: eben Subject: Why Cannot Sleep in NonBlockingServer Date: Thu, 7 Jul 2011 14:07:45 +0000 (UTC) Lines: 11 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: sea.gmane.org User-Agent: Loom/3.14 (http://gmane.org/) X-Loom-IP: 65.49.68.164 (Mozilla/5.0 (Windows NT 5.2) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/13.0.782.41 Safari/535.1) C++ , NonBlockingServer(libevent2), ThreadManager 10 workers, I put 'Sleep(100)' in my Handler Then I found the server will run to the next line of sleep. I know I should not use Sleep, But I also want to know why thrift strict us not to use it.