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 3312B200C81 for ; Fri, 12 May 2017 07:05:11 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 31A77160BC7; Fri, 12 May 2017 05:05:11 +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 77FA0160BCA for ; Fri, 12 May 2017 07:05:10 +0200 (CEST) Received: (qmail 54773 invoked by uid 500); 12 May 2017 05:05:09 -0000 Mailing-List: contact users-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@activemq.apache.org Delivered-To: mailing list users@activemq.apache.org Received: (qmail 54411 invoked by uid 99); 12 May 2017 05:05:08 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 12 May 2017 05:05:08 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 79ED8CF25B for ; Fri, 12 May 2017 05:05:08 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.27 X-Spam-Level: * X-Spam-Status: No, score=1.27 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, HEADER_FROM_DIFFERENT_DOMAINS=0.001, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-2.796, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001, URIBL_BLOCKED=0.001, URI_HEX=1.313, URI_TRY_3LD=0.001, WEIRD_PORT=0.001] autolearn=disabled Authentication-Results: spamd1-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 (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id mN8_0GKBQeRW for ; Fri, 12 May 2017 05:05:06 +0000 (UTC) Received: from mail-ua0-f175.google.com (mail-ua0-f175.google.com [209.85.217.175]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id E96905F398 for ; Fri, 12 May 2017 05:05:05 +0000 (UTC) Received: by mail-ua0-f175.google.com with SMTP id g49so40801084uaa.1 for ; Thu, 11 May 2017 22:05:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=2NzktOimmrJ90rZNFI035kfc4Nxdt4vCE7+aTOIw+ss=; b=W8IjsbBg0lcy38WfEIxxUp2w/nqeCgOMlqIGpOB1M7pIEbhRplBeX7KoYzriP+wvAQ LAJDKC87jAdj0z3zM8E7KaGR5FN9rkClvFIfthJ4/0ahNtyZ3JhvEzGHZEddvlV/AdQX KJGZzfu4afapNiE7V64n4tiNVJlAnF8uzpdn96pOQI7MbB+QbBT3gnZzipCFN/v563lJ 7N1Zd2x94zAH6U7of+ZLi+KZJZRCFZLUs+qOmXV+g+1q2c/JQpZdIz/pXSIYQIasOjaU pQfBVZmocho2BU7QRkwzBuXUvWxyqC1LwHVSk6dBaIi4akp3TVm0n1zW73PF4zRXabTQ PcDg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=2NzktOimmrJ90rZNFI035kfc4Nxdt4vCE7+aTOIw+ss=; b=eumeYNSWwO9UiGGT/NMStZJ1ret8wyqhjQkaoMLOODhBCwGWzclgNJlahH98GMrwDM UtffJq40UL9avKAEiVeXafgFrA/fvF0SyCKcgCt8gdE41aKCCbztoU+Oo+2bTXeo2b4G Ot8adagRJ2U9uuaG5BX163fomhZiEIdd3be3Vqoif/5EzxTlnSUmewFna57GECB26LL0 RGFzZ9UtZZ9VJDul5AOVSY8XVNYYIP7dFrxl3P/XPc7qvyQrKtl4PfJrDRtv4lbdmVAT xyl/U2nRq2VkgE0Hfa0wBewXVGH7EfJjosf7MRYiHBScYCGf8WPCzOUj243W4nxSFKX1 y/Bg== X-Gm-Message-State: AODbwcCgXxND6CeN7u6QJzCPM86Yx97ekJYrdTkTWtCpqmn4HEr37Ivz cadgtuw19RpV5Ap6575UfoVJ7EhxZA== X-Received: by 10.176.86.90 with SMTP id z26mr1084182uaa.57.1494565505398; Thu, 11 May 2017 22:05:05 -0700 (PDT) MIME-Version: 1.0 Sender: tbain98@gmail.com Received: by 10.103.91.23 with HTTP; Thu, 11 May 2017 22:05:04 -0700 (PDT) Received: by 10.103.91.23 with HTTP; Thu, 11 May 2017 22:05:04 -0700 (PDT) In-Reply-To: <1494418730444-4725883.post@n4.nabble.com> References: <1494275827659-4725797.post@n4.nabble.com> <1494418730444-4725883.post@n4.nabble.com> From: Tim Bain Date: Thu, 11 May 2017 23:05:04 -0600 X-Google-Sender-Auth: 5wZxuNq6-KVD6UsCqCxBST4aOWk Message-ID: Subject: Re: ActiveMQ REST Api with HTTP To: ActiveMQ Users Content-Type: multipart/alternative; boundary="f403045dcba20afcfb054f4ca627" archived-at: Fri, 12 May 2017 05:05:11 -0000 --f403045dcba20afcfb054f4ca627 Content-Type: text/plain; charset="UTF-8" Is what you're doing (setting them via request parameters on the URL) the right way to set message header properties (e.g. test=2)? The page doesn't say explicitly, but I had assumed that you'd need to use the --header approach. You should be able to publish your messages and then look at them in the web console to confirm that the right values are getting set. Once you get the publisher working right, then you can move on to the consumer, selectors, etc. Tim On May 10, 2017 6:31 AM, "kovacro" wrote: > Hello, > > Point 1: > > I insert the the 4 following messages > > curl -u admin:admin -d "hello world 1" -H "Content-Type: text/plain" -XPOST > "http://localhost:8161/api/message?destination=queue:// > Test_Kovac&&clientId=KovacIP1" > > curl -u admin:admin -d "test selector" -H "selector test" -H "Content-Type: > text/plain" -XPOST "http://localhost:8161/api/message? > destination=queue://Test_Kovac&&clientId=KovacIP2&test=2" > > curl -u admin:admin -d "hello world 3" -H "Content-Type: text/plain" -XPOST > "http://localhost:8161/api/message?destination=queue:// > Test_Kovac&&clientId=KovacIP3" > > curl -u admin:admin -d "hello world 5" -H "Content-Type: text/plain" -XPOST > "http://localhost:8161/api/message?destination=queue:// > Test_Kovac&&clientId=KovacIP4" > > I retrieve 2 of them with this command > > curl -u admin:admin -X GET > "http://localhost:8161/api/message?destination=queue:// > Test_Kovac?type=queue&clientId=jojo" > > When I try with a different clientID, it doesn't work: > > curl -u admin:admin -X GET > "http://localhost:8161/api/message?destination=queue:// > Test_Kovac?type=queue&clientId=KovacIP2" > > Since the clientID is not a filter, why doesn't it work? > > > --------------- > Point 2: > > With the 2 followoing messages: > curl -u admin:admin -d "hello world 1" -H "Content-Type: text/plain" -XPOST > "http://localhost:8161/api/message?destination=queue:// > Test_Kovac&&clientId=KovacIP1" > > curl -u admin:admin -d "test selector=2" -H "selector: test" -H > "Content-Type: text/plain" -XPOST > "http://localhost:8161/api/message?destination=queue:// > Test_Kovac&&clientId=KovacIP2&test=2" > > I try this selector and it doesn't work, I can retrieve everything: > curl -u admin:admin -H "selector: test=2" -X GET > "http://localhost:8161/api/message?destination=queue:// > Test_Kovac?type=queue&clientId=KovacIP2" > > Conclusion: I can seem to filter any messages. > > > > > > > -- > View this message in context: http://activemq.2283324.n4. > nabble.com/ActiveMQ-REST-Api-with-HTTP-tp4725797p4725883.html > Sent from the ActiveMQ - User mailing list archive at Nabble.com. > --f403045dcba20afcfb054f4ca627--