Free Essay

Web Services

In:

Submitted By rohitn
Words 707
Pages 3
What is an HTTP Endpoint in Sql Server? Well, it is a way to create a usable interface using HTTP or TCP for SOAP, T-Sql, Service
Brokering and a few other things. I’m just going to tell you, quick and simple, about creating a web service to return data, although you can return scalar values, messages and errors too. The results returned are serialized into Xml. If you have Windows
2003, you don’t have to have IIS installed. Sql server will use the http.sys module in the Win2K3 kernel.
So lets look at creating a usable web service from within Sql Server. Lets start with creating a stored procedure.
Create stored procedure to return list of employees use adventureworks go create procedure dbo.GetEmployees
As
select e.employeeid, e.title, c.FirstName + ‘ ‘ + c.Lastname As Fullname from HumanResources.employee e inner join person.contact c on e.contactid = c.contactid go Now, lets create our sql server web service, known as an HTTP ENDPOINT.
The Sql 2005 code to create the HTTP ENDPOINT use adventureworks go CREATE ENDPOINT GetEmployees STATE = STARTED
AS HTTP
(
PATH = ‘/Employee’, AUTHENTICATION = (INTEGRATED), PORTS = (CLEAR), SITE = ‘localhost’
)
FOR SOAP
(
WEBMETHOD ‘EmployeeList’ (NAME=’AdventureWorks.dbo.GetEmployees’), BATCHES = DISABLED, WSDL = DEFAULT, DATABASE = ‘AdventureWorks’, NAMESPACE = ‘http://AdventureWorks/Employee’
)
go
There we go. We now have a web service! You access and use this endpoint the same way you would any other web service. You can create multiple WEBMETHODs in a single endpoint, just seperate them with commas in the FOR SOAP statement.
Here are the values you can use for the “STATE” argument: • STARTED—listening and responding • DISABLED—neither listening nor responding • STOPPED—listening, but returns errors to client requests
Here are the “AS HTTP” arguments you can use: • Path – The virtual URL path on the server where the Web service will reside • Authentication o INTEGRATED – most secure. It will try to use Kerberos-based authentication if possible (otherwise, NTLM). o DIGEST is not as secure as INTEGRATED. You should use it only if INTEGRATED authentication is not possible. o BASIC authentication is the least secure. You should use it only if you can’t implement either INTEGRATED or DIGEST authentication methods. BASIC requires SSL as the Port value. • Ports – CLEAR (HTTP – port 80 by default) SSL (HTTPS – port 443 by default) • Site – The name of the server on which the Web service is running
So, now lets put our endpoint to work. First, create a new windows application project, and add a web reference to it. When you browse for the web service, it won’t be discovered automatically. You have to type in the url and click “go”.
The url in this case is http://localhost/Employee?wsdl.
You’ll see the EmployeeList method come up in the list, just like using any other web service. Go ahead and add the service and rename it to whatever. I called mine “adventureWorksService”.
Now we just add code like using any other webservice. I’ve added a button to click to populate the listbox on my form. So here it is:
A VB.net form that loads the results of the stored procedure into a list box.
Public Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click ‘ Create a new instance of the web service Dim employeesProxy As adventureWorksService.GetEmployees = New adventureWorksService.GetEmployees ‘ You have to pass in credentials to authenticate yourself to use the service. We are just going to use ‘ the same credentials we have logged into our computer as. employeesProxy.Credentials = System.Net.CredentialCache.DefaultCredentials ‘ The result of a SELECT statement via an endpoint can be converted to a DataSet Dim ds As System.Data.DataSet = DirectCast(employeesProxy.EmployeeList, DataSet) ListBox1.DataSource = ds.Tables(0) ListBox1.DisplayMember = “FullName” ListBox1.ValueMember = “EmployeeId” End Sub
End Class
I am having problems with my Adobe Photoshop, so I don’t have any screenshots to show you. You’ll just have to trust me.
Here are the other return values from the endpoint: • Select statement – Convert to DataSet • Select statement FOR XML – Convert to XmlElement • Error or Message – WSDL SqlMessage • Output parameter – WSDL SqlParameter • Row count – WSDL SqlRowCount • RETURN statement – Convert to Int32
Tada! There you go! A web service straight from Sql Server!

Similar Documents

Free Essay

Web Services

