Creating a RESTful Web Service for Microsoft SQL Server Patrick Mundy, Managing Partner Albert Factora, Managing Partner.

Slides:



Advertisements
Similar presentations
Other Web Application Development Technologies. PHP.
Advertisements

Internet Information Services 7.0 and Internet Information Services 7.5 Infrastructure Planning and Design Published: June 2008 Updated: November 2011.
REST - Representational State Transfer
Representational State Transfer (REST): Representing Information in Web 2.0 Applications this is the presentation Emilio F Zegarra CS 2650.
Building and using REST information services Rion Dooley.
REST (Representational State Transfer)
Background REST (Representational State Transfer) What does it mean to be RESTful? Why REST? WCF How does WCF support REST? What are the pieces we need.
Eric J. Oszakiewski MCTS: SharePoint Application Development SharePoint Configuration.
DB Relay An Introduction. INSPIRATION Database access is WAY TOO HARD The crux.
SSRS 2008 Architecture Improvements Scale-out SSRS 2008 Report Engine Scalability Improvements.
Small Business Server and Windows SharePoint Services David Overton
Using Evernote and Google Docs in your web or mobile application (and potentially Dropbox and Skydrive) By Peter Messenger Senior Developer – Triple Point.
INTRODUCTION TO ASP.NET MVC AND EXAMPLE WALKTHROUGH RAJAT ARYA EFECS - OIM DAWG – 4/21/2009 ASP.NET MVC.
Intro to SharePoint 2013 Architecture Liam Cleary.
AHRT: The Automated Human Resources Tool BY Roi Ceren Muthukumaran Chandrasekaran.
Running PHP on Windows Server 2008 and IIS 7 Rob Cameron Developer Evangelist, Communications Sector Microsoft.
1 Configuring Internet- related services (April 22, 2015) © Abdou Illia, Spring 2015.
PHP on Windows Improvements in PHP-Microsoft Interoperability PHP World Kongress Munich, Germany November 9, 2010.
Creating WordPress Websites. Creating a site on your computer Local server Local WordPress installation Setting Up Dreamweaver.
DT228/3 Web Development Databases. Database Almost all web application on the net access a database e.g. shopping sites, message boards, search engines.
Peoplesoft: Building and Consuming Web Services
Getting Started with Web Servers, PHP, and the Eclipse PDT Appendix I DAVID M. KROENKE and DAVID J. AUER DATABASE CONCEPTS, 6 th Edition.
PHP Scripting Language. Introduction “PHP” is an acronym for “PHP: Hypertext Preprocessor.” It is an interpreted, server-side scripting language. Originally.
Computer Science 101 Web Access to Databases Overview of Web Access to Databases.
Sharepoint Portal Server Basics. Introduction Sharepoint server belongs to Microsoft family of servers Integrated suite of server capabilities Hosted.
 2000 Deitel & Associates, Inc. All rights reserved. Chapter 24 – Web Servers (PWS, IIS, Apache, Jigsaw) Outline 24.1Introduction 24.2Microsoft Personal.
