What is the difference between various web service implementations [closed] - web-services

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
I am new to web services programming. Recently I started learning web services but there I came across various specifications like:
REST
JAX-WS
JAX-RPC
etc.
Kindly update me that does these technologies occur in parallel or some are old versions and others are new versions of the same.
Also do I need to follow a hierarchy while learning these or I could start with any one randomly.
Thanks in advance

rest is a new way of implementing and describing web services via HTTP methods and URIs. Java helps with implementing such web services with jax-rs standard. REST services are often easy to interact with using browser, curl or any HTTP client. See StackOverflow API for an example.
jax-ws is similar to JAX-RS but provides standard way of implementing soap web services (older but also better recognizable in industry). SOAP is much more complex than REST, all messages are sent inside XML envelope, but the protocol is not restricted to HTTP and request-response.
jax-rpc is outdated and currently deprecated:
JAX-RPC 2.0 was renamed JAX-WS 2.0

REST: Representational State Transfer (REST) is a style of software architecture for distributed systems such as the World Wide Web.
http://en.wikipedia.org/wiki/Representational_state_transfer
Java API for XML Web Services (JAX-WS), is a set of APIs for creating web services in XML format (SOAP) mkyong.com/tutorials/jax-ws-tutorials/
JAX-RPC: Java APIs for XML-based Remote Procedure Call (JAX-RPC)
http://www.ibm.com/developerworks/library/ws-jaxrpc1/
As you notice from above descriptions, first one is a architecture and the rest are Jaa APIs.
You may start with REST then based on your requirement choose the API.

Related