...REFERENCES #1 “Web Services Glossary,” W3C Working Group Note 11 February 2004, Last retrieved from http://www.w3.org/TR/ws-gloss/ on 31 October2012 #1Rajat Kathuria, 2009, “India: The Impact of Mobile Phones”, Paper Number 9, Policy Paper Series Published by Vodafone Group ) #2ITU (2012), {http://www.itu.int/net/pressoffice/press_releases/2012/70.aspx} #3(World Bank Study, 2012) (http://www.worldbank.org/en/news/2012/07/17/mobile-phone-access-reaches-three-quarters-planets-population accessed on 1st November 2012) #5 Kushchu, I., Kuscu, M., H., 2004. From e-Government to m-Government: Facing the Inevitable. URL http://www.mgovernment.org/resurces/mgovlab_ikhk.pdf. (2009-03-15) Karunamurthy R, Khendek F, Glitho RH. A novel architecture for Web service composition, Journal of Network and Computer Applications 35 (2012) 787–802. Chen, G., & Kotz, D. (2000). A survey of context-aware mobile computing research. Dartmouth College. http://www.cs.dartmouth.edu/reports/TR2000-381.pdf Chen, H., Finin, T., & Joshi, A. (2003). An ontology for context-aware pervasive computing environments. Knowl. Eng. Rev. , 18 (3), 197--207. Chen, I. Y., Yang, S. J., & Zhang, J. (2006). Ubiquitous Provision of Context Aware Web Services. Proceedings of the IEEE international Conference on Services Computing (pp. 60-68). Washington: IEEE Computer Society. Layne, K. & J. Lee (2001) Developing fully functional E-government: A four stage model Government Information Quarterly...

Words: 300 - Pages: 2

Premium Essay

Pfch Web Services

...Patton-Fuller Community Hospital Request for Project (RFP) – Web Services CMGT/554 IT Infrastructure May 27, 2013 Matt Mancani In an age of technological advances, more people access the Internet to conduct research, perform banking and other financial transactions, participate in education, search for real-estate, and purchase consumer goods, among other things. Today, people can perform actions from playing online games to searching for love on the Internet. It is customary for people to have more “friends” online today than they have on-ground. Social networking has taken the Internet to new highs and generations are accustomed to living full lives through the World Wide Web. Therefore, it goes without reason that people would expect to access vital services such as healthcare online as well. Learning Team C has been requested by the executive staff at Patton-Fuller Community Hospital (PFCH) to determine the feasibility of PFCH becoming a state-of-the art healthcare provider with an online presence. This paper will determine what PFCH needs to do to achieve this status by providing interactive web services to its vendors, suppliers, clinicians and patients. This analysis will answer the questions of what modifications/implementations must be achieved to provide up-to-date, accurate information to staff, medical personnel and patients; what interactivity would allow patients the ability to being able to access pertinent...

Words: 1196 - Pages: 5

Free Essay

Estudo de Transações Distribuídas Em Web Services Utilizando O Padrão Ws-Caf

...Web Services são componentes auto-descritos, auto-contidos e que têm baixo fator de acoplamento com outros web-services. Eles têm as seguintes características principais: acessibilidade via web, exposição por interface em XML, habilidade de serem localizadas por um registro único, e uso de mensagens em XML sob protocolos padrão de Internet. Apesar de todas as facilidades e infra-estrutura para o desenvolvimento e a integração de aplicações, os Web Services não provêm os serviços sob a perspectiva de uma transação distribuída. Em 28 de julho de 2003, as empresas Arjuna Technologies Limited, Fujitsu Software, IONA Technologies PLC, Oracle Corp e Sun Microsystems anunciaram a publicação do Web Services Composite Applications Framework (WS-CAF), que é na verdade um conjunto de três especificações: Web Service Context (WS-CTX), Web Service Coordination Framework (WS-CF) e Web Service Transaction Management (WS-TXM). O WS-CAF foi desenvolvido justamente para resolver os problemas relacionados com transações distribuídas (quando múltiplos Web Services são utilizados em combinação), de modo a suportar compartilhamento de informações e processamento de transações. O WS-CAF não requer a implementação de um novo protocolo de transações, dado que pode usar qualquer protocolo em substituição ou adição aos protocolos neutros definidos no WS-TXM. A tendência é que o WS-CAF se torne um padrão reconhecido internacionalmente, levando a uma convergência no desenvolvimento de transações distribuídas...

