Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id E1426200BE7 for ; Tue, 20 Dec 2016 17:44:27 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id DFDCD160B29; Tue, 20 Dec 2016 16:44:27 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 360C8160B12 for ; Tue, 20 Dec 2016 17:44:27 +0100 (CET) Received: (qmail 67954 invoked by uid 500); 20 Dec 2016 16:44:26 -0000 Mailing-List: contact dev-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list dev@activemq.apache.org Received: (qmail 67938 invoked by uid 99); 20 Dec 2016 16:44:26 -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; Tue, 20 Dec 2016 16:44:26 +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 AC2D6C00A6 for ; Tue, 20 Dec 2016 16:44:25 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.821 X-Spam-Level: X-Spam-Status: No, score=-0.821 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id l3DEwa1T7Mby for ; Tue, 20 Dec 2016 16:44:24 +0000 (UTC) Received: from mail-oi0-f46.google.com (mail-oi0-f46.google.com [209.85.218.46]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id 5990961012 for ; Tue, 20 Dec 2016 16:44:24 +0000 (UTC) Received: by mail-oi0-f46.google.com with SMTP id v84so182917193oie.3 for ; Tue, 20 Dec 2016 08:44:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding; bh=PdIusoRDjkYy3ZwDJkod6JuhcGorgG0HUpspbTA4cxw=; b=fhVt6cStf+WgUyqM8mwFgrHc0yzfsR4E/2JiBndA0ezqxUsLiICSzhbt2fBMTL8Fol QK4jT6Y0oNeXST/l9lneVJba5VAbeTajQf1jfZCPyC9sqwJRZBwRCYpxqcKl6EAyQYG2 a7ZyoyzdaKuHFVciwxbum92M0S4Ac+5xn9mbGzRCtqSF8Qh14Dk1z8DZVB5Y2fyy0RYZ DoE2ADsVPazO2hqS3m5On4cSwLToNCdxJfs0JIyZ4d0ZkRvd5JnsiRf8X/5AVXthmmfu SX/K94JbpGGzLEZwbPPBBj/sgDJ5QRPz3iIaf4UjYJLCnhKZU2ziORF0U1bWhELUn0+k 1iCA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=PdIusoRDjkYy3ZwDJkod6JuhcGorgG0HUpspbTA4cxw=; b=sSmI/kNGKoFqtp1Sn+T7D/IVauvCYsBv+EeghQPywi8r2ULUKk3QE00p7vKVFxOCpg g6T3B6f7GLGenE4l8qFvQFl+qthQvGl9RkX23xhXjM6KwE39/tUeTK6oNmc3lfK8tGpD QDRvRlvO/Y7MG7zpizE+FP+tDMCYzzbWNMcQnZlv4+zS4aKAPwkxPyfdlSn35rn/JsQe EZQfhq6hERRrkozcVhDEVXBJMarAtIHl6Gfft/s4SynxE5FyEtvIYfNPFt3vvtiM64uw vQVHJ0eRZQqOAk1BUwMRM7IL2QtFMDex7qvM/dCxZBw6mrjhyL36cpEstpEUgARq1aRr g+mg== X-Gm-Message-State: AIkVDXJgljF7h+9I/PywBb601v36+VpisedBj74do1yRoxmq6HWa5qHaQQkL0P8q2d4k2w== X-Received: by 10.157.2.72 with SMTP id 66mr156156otb.118.1482252248366; Tue, 20 Dec 2016 08:44:08 -0800 (PST) Received: from mattbookpro.local (rrcs-67-79-3-86.sw.biz.rr.com. [67.79.3.86]) by smtp.gmail.com with ESMTPSA id 61sm9816697otb.8.2016.12.20.08.44.07 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 20 Dec 2016 08:44:07 -0800 (PST) Subject: Re: [DISCUSS] Artemis plugins ARTEMIS-898 To: dev@activemq.apache.org References: <2c22bee4-5d67-c764-fe6b-4a5cd2e14999@gmail.com> From: Matt Pavlovich Message-ID: <166f2ace-e11c-2cba-21ff-feeebb775057@gmail.com> Date: Tue, 20 Dec 2016 10:44:07 -0600 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit archived-at: Tue, 20 Dec 2016 16:44:28 -0000 Clebert- I think outbound/inbound separation would be really handy for plugin writers. Are these statements correct based on what you are thinking w/ inbound and outbound? 1. The outboundTransformer() would transform messages for one or more client consumer(s) and across protocols. ie.. one JMS consumer, one STOMP consumer on the same address would receive the transformed copy of the message. 2. The outboundTransformer would _not_ transformation messages being sent to other brokers (replication and/or pub+sub to brokers in a cluster) 3. For the inboundTransformer.. the message would be transformed for all delivery into the broker for all consumers, brokers and diverts. Thanks, Matt On 12/20/16 10:33 AM, Clebert Suconic wrote: > I think we should include two options on AddressSettings: > > i - inboundTransformer > ii - maybe an outboundTransformer > > inboundTransformer (String address, ServerSession session, > ServerMessage message); > outboundTransformer(String address, ServerSession session, > ServerMessage message); > > > The trick part here is that outboundTransformer would need to work on > a copy of the message. so, the API needs to return a copy of the > message. > > > > I am working now on refactoring encoding and transformer between > protocols that would make this a bit easier. I'm at the design phase > and I will post a DISCUSS thread about that when I have something more > concrete to talk about it. > > > > > On Tue, Dec 20, 2016 at 11:22 AM, Matt Pavlovich wrote: >> I was taking a first step in implementing an existing ActiveMQ 5.x plugin in >> the Artemis source and noticed that there is a gap in the availability of >> extension points in Artemis (or plugins). >> >> I opened ARTEMIS-898 for tracking, and thought it deserved a discussion. >> This feels like a good target as a 2.x feature, since it would most likely >> be API changing. It stands to reason the extension points in Artemis would >> be very different than ActiveMQ 5.x, so I've laid it out in terms of >> features and capabilities. >> >> The big three: >> >> 1. Message header / property manipulation. Allows admins to set message >> policies for things like JMSXUserId, Timestamps, Expiry, etc >> >> 2. Message body manipulation. (Clebert mentioned perhaps an extension of >> Divert / Transformers?) >> >> 3. Activity tracing for audit tracing and/or triggering other activity >> (extension point at PostOffice and ActiveMQServer ?) >> >> One side benefit might be that Advisory support becomes a plugin vs an >> ingrained feature. Could be handy to have all the advisory logic in one >> place to allow more customization of behavior. >> >> Thoughts? >> >> -Matt Pavlovich >> >> > >