From owner-freebsd-arch@freebsd.org Tue Dec 20 00:38:08 2016 Return-Path: Delivered-To: freebsd-arch@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 07568C88D10; Tue, 20 Dec 2016 00:38:08 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-wj0-x242.google.com (mail-wj0-x242.google.com [IPv6:2a00:1450:400c:c01::242]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id A1C02AAF; Tue, 20 Dec 2016 00:38:07 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: by mail-wj0-x242.google.com with SMTP id kp2so25660540wjc.0; Mon, 19 Dec 2016 16:38:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=461xUVmZnZeRUuaRZ+A78xEad/2VWl1/tWse/wGpI0I=; b=VzrmGK4C+Sv0fbfFI3ibV9pqYuNFv1Sp2/mtOqwbc2NJU50pRMp5jP8ti5XXGTjTq4 BYs97DiZOZ8rlq80bUAZ5HXFyKtw7a2oxqFer2b5gNXvtyVTUNW6mVi9Zcz7Cc5637z7 ZOGRfkNHbZNBQqzfggv22q9S8lXkGSehSmCyiCzHTcBSow9wahNf3ZoPqMGffFI7bQWz MYXZ5gQ7QvwkZBDiZsCrUMdux4GCZSVdjapInKBdaUvFfaL4+pwd09fEevvrNju7Hniz y6OXdDLGoa+qac577E4lInwzL4Yw3DsEabIpMv2+V9SvsGE2Yf3YQgyS4tFtI1sZBHVw /Ygw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=461xUVmZnZeRUuaRZ+A78xEad/2VWl1/tWse/wGpI0I=; b=GHV4R0Gf5RnuGchbNLL9GUP4brps7HUYGkK0iTENoGo1O4Rs80mXT7oJR/ajVmcXd3 M/US4HpAGCMSCjIhzHlplHe3JQRG77SCaFd2U3d4NGSws+zrw0zemMqWdlc96yrKAMpA a63jHH8cSqVIIVBSvSI0LQx5aM9ttNT55aH2jnIs6pYssBmCE3x+7rE9htEE5gHcKd0G WhKQcJCXo01QcFBTU+bVgQi/KYsCUJCDNdnBY+JM6Vv5WTvBx63ViNjPZu1VnGdeM6rh 461VwTdWG7W54H49bxpZQy5E6liaJnEs/sEiiIHBYOCHu6YxwzjZMksOu7tPjiHJCXJC i7Kg== X-Gm-Message-State: AIkVDXLsGl899ogUjc4tG4pyZGpMwDhLLfGFxvtn4K5FBIIY1powabcdD49j3jM4d0gjajxeAhHmuBrbXqH9Rg== X-Received: by 10.194.187.103 with SMTP id fr7mr15204315wjc.99.1482194286007; Mon, 19 Dec 2016 16:38:06 -0800 (PST) MIME-Version: 1.0 Received: by 10.194.44.1 with HTTP; Mon, 19 Dec 2016 16:38:05 -0800 (PST) In-Reply-To: References: <20161220.043646.1181938468712455328.hrs@allbsd.org> From: Adrian Chadd Date: Mon, 19 Dec 2016 16:38:05 -0800 Message-ID: Subject: Re: RFC: DTrace probes for debugging or testing in userland programs To: Jordan Hubbard Cc: "freebsd-arch@freebsd.org" , freebsd-current Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Dec 2016 00:38:08 -0000 On 19 December 2016 at 16:04, Jordan Hubbard wrote= : > > On Dec 19, 2016, at 12:27 PM, Adrian Chadd wrote= : > > So although I like the sentiment, I don't think using dtrace for > program logging is the right answer. I like what apple did to wrap > the program logging stuff so people didn't just write their own > libraries (hi!) and so there's a unified-ish way to interact with > apple programs. I think we could do with that. > > > Thanks! > > We did a number of other things with ASL (Apple System Logger) which I mi= ss > very much today and would hope to see in any FreeBSD equivalent: > > 1. We structured all log data into dictionaries, so every application and= /or > subsystem within that application can add its own =E2=80=9Ctags=E2=80=9D = without squashing > other key information. This also unified the character encoding format, = so > some applications were no longer logging in ISO-Latin1, others in UTF-8 a= nd > yet others in SHIFT-JIS. > > 2. There=E2=80=99s also a logging database, as one of the many possible = =E2=80=9Coutput > sinks=E2=80=9D, so searches / queries are fast (and there=E2=80=99s an AP= I for querying and > managing its contents). > > 3. We added client-side and server side logging filters, so you can =E2= =80=9Ccrank > an application up=E2=80=9D or shut its mouth without having to make any c= ode > changes. > > 4. It=E2=80=99s all thread-safe. Hm. Where's the ASL source hiding? I'm kinda hoping it's light weight enough to port over without porting a lot of other stuff, but I am also afraid it's Apple.. :) -adrian