M. Taimoor Khan * Java Server Pages (JSP) is a server-side programming technology that enables the creation of dynamic,
REST.  REST is an acronym standing for Representational State Transfer  A software architecture style for building scalable web services  Typically,
Microsoft Visual Studio 2010 Muhammad Zubair MS (FAST-NU) Experience: 5+ Years Contact:- Cell#:
Standalone Java Application vs. Java Web Application
Learningcomputer.com SQL Server 2008 Configuration Manager.
Microsoft Visual Studio 2010 Muhammad Zubair MS (FAST-NU) Experience: 5+ Years Contact:- Cell#:
HTML. Principle of Programming  Interface with PC 2 English Japanese Chinese Machine Code Compiler / Interpreter C++ Perl Assembler Machine Code.
Tutorial 10 by Sam ine1020 Introduction to Internet Engineering 1 Database & Server-side Scripting Tutorial 10.
PHP on Windows Improvements in PHP-Microsoft Interoperability Brian Swan PHP Developer Outreach,
Introducing ASP.NET 2.0. Internet Technologies WWW Architecture Web Server Client Server Request Response Network HTTP TCP/IP PC/Mac/Unix + Browser (IE,
Dynamic web content HTTP and HTML: Berners-Lee’s Basics.
1 MSCS 237 Overview of web technologies (A specific type of distributed systems)
What's New in Kinetic Calendar 2.0 Jack Boespflug Kinetic Data.
Copyright © 2006 Pilothouse Consulting Inc. All rights reserved. Search Overview Search Features: WSS and Office Search Architecture Content Sources and.
RESTful Web Services What is RESTful?
ICM – API Server Gary Ratcliffe. 2 Agenda Webinar Programme API Server Overview JSON-RPC iCM API Service API Server and Forms New services under.
ASP-2-1 SERVER AND CLIENT SIDE SCRITPING Colorado Technical University IT420 Tim Peterson.
AJAX and REST. Slide 2 What is AJAX? It’s an acronym for Asynchronous JavaScript and XML Although requests need not be asynchronous It’s not really a.
2 Microsoft Confidential3 The Microsoft Web Platform is the software of choice when building web solutions or applications for your business, large.
David M. Kroenke and David J. Auer Database Processing Fundamentals, Design, and Implementation Appendix I: Getting Started with Web Servers, PHP and the.
PHP on Windows server. About PHP history, usage [ 3 ] Basics about PHP Open, free, object oriented (recently added namespaces), procedural, type free.
Representational State Transfer COMP6017 Topics on Web Services Dr Nicholas Gibbins –
REST API Design. Application API API = Application Programming Interface APIs expose functionality of an application or service that exists independently.
Integrating ArcSight with Enterprise Ticketing Systems
Integrating ArcSight with Enterprise Ticketing Systems
Introduction to Dynamic Web Programming
The Client-Server Model
Node.js Express Web Applications
Node.js Express Web Services
AJAX and REST.
An introduction to REST for SharePoint 2013
Jon Galloway | Tech Evangelist Christopher Harrison | Head Geek
Representational State Transfer
Ashish Pandit IT Architect, Middleware & Integration Services
WEB API.
Windows Internals Brown-Bag Seminar Chapter 1 – Concepts and Tools
Web Browser server client 3-Tier Architecture Apache web server PHP
Configuring Internet-related services
$, $$, $$$ API testing Edition
Client-Server Model: Requesting a Web Page
TN19-TCI: Integration and API management using TIBCO Cloud™ Integration
WCF Data Services and Silverlight
Chengyu Sun California State University, Los Angeles
Web Application Development Using PHP
Presentation transcript:

Creating a RESTful Web Service for Microsoft SQL Server Patrick Mundy, Managing Partner Albert Factora, Managing Partner

About The Presenters Albert Factora RocketWeave co-founder Angry Lumpia inventor Patrick Mundy RocketWeave co-founder Kick-ass drummer

About RocketWeave

Our mission: ensure that your business systems are primed for a successful take-off!

Problem Statement Web Service MSSQL Database Server ?? PHP / IIS ONE AWS Instance

Common Alternative Platforms Spin up a virtual LAMP stack Spin up a virtual WAMP stack Others…? This presentation presumes a Microsoft shop where MS SQL and IIS are the supported platforms…

Agenda Background RESTful architecture overview, JSON overview, Requirements Preparation Installation Process, Configuration Issues Demo Review SQL Data, PHP File architecture Fire off some GET, POST calls Observe behavior Conclusion It can be done App Design thoughts…

Background: RESTful principles for web services Architectural Properties Performance Scalability Simplicity of interfaces Modifiability of components Visibility of communication between components Portability of components Reliability Made from: Components, Connectors, and Data “Representational State Transfer”

Background: RESTful principles for web services HATEOAS Hypertext As The Engine Of Application State ENDPOINTS Collections / Methods Elements / Methods

Background: RESTful principles for web services Hypertext As The Engine Of Application State Client context not stored on Server Client initiates state-change via request to Server PUT and DELETE are idempotent GET is nullipotent (i.e. safe method)

RESTful Design of the Demo /Categories GET – returns list of Members of Category Collection POST – (with data) creates a new Member of the Category Collection /Categories/:catID GET – returns data for just the selected Member /Categories/Level/:lvl GET – returns Members of “lvl” Level Collection

Transmittal Attributes Method GET PUT POST DELETE Optional: data to work with (JSON- encoded) $.post(' { username:'test1abc', password:'pwd123', });

Background: JSON Review “Javascript Object Notation”: Text-Based Data Interchange Format { Attribute1 / Value Attribute2 / Value } Address Attribute’s Value is a nested JSON object phoneNumbers Attribute’s Value is a LIST of two more small JSON objects

Background: System Architecture MSSQL Database Server PHP executable PHP index file PHP include files PHP extension files Windows 2008 R2 DataCenter 7.5 Gig memory 64 bit OS IIS 7 PHP VC9 binary, thread safe v ts

Background: PHP File Architecture php.ini php extension files (.dlls) (including mssql support files) index.php routes.php sql.php db.php

Preparation: Installation Process Overview Assumptions: SQL Server and IIS are installed 1.Install PHP 2.Install SQL Server PHP extension 3.Configure php.ini files for IIS 4.Configure IIS for PHP 5.Install SQL Server 2012 Client 6.Build, test DB Connection logic 7.Build t-SQL creation logic 8.Build logic to parse “payload” of GET/PUT/POST

Preparation: Install PHP Determine the version of PHP to use, based on IIS version Download binaries Unzip You may need to install C++ runtime

Preparation: Install MSSQL Drivers for PHP PHP page about this: Microsoft page about this: Download drivers (most likely SQLSRV 3.0) Place them in the IIS Extensions folder Decide which one you will have IIS load: ing-sql-server-databases-from-php.aspx ing-sql-server-databases-from-php.aspx

Preparation: Configure php.ini Instructions are on second half of PHP install page: Stipulate extension file location Stipulate which extensions to use (especially correct MSSQL extension) Set up logging and log output CGI and FastCGI settings

Preparation: Configure IIS for PHP PHP page about this: Enable FastCGI support in IIS Configure IIS to process PHP requests php.ini settings taken care of in prior slide Set up “handler mapping” for PHP inside IIS Manager Set up impersonation and file access Set up IIS to use “index.php” as default document

Preparation: Install MSSQL 2012 Client And from there to: us/download/confirmation.aspx?id= us/download/confirmation.aspx?id=29065 It’s about halfway down the page AFTER you expand the “installation instructions.” Most of us want x64 version

Demo: Review SQL Data, Procedures Select * from CategoriesExec usp_ShowLevelMembers 2 Exec usp_NewCategory

Demo: Review PHP files \PHP\php.ini \inetpub\wwwroot\index.php \inetpub\wwwroot\restful_routes.php \inetpub\wwwroot\restful_sql.php \inetpub\wwwroot\restful_db.php

Demo: Execute Some GETs /Categories -- shows list of Members of Category Collection /Categories/:catID -- shows data for just the selected Member /Categories/Level/:lvl -- shows Members of “lvl” Level Collection

Demo: Execute a POST /Categories {parentID=1, catName = ‘Coffee Shops’}

Recap Background RESTful architecture overview, JSON overview, Requirements Preparation Installation Process, Configuration Issues Demo Review SQL Data, PHP File architecture Fire off some GET, POST calls Observe behavior

Conclusions

(415)