Over 500 ASP.NET 3.5 Interview Questions with Answers of DOT NET including ASP.NET,dotnet interview questions,Visual stdio 2008,download free e-book.
Showing posts with label Web Service. Show all posts
Showing posts with label Web Service. Show all posts
What are the consideration in deciding to use .NET Remoting or ASP.NET Web Services?
Remoting is a more efficient communication exchange when you can control both ends of the application involved in the communication process. Web Services provide an open-protocol-based exchange of informaion. Web Services are best when you need to communicate with an external organization or another (non-.NET) technology.
Can you give an example of when it would be appropriate to use a web service as opposed to a non-serviced .NET component?
When to use Web Service:
1. Communicating through a Firewall When building a distributed application with 100s/1000s of users spread over multiple locations, there is always the problem of communicating between client and server because of firewalls and proxy servers. Exposing your middle tier components as Web Services and invoking the directly from a Windows UI is a very valid option.
2. Application Integration When integrating applications written in various languages and running on disparate systems. Or even applications running on the same platform that have been written by separate vendors.
3. Business-to-Business Integration This is an enabler for B2B intergtation which allows one to expose vital business processes to authorized supplier and customers. An example would be exposing electronic ordering and invoicing, allowing customers to send you purchase orders and suppliers to send you invoices electronically.
4. Software Reuse This takes place at multiple levels. Code Reuse at the Source code level or binary componet-based resuse. The limiting factor here is that you can reuse the code but not the data behind it. Webservice overcome this limitation. A scenario could be when you are building an app that aggregates the functionality of serveral other Applicatons. Each of these functions could be performed by individual apps, but there is value in perhaps combining the the multiple apps to present a unifiend view in a Portal or Intranet.
When not to use Web Services:
1. Single machine Applicatons When the apps are running on the same machine and need to communicate with each other use a native API. You also have the options of using component technologies such as COM or .NET Componets as there is very little overhead.
2. Homogeneous Applications on a LAN If you have Win32 or Winforms apps that want to communicate to their server counterpart. It is much more efficient to use DCOM in the case of Win32 apps and .NET Remoting in the case of .NET Apps.
1. Communicating through a Firewall When building a distributed application with 100s/1000s of users spread over multiple locations, there is always the problem of communicating between client and server because of firewalls and proxy servers. Exposing your middle tier components as Web Services and invoking the directly from a Windows UI is a very valid option.
2. Application Integration When integrating applications written in various languages and running on disparate systems. Or even applications running on the same platform that have been written by separate vendors.
3. Business-to-Business Integration This is an enabler for B2B intergtation which allows one to expose vital business processes to authorized supplier and customers. An example would be exposing electronic ordering and invoicing, allowing customers to send you purchase orders and suppliers to send you invoices electronically.
4. Software Reuse This takes place at multiple levels. Code Reuse at the Source code level or binary componet-based resuse. The limiting factor here is that you can reuse the code but not the data behind it. Webservice overcome this limitation. A scenario could be when you are building an app that aggregates the functionality of serveral other Applicatons. Each of these functions could be performed by individual apps, but there is value in perhaps combining the the multiple apps to present a unifiend view in a Portal or Intranet.
When not to use Web Services:
1. Single machine Applicatons When the apps are running on the same machine and need to communicate with each other use a native API. You also have the options of using component technologies such as COM or .NET Componets as there is very little overhead.
2. Homogeneous Applications on a LAN If you have Win32 or Winforms apps that want to communicate to their server counterpart. It is much more efficient to use DCOM in the case of Win32 apps and .NET Remoting in the case of .NET Apps.
Web Service - FAQ
WEB SERVICE - Frequently Asked Question
1. What is SOAP?
Simple Object Access Protocol (SOAP) is a lightweight protocol for exchange of information in a decentralized, distributed environment. It's an industry-standard message format that enables message-based communications for Web services.
2. What is UDDI?
Universal Discovery Description and Integration is like the "Yellow Pages" of Web services. A UDDI directory entry is an XML file that describes a business and the services it offers. There are three parts to an entry in the UDDI directory. The "white pages" describe the company offering the service, like, name, address, contacts, etc. The "yellow pages" include industrial categories based on standard taxonomies the Standard Industrial Classification. The "green pages" describe the interface to the service in enough detail for someone to write an application to use the Web service.
3. What is WSDL?
Web Service Description Language (WSDL) defines an XML grammar for describing web services. This description includes details such as where to find the web service (its URL), what methods and properties that service supports, the data types and the protocols used to communicate with the service.
4. Describe Web Service (XML Web Service)?
A Web Service (XML Web Service) is a unit of code that can be activated using HTTP requests. Stated another way, a Web Service is an application component that can be remotely callable using standard Internet Protocols such as HTTP and XML. A major advantage of the Web services architecture is, it allows programs written in different languages on different platforms to communicate with each other in a standards-based way. Simply said, a Web service is a software service exposed on the Web through SOAP, described with a WSDL file and registered in UDDI.
5. Give examples of a Web Service?
o Information sources like stock quotes, weather forecasts, sports scores etc that could easily incorporate into applications
o Services that provide commonly needed functionality for other services. Example, user authentication, usage billing etc
o Services that integrate a business system with other partners
6. What is SOAP Protocol message contains?
A SOAP Protocol message contains four parts:
· An envelope
· Encoding Rules
· RPC representation (Convention)
· Protocol binding (optional)
an envelop that defines a framework for describing what is in a message and how to process it, a set of encoding rules for expressing instances of application-defined data types and a convention for representing remote procedure calls (RPC). In protocol binding, almost all SOAP implementations support it as it's the only standardized protocol for SOAP. The HTTP binding is optional.
Subscribe to:
Posts (Atom)