Return-Path: X-Original-To: apmail-ace-users-archive@minotaur.apache.org Delivered-To: apmail-ace-users-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 72237173F0 for ; Tue, 7 Oct 2014 16:46:55 +0000 (UTC) Received: (qmail 93224 invoked by uid 500); 7 Oct 2014 16:46:55 -0000 Delivered-To: apmail-ace-users-archive@ace.apache.org Received: (qmail 93200 invoked by uid 500); 7 Oct 2014 16:46:55 -0000 Mailing-List: contact users-help@ace.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@ace.apache.org Delivered-To: mailing list users@ace.apache.org Received: (qmail 93189 invoked by uid 99); 7 Oct 2014 16:46:55 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 07 Oct 2014 16:46:55 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=RCVD_IN_DNSWL_NONE,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of marcel.offermans@luminis.eu designates 157.55.234.141 as permitted sender) Received: from [157.55.234.141] (HELO emea01-db3-obe.outbound.protection.outlook.com) (157.55.234.141) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 07 Oct 2014 16:46:27 +0000 Received: from marcels-mbp.fritz.box (82.95.193.148) by AMSPR03MB259.eurprd03.prod.outlook.com (10.242.85.148) with Microsoft SMTP Server (TLS) id 15.0.1039.15; Tue, 7 Oct 2014 16:46:23 +0000 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: Poor performance of the REST Client API with hundreds of targets. From: Marcel Offermans In-Reply-To: Date: Tue, 7 Oct 2014 18:46:19 +0200 Content-Transfer-Encoding: quoted-printable Message-ID: <713BF914-3CA4-4B36-9D13-00CFC7B37BB4@luminis.eu> References: To: ACE-users Apache ACE users X-Mailer: Apple Mail (2.1878.6) X-Originating-IP: [82.95.193.148] X-ClientProxiedBy: AM3PR05CA039.eurprd05.prod.outlook.com (10.141.192.49) To AMSPR03MB259.eurprd03.prod.outlook.com (10.242.85.148) X-Microsoft-Antispam: UriScan:; X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:;SRVR:AMSPR03MB259; X-Forefront-PRVS: 035748864E X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(6009001)(24454002)(377454003)(52044002)(199003)(189002)(69596002)(19580405001)(19580395003)(42186005)(46406003)(50466002)(97736003)(95666004)(85306004)(82746002)(106356001)(105586002)(122386002)(97756001)(40100002)(107046002)(81156004)(107886001)(110136001)(53416004)(77096002)(76482002)(50986999)(76176999)(104166001)(57306001)(4396001)(33656002)(50226001)(102836001)(101416001)(99396003)(120916001)(23726002)(86362001)(93916002)(20776003)(21056001)(88136002)(87976001)(47776003)(83716003)(66066001)(74482002)(46102003)(80022003)(89996001)(85852003)(87286001)(92726001)(92566001)(31966008)(64706001)(77156001)(36756003)(62966002)(104396001);DIR:OUT;SFP:1102;SCL:1;SRVR:AMSPR03MB259;H:marcels-mbp.fritz.box;FPR:;MLV:sfv;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-OriginatorOrg: luminis.eu X-Virus-Checked: Checked by ClamAV on apache.org Hello Klaus, On 07 Oct 2014, at 18:18 pm, Klaus.Meyer@Gebit.de wrote: > I want to use ACE (version 2.0.1) for deploying POS (Point of sale) = java=20 > clients. In my scenario I have hundreds or thousands of targets=20 > (POS-clients). I developed an API around the REST-API for creation of=20= > distributions which point to an associated feature which contains = about=20 > 100 bundles. On the other side I have developed an API (based on the=20= > REST-API) which creates targets and connects them to the = distributions. I=20 > found out that when I import about 1000 targets then the allinone = server=20 > becomes extremely slow, when managing each kind of data (creating and=20= > deleting distributions, targets). Allocating a working area needs = about=20 > one minute or so. Also sometimes I get exceptions from the Felix=20 > preference service. Do you have already experiences whith a lot of=20 > targets, are there any issues known about performance ? Can you give = me=20 > some ideas what I can do next to solve my problem. Let me start by explaining a bit about how the ACE client code works, as = that will give you more insight into this problem. ACE consists of a server, a client and an OBR repository. Each can be = deployed independently, but for convenience we also have an "all-in-one" = version. The client is what you need to manipulate the repository, and = fundamentally the client works by "checking out" a copy of the current = configuration, manipulating it locally and, when done, "committing" the = new configuration back to the server. Now, the client has an OSGi API (services) you can talk to, and on top = of that we built three different APIs: 1. The web UI based on Vaadin. 2. The REST API. 3. The Gogo Shell API. The first two can work "over the network" with a browser or REST client = being the primary users. The last one works "on the client" and is therefore usually a lot = faster. We use it for all kinds of scripted access such as in continuous = integration scenarios. That being said, I have a few recommendations: First of all, if you build your own API, I would consider building it = directly on top of the OSGi, service based API just like the 3 existing = clients do. That will be a lot quicker than interfacing, over the = network, with a remote client. Second of all, you might want to consider the Gogo Shell API to script = these things. We use this in continuous integration and if it helps I = can provide some examples (but I probably need to know a bit more = details about the deployment process you are using). Finally, we have tested ACE with 100's to 1000's of targets. I would say = that is possible. I currently would not go to 10.000's of targets, our = benchmarks have shown that you are running into some limits there. = However, we have options to partition the targets into smaller groups = within ACE, so if necessary I can go into that a bit more and explore if = that is an option that could help you. Also, one thing that slows ACE = down is when you have "auto configuration" XML files which are templates = that have parameters that need to be substituted for each target. We are = still discussing ways to optimize that. I hope this gives you some pointers/suggestions that help. Feel free to = follow up if you have more questions. Greetings, Marcel