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 E2003200BB5 for ; Sun, 6 Nov 2016 22:44:21 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id E07A8160B0D; Sun, 6 Nov 2016 21:44:21 +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 30E0F160AE8 for ; Sun, 6 Nov 2016 22:44:21 +0100 (CET) Received: (qmail 71320 invoked by uid 500); 6 Nov 2016 21:44:20 -0000 Mailing-List: contact users-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@cxf.apache.org Delivered-To: mailing list users@cxf.apache.org Received: (qmail 71309 invoked by uid 99); 6 Nov 2016 21:44:19 -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; Sun, 06 Nov 2016 21:44:19 +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 63B48C1BA9 for ; Sun, 6 Nov 2016 21:44:19 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.592 X-Spam-Level: ** X-Spam-Status: No, score=2.592 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, PLING_QUERY=0.279, RCVD_IN_DNSWL_NONE=-0.0001, URI_HEX=1.313] autolearn=disabled 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 87p67-tx2Sfi for ; Sun, 6 Nov 2016 21:44:17 +0000 (UTC) Received: from vie01a-dmta-at51-2.mx.upcmail.net (vie01a-dmta-at51-2.mx.upcmail.net [62.179.121.140]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id F01685F30C for ; Sun, 6 Nov 2016 21:44:16 +0000 (UTC) Received: from [172.31.216.41] (helo=vie01a-pemc-psmtp-at50) by vie01a-dmta-at51.mx.upcmail.net with esmtp (Exim 4.87) (envelope-from ) id 1c3VEd-0003jc-09 for users@cxf.apache.org; Sun, 06 Nov 2016 22:44:15 +0100 Received: from [192.168.1.13] ([80.110.36.208]) by vie01a-pemc-psmtp-at50 with SMTP @ mailcloud.upcmail.net id 4lkE1u00e4VStTk0BlkECA; Sun, 06 Nov 2016 22:44:14 +0100 X-SourceIP: 80.110.36.208 X-Authenticated-Sender: modsec@fwd.at X-CNFS-Analysis: v=2.2 cv=FpZHxCjq c=1 sm=2 tr=0 a=WeyBsX0pwibosy+wZQfSmw==:117 a=WeyBsX0pwibosy+wZQfSmw==:17 a=N659UExz7-8A:10 a=NEAV23lmAAAA:8 a=mV9VRH-2AAAA:8 a=Bi6GNO_xAAAA:8 a=9I5xiGouAAAA:8 a=JOTLvX9Gg2MwjEvJ6fUA:9 a=pILNOxqGKmIA:10 a=upcPNqXXdgAA:10 a=chRs7B119AUA:10 a=Bn2pgwyD2vrAyMmN8A2t:22 a=BYZmueQyWBbq8FANvIHb:22 a=8dz3wjUUSoMOZLcCqgkG:22 a=ARFN2YZ7Uv8kHtb7LS-q:22 Subject: Re: CXF supports clients in other languages? Then provide samples! To: users@cxf.apache.org References: <1478402599353-5774606.post@n5.nabble.com> From: "J. Fiala" Message-ID: <9c489d21-6cc9-b16d-9103-99aae5407f6d@fwd.at> Date: Sun, 6 Nov 2016 22:44:10 +0100 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <1478402599353-5774606.post@n5.nabble.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit archived-at: Sun, 06 Nov 2016 21:44:22 -0000 Hi Philippe, CXF REST services actually support clients of any programming language capable of doing REST API calls. If you want to generate client code, pls check out Swagger-Codegen (http://github.com/swagger-api/swagger-codegen), it currently supports around 40 programming languages (client/server stubs), all the languages you listed are already there (JavaScript, Python, Ruby, Perl). It allows you to actually generate the client code in any language provided by Swagger contract. You can create the Swagger contract yourself or generate the contract dynamically using CXF SwaggerFeature (http://cxf.apache.org/docs/swagger2feature.html). If you want to generate the CXF application itself from an existing Swagger contract, you can take a look at a talk I did yesterday at DevFest Vienna (http://www.slideshare.net/johannes_fiala/how-to-generate-a-rest-application). Pls also try the Javascript generator there (Disclaimer: I added the basic generator for Javascript last year) and give feedback there. The Javascript calls are per se asynchronous & it supports AMD like RequireJs. If you want an overview of the Javascript features, you can watch a short talk I did at dotjs last year after creating the Javascript language generator: http://www.slideshare.net/johannes_fiala/rest-api-code-completion-for-javascript. Best regards, Johannes Am 06.11.2016 um 04:23 schrieb cp10000: > One of the fundamental characteristics and advantages of web-services is that > it allows different environments, different operating system, different > programming languages to interact. > > Does Apache CXF support clients in other other languages (especially dynamic > languages like JavaScript, Python, Ruby, Perl,...)? > > The answer to that question is not clearly stated anywhere in CXF > documentation. If CXF supports clients in other languages, then SAMPLE > SOURCE CODES SHOULD BE PROVIDED! It's not enough to say yes. > > We must separate the two cases of synchronous functions and asynchronous > functions. I would like to see sample code in JavaScript and Python for > call to synchronous web-service in CXF. This might be possible, but some > sample code would be helpful. > > I am particularly interested in seeing how a client in another computer > language than Java like JavaScript or Python can call an asynchronous > web-service in Apache CXF. Asynchronous web-service in CXF uses classes > like Future, AsyncHandler. These classes don't map directly to > classes in JavaScript and other languages. I am not aware of any > correspondence across computer languages. > > I have a strong feeling that a different language like JavaScript requires a > software framework in order to write a client that can call Apache CXF > web-services. Does such framework exist? If yes, it should be mentioned > in the documentation. If such framework does not exist, then Apache CXF > should write one for the major other programming languages (JavaScript, > Python, Ruby, Perl, ....etc) > > > > > -- > View this message in context: http://cxf.547215.n5.nabble.com/CXF-supports-clients-in-other-languages-Then-provide-samples-tp5774606.html > Sent from the cxf-user mailing list archive at Nabble.com. >