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.