Difference in Rest API / Web Service / Web API [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 1 year ago.
Improve this question
I have read all over the internet up and down about the differences in these three things and to me the waters seem incredibly muddy. I'm curious if anyone has any very clear way of explaining or identifying the differences between these three categories. Examples would be helpful.
I can read the differences all day, but nothing is computing with me. A Web Service and a Web API both do the same thing, I don't get it, and a REST API is just a type of Web API so how are these 3 different things?
A Web Service is a way to expose a system functionality in a machine-readable way over HTTP. The popular formats are SOAP, JSON or other XML schemas, but anything both sides understand will do.
A REST API is one architecture to design a Web Service, where resources are identified by URLs, and actions on them are identified by HTTP VERBS (GET, POST, DELETE, PUT etc.)
Web API is the Microsoft offering to implement a Web Service, REST or other. SOAP is not supported out of the box in Web API, but can be implemented.

Authenticating an External Restful Web-service from UI5/Fiori application [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
We have a requirement to consume a External RESTful web service from UI5 application. We need to develop a complete Fiori app without using ODATA service published in gateway.
Kindly help me out in authenticating an external web service. Will this requirement is feasible to implement when considering the front end roles and back end roles?
It will be more helpful for me if you share the code snippet for performing/consuming CRUD operations on external services from UI5 application including authentication.
Regards
Phani Poorna
The authentication you are looking for is not something that you should build into your app, but should be provided by the infrastructure your application is running on. Your ID provider (e.g. R/3 or Active Directory), in which you login to, should provide your browser with the necessary tokens or cookies. The respective sub-systems should in turn decide to give you access based on the cookies, tokens or certificates that you bring along.
A bit like this:
Many Fiori apps are running on the same R/3 environment as the user logs into. As this is the same system, it is trusted by default. This is why you don't have to do much to get a decent response from your service. However, if you want to connect to an external system, you will have to put some IDP plumbing in place. This usually involves things such as establishing a trust between de IDP and the external service.
As mentioned, authorisation should not be part of your app, hence no code samples in this answer. I hope answer provides you with enough pointers to find a solution for your particular situation. This is a tough topic though, read up on it (there's lot of info on SCN and the help-section) and don't be shy to ask for help from a basis consultant if necessary.
Also, please don't step into the pitfall of building your own authentication (e.g. basic authentication or oAuth), as it is insecure by default. The reason for this is because your Javascript, including embedded algorithms and tokens are readable by anyone the has access to the app.

Difference between Web Services and Web API [duplicate]

This question already has answers here:
What is the difference between a web API and a web service?
(13 answers)
Closed 6 years ago.
I have already gone through to the couple of tutorials to find the answer of this question but I did not find out the exact one. Everyone discusses about the api which we generally use with our project as a dependency but I always ask this question in context of web only.
What do you think about it?
Is there any difference between these two terms : Web Services and Web API
ya definitely there is difference between both of this frameworks.
In .net web services are built using wcf framework and web api are built using webapi framework.
If you are beginner i would say that web api is nothing but advanced and well developed form of web services.
web api are built as they can serve any type of devices in any format(content-type) of data.
Actually webapi vs web service is such concept that is difficult to explain but very easier to understand by doing some mock labs or experiments.

What is the difference between API and Webservice? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
can anybody give me some example?
A web service will expose an API.
Not all APIs are web services - any library will have an API.
APIs are the public interface of a piece of code - it is what you can call from within your code. It may be a web service, but it could also be a JavaScript library, a compiled library for your platform (say .NET assembly, java JAR, a PE DLL and more).
API is more of an abstract concept it is a programatic interface for your application it can be implemented in veraity of methods and technologies. Webservice is a spesific implemenation of such concept that using SOAP and HTTP technologies.
API is an acronym that stands for Application Programming Interface, as such it can be used to describe any piece of software you can use inside another software to develop an application or part of it. As an example the library/module/classes that allow you to open a file and read its contents is an API: you don't know how it works but you can use it into your software to achieve a possible complicate goal.
A web service is usually a remote piece of software capable of responding to web requests which provides some sort of functionality. Usually the word is used to indicate SOAP web services, but a RESTful application is a web service as well. In a broader sense of the word any web site is a web service as they provide a service over the web, but usually we do not consider them in that category because we refer to machine-to-machine interactions.
Now, if you consider that a web service can be used by your application to deliver part of your application logic then a web service IS an API.
They are same thing, Web Service is a specific type of API that is accessed over the web.
Facebook - offers a Web service / API
Twitter - offers a Web service / API
Windows - offers an API
An "Application Programming Interface" was originally used to describe the interface offered by system software(Windows) to be used by application programs (word, Microsoft paint etc...). The term API has since then evolved to encompass pretty much any software interface.
A web service is a software interface that is accessed over the web.
IMO API's that are accessed over the web should only be called Web Services, However the masses have started calling them API's - so that is what it is.
I wrote more about API's here: http://www.woodstitch.com/resources/what-is-an-api.php

what is API web services, how do you create them and why? [closed]

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
what is the purpose of web services?
i mean isn't all web applications a web service ?
also why do people create API web services? is it to let developer's use the website's functions? kinda like facebook and youtube ?
is it possible to make a API for web service where you can use C++ or VB to use the functions? therefore, someone could make a desktop application based on your web application's API ?
how do you create a web service API and a web service ?
what is the purpose of web services?
Allow the easy consumption of a service using web technologies? I mean, you can potentially code your application to do what the browser does ( that's how many applications for stackoverflow have been done in the past )
The problems are:
it is much harder than using an API
Since there is no API, changes in the website do crash your application ( while responsible API's will allow you to use your old version )
i mean isn't all web applications a web service ?
Not at all. A web app is an specific application designed to be used by a webbrowser ( firefox, chrome, etc ) While a webservice is meant to be consumed by other application.
You can consume a webservice in pretty much any programming language out there.
also why do people create API web services? is it to let developer's use the website's functions? kinda like facebook and youtube ?
Not the website functionality but to allow them to create own applications that use some functionality of that website.
For instance YouTube allow you to upload videos with it's API, otherwise you'll have to "simultate" the HTTP post which can be problematic.
That way, some tools offer the capability of "uploading" your video directly from the app.
is it possible to make a API for web service where you can use C++ or VB to use the functions?
That's the point, among other programming languages.
therefore, someone could make a desktop application based on your web application's API ?
Exactly!!!
Here's an example of the Object-C application I use for Twitter ( tweetie http://www.atebits.com/tweetie-mac/ )
(source: cachefly.net)
how do you create a web service API and a web service ?*
It is not much different from creating a API for an internal fremework/product/library.
You have to define what are you going to offer ( your public interface, your services that is )
Create a list of in/out parameters and interchange formats ( XML, json, text/plain, YAML, whatever )
And finally provide and endpoint in the web ( or why not intranet )
Webservices could are harder to control than regular APIs, you have to check security concerns, work load etc.
To see a working API refer to that mentioned by Nathan here
There are basically two different types of webservices, one that is SOAP-based and the other is REST-based.
Either can be accessed by desktop applications. I have written applications, such as screensavers, that will interact with the server through both of these types of webservices.
An API is useful so that people can write applications, as you mentioned, to use these services, as, without applications using them, these webservices are pretty useless.
A SOAP-based webservice is basically just a web application that sends and receives using an xml message format that follows a standard.
A REST-based webservice is the cgi-based application that is similar to using an html form element, generally using GET, but, if you are doing anything that can be destructive, or change databases, you will want to use POST.
You can write applications using these APIs in any language, which is the advantage, as you can then choose which language is best for the server-side, and that has no impact on what you do on the client-side.
How to create a webservice will depend on which of the two main types you want to create, and which language you choose to use.
A web service is a type of program running on a web server built especially for other programs to use, by submitting information requests to it in a particular format (usually some information wrapped in XML).
The API part (Application Programming Interface) is usually a class or set of classes that have the code that knows how to format the information to make requests from the Web Service - so that your program only needs to make the usual function calls to the API classes.
It simplifies your use of the web service.
Here is an example of how to make one, and use it for .NET languages: http://www.codeproject.com/KB/XML/BeginnerWebService.aspx
Any program that uses the web for its interface is a web application, like this site or Facebook.
An Application Service Provider is a company that helps you write web apps (http://en.wikipedia.org/wiki/Application_service_provider) or provide other services.
Normally a API is developed to create program that interact with the site, like the Twitter API, that you can use Twitter functions in a program.
If you ever developed applications that rely on libraries or dlls in terms of windows programming. Think of a web service as a dll hosted on a web server that has a direct URL to it.
So your application or website can read the data exposed from the URL that you can use as function calls.
Web services transmits data via xml, once the language you write your application in can read xml, you can write it to make calls to the web service, that is passing parameters and the function name to the service, then if expecting a return value, your application reads the data from xml.