Words: 362 - Pages: 2

Premium Essay

Nt1310 Unit 5 Essay

...Question 2: What are the foundations of J2EE API? In your answer include the main detail definitions, services, and specifications. J2EE API is used for developing and running enterprise software, including network and web services, and other large-scale, multi-tiered, scalable, reliable, and secure network applications. Specifications : RMI: Distributed Object Communication allows objects to access data and invoke methods on remote objects(non-local memory objects), this process is known as remote method invocation Java Mail: It allows an application component to send Internet mail (notifications. The JavaMail API has two parts: • an application-level interface used by the application components to send mail, and • a service provider interface used at the Java EE SPI level....

Words: 523 - Pages: 3

Premium Essay

Email & Web Services Final Exam

...!!FINAL EXAM!! The MX DNS record is used to indicate the e-mail server for a particular domain to which e-mail should be forwarded. The GC (global catalog) is a database of all object names in the forest and aids in locating objects in the AD. Virtual Directory enable you to use a Web site to publish files located anywhere on the network? Server Manager is an MMC console that provides a selection of the most commonly used Windows Server 2008 management tools. ESMTP is and improved version of the standard e-mail protocol that provides greater support for embedded graphics and attachments in e-mail. The Add Roles Wizard provides roles that fall into three basic categories: Directory Services, Application Services, and Infrastructure Services? All applications that you add to the Default Web Site on the server use Default App Pool. Although mailbox users connect to a single public folder database by default, they will be able to see and access all of the public folders within the Exchange organization using Public Folder Referrals. The client must use the prefix https:// in its URL to connect to an IIS7 server using SSL. Digital certificates are issued by internal or external resources called? Certification Authority Domain names that contain the name of the host computer are called Fully Qualified Domain Name. Edge role servers must use ADAM to periodically obtain AD and Exchange information using the Edge-Sync protocol from a server that hosts...

Words: 1108 - Pages: 5

Free Essay

Trends in Dicos

...DICOM publication in an XML format The publication of the DICOM standard in an XML format he idea is that by having the specification in XML developers will be able to access all of the tables, all of the information object definitions, and the vocabulary, and use this in their products. This would enable thinks like test tools, code generators, documentation generators - there's wide variety of things that they expect to facilitate by creating an XML specification. FHIR and RESTful DICOM New users with new use cases want to leverage the technology they have - so if mobile devices support REST, DICOM has to create a RESTful protocol to allow for access to imaging objects by such devices. DICOM tries to ensure that the evolutionary trends still maintain the value of any existing images in the radiology department. As such these new protocols are viewed as layers on top of DICOM. There'll be a mixture of the DICOM native protocol and webservices for some of these new use cases. Radiation dosage monitoring DICOM also has relationships with the IEC related to the issue of radiation safety. Regulatory agencies have an interest in collecting information related to radiation/patient safety issues. Jointly with the IEC DICOM has created the information stuctures to capture patient radiation dose information, initially for simple X-Rays, for CT, and currently they're working on collecting radiation data for radiopharmaceuticals. This is tricky, because the radiopharmaceutical...

Words: 266 - Pages: 2

Free Essay

Ericsson the Great

...has capitalized it profits and jet-streamed its businesses using Amazon Web Services. Let us take a look at the scalability, dependability, manageability, and adaptability of Amazon EC2, Amazon S3, and RightScale along with the security concerns and cost issues of cloud-based services via the eyes of Amazon Web Services. Ericsson the Great The main goal for all companies is to increase profits as much as possible by attracting new customers while maintaining consumer satisfaction on all levels. But before money can be made and collected, companies must first have a game plan to construct, provide, maintain, and secure goods and services consumers really want and need. That is just the idea that Ericsson had when they made the decision to use Amazon Web Services (AWS), to maximize their vision while reducing their cost and overhead. Ericsson has gained numerous benefits from the strategy, reliability, and security of Amazon services. Amazon Web Services can be characterized by a collection of computing services bundled together to make up a cloud computing platform, in which services are offered over the internet via Amazon.com. But that is just the beginning because with power players like Ericsson on board, the value of the cloud illuminates. Ericsson can be described as one of the world’s leading providers with creative technology and innovative ideas that produce first class products and services. “Ericsson is the leader in 2G, 3G, and 4G...

Words: 1439 - Pages: 6

Premium Essay

Coca Cola

...5. What exactly are Simple Storage Service (S3), Elastic Compute Cloud (EC2), Virtual Private Cloud(VPN between Amazon cloud and company's existing IT infrastructure), Flexible Payments Service (FPS), Amazon Mechanical Turk, Alexa Web Info Services, and Fulfillment Web Services (FWS)? Simple Storage Service (S3) = S3 is storage for the Internet. It is designed to make web-scale computing easier for developers. It provides a simple web services that can be used to store any data, any time, from anywhere as long as you are connected to the web. Elastic Compute Cloud (EC2) = Elastic Compute Cloud (EC2) is a web service that provides resizable compute capacity in the cloud. It is designed to make web-scale computing easier for developers. It provides you with complete control of your computing resources. Virtual Private Cloud = VPC is a secure and seamless bridge between a company’s existing IT infrastructure and the AWS cloud. VPC lets enterprises to connect their valid infrastructure to a set of isolates AWS compute resources through a Virtual Private Network (VPN) connection. Also, to expand their existing management capabilities such as security services, firewalls, and intrusion detection systems to include their AWS resources. Flexible Payments Service (FPS) = the first payments service designed from the ground up for developers. It is built on top of Amazon’s reliable and scalable payments infrastructure and provides developers with a convenient way to charge Amazon’s tens...

Words: 354 - Pages: 2

Free Essay

Shireesha Individual Assignment

...utilizing this kind of innovation, the already existing markets will be forced to modify their strategies to suit the new innovation and hence will result in those companies having to undergo a lot more changes to both try and crush the old technology with a more advanced one as well as to try and adapt this technology in their business successfully. Let us take the example of Cloud Computing which uses a network of remote servers hosted on the Internet to store, manage, and process data, and which does not require a local server or a personal computer that is currently being used. The initial entrant to disrupt the local server trend was Amazon through their Amazon Web Services. In 2006, Amazon Web Services (AWS) started to offer IT infrastructure services to businesses in the form of web services - now commonly known as cloud computing. Amazon is the company responsible for the innovation...

Words: 979 - Pages: 4

Premium Essay

Cloud Computing

...Overview of Amazon Web Services December 2010 Amazon Web Services Overview May 2010 Introduction Managing the unique and groundbreaking changes in both technology and business over the past decade has created an ongoing IT infrastructure challenge for many senior technology executives. Indeed, over the past 10 years, the typical business application architecture has evolved first from a desktop-centric installation, eventually to client/server solutions, and now most prominently to loosely coupled web services and service-oriented architectures (SOA). Each of these evolutionary steps has built upon the previous while adding new challenges, dimensions, and opportunities for IT organizations and their business partners. Recently, virtualization has become a prevalent and widely accepted way to reduce operating costs and increase the reliability of enterprise IT. In addition, concepts such as grid computing make possible a whole new class of analytics, data crunching, and business intelligence tasks that were previously cost- and time-prohibitive. Along with these technology changes there have also been fundamental changes in how markets work, with the speed of innovation and product introductions increasing at an unprecedented rate. Taken alongside the wide acceptance of Software as a Service (SaaS) offerings, all of these concepts have inspired the latest turn in the IT infrastructure challenge: cloud computing. Amazon Web Services (AWS) provides a flexible, cost-effective...

Words: 4330 - Pages: 18

Premium Essay

Bis 320 Week 5

...with varying number of steps. Some go for the eight step process while few prefer the seven step process. Another variation is the five step process which includes the following stages: System definition, Requirement analysis, Component design, Implementation and Maintenance. There is a subtle difference between a disaster and a threat. Heavy physical loss of computing machinery due to natural causes, assault or terrorist attacks come under the category of Disasters. Threats cover issues arising from human errors, malicious illegal acts and natural disasters. An instance of human error would be an unintentional or intentional shredding of data by employees. Events like a twister or flood beyond human control can disable all computing services indefinitely. With all these factors established, it is important to consider the steps to be taken in preparing for disasters ahead of development of plans (Kroenke, “Information Security Management,” 2012). The SDLC process which has been so strictly and exhaustively followed by Amazon can be used as a standard operating procedure for application development by other organizations. The first and foremost condition for being prepared in case of disasters is to locate facilities in geographical positions which are beyond natural and human attacks. Next important step is identification of systems and resources that are necessary to get the business rolling. Having a secondary backup...

Words: 2406 - Pages: 10

Premium Essay

Amazon.Con the Cloud

...information systems, and propose solution to improve the systems. Amazon.com: Welcome to the cloud Managing data efficiently is the key to success for any business or organization because data increases and changes exponentially. Successful companies such as Microsoft, Google, and Amazon manage their data using data warehouses and databases. Managing their data through those systems allows them to improve business knowledge, assist decision-making processes, and offer a better service to their customers. This essay will cover how Amazon uses information systems to support business processes, and the potential strengths and weaknesses of those information systems. Amazon.com. Inc. overview Founded in 1994 by Jeffrey P. Bezos, the company debuted on the Internet in 1995 and “quickly became the number one book-related site on the Web” Answer.com (n, d.) Considered a pioneer in e-business, Amazon.com quickly diversified its services and products. The company’s website offers a wide variety of books,...

Words: 1066 - Pages: 5

Premium Essay

Lt Amazon.Com® Evolution

...to create a global web-based computing platform. Over many years, Amazon.com gradually has situated the business as an aggressive technology company in the course of a sequence of services referred to as Amazon Web Services (AWS). These are services whereas Amazon rents parts of its back-end infrastructure to other IT groups and developers (New York Times, 2010) because 90% of it was not being used. Amazon.com offers a number of benefits such as cost-effectiveness, reliability, flexibility, and intellectual capacity. The aggressive AWS products in which Amazon highlights are Mechanical Turk, Simple Storage Service (S3) and Elastic Compute Cloud (EC2). Mechanical Turk is a marketplace which provides an on-demand workforce which necessitates human astuteness since there are various tasks in which human beings can complete more efficiently than central processing units. Amazon S3 permits businesses to store information on Amazon’s PC and “gives any developer the right to use to the identical high scalable, dependable, fast, economical information storage space infrastructure that Amazon uses to run its global network of websites” (Amazon Web Services, 2010). The EC2 allows developers inclusive control of computing resources while running within Amazon’s computing setting. Reference Amazon Web Services (2010). Amazon Elastic Compute Cloud (Amazon EC2). http://aws.amazon.com/ec2/ Amazon Web Services (2010). Amazon Simple...

Words: 274 - Pages: 2

Premium Essay

Cloud Computing

...years. AWS provides a massive global cloud infrastructure that allows you to quickly innovate, experiment and iterate. Instead of waiting weeks or months for hardware, you can instantly deploy new applications, instantly scale up as your workload grows, and instantly scale down based on demand. Whether you need one virtual server or thousands, whether you need them for a few hours or 24/7 AWS is a language and operating system agnostic platform. You choose the development platform or programming model that makes the most sense for your business. You can choose which services you use, one or several, and choose how you use them. This flexibility allows you to focus on innovation, not infrastructure., you still only pay for what you use. AWS is a secure, durable technology platform with industry-recognized certifications and audits: PCI DSS Level 1, ISO 27001, FISMA Moderate, HIPAA, and SAS 70 Type II. Our services and data centers have multiple layers of operational and physical security to ensure the integrity and safety of your data (About AWS, pg.1, 2012). Amazon Elastic...

Words: 1231 - Pages: 5

Free Essay

Cloud

...continues to be the world’s leader in providing telecom services of various types. The Ericsson organization offers infrastructure development, complete solutions and a variety of enterprise packages. To minimize costs and increase the profitability of the organization, Ericsson has opted to utilize cloud services from Rightscale and Amazon. Attributed to the many variables that are present when cloud computing, I desire to discuss the following items in greater detail during this paper: * Discuss how Ericsson benefited from Amazon Web Services (AWS) in terms of cost reduction, automated software updates, remote access, and on-demand availability. * Evaluate the scalability, dependability, manageability, and adaptability of Amazon Elastic Compute Cloud (Amazon EC2), Amazon Simple Storage Services (Amazon S3), and RightScale. * Examine the security concerns for cloud-based services and make suggestions to cope with these concerns. * Assess the possible scalability, reliability, and cost issues associated with cloud computing, and make suggestions to overcome each of these issues. Benefits from Amazon Web Services in terms of cost reduction, automated software updates, remote access, and on-demand availability. When examining the advantages of cloud computing, there are many rational reasons often revealed. Ericsson selected and decided to utilize the services provided by the Amazon Web Services (AWS) solution because of their “well known” reputation...

Words: 1371 - Pages: 6