Introduction to ArcGIS Server Development Kevin Deege,, Rob Burke, Kelly Hutchins, and Sathya Prasad ESRI Developer Summit 2008 1
Schedule Introduction to ArcGIS Server Rob and Kevin Questions Break 2:15 to 2:45 Developing with ArcGIS Server and DotNet Kelly Questions Developing with ArcGIS Server and JAVA Sathya Questions Social by the pool 5:30 to 7:30 Please complete the session survey ESRI Developer Summit 2008 2
Agenda: Introduction to ArcGIS Server Introduce Author, Publish, Consume pattern Use Manager and create a Web mapping application Add tasks to an application Describe ArcGIS Server components and architecture
ArcGIS: a complete GIS Applications ArcGIS Desktop C o n s u m e r s ArcGIS Engine ArcGIS Explorer Web Mapping Application ArcGIS Mobile Author ArcMap ArcCatalog ArcGlobe + Extensions Custom GIS applications Lightweight GIS client (Free) Java.NET Lightweight toolkit Services Desktop ArcGIS Server Integrated server-based GIS ArcSDE technology ArcWeb Services ArcGIS Online New Data (Geodatabase) Personal for MS Access File File Personal Workgroup Enterprise ArcSDE
ArcGIS Server: Sharing geographic resources For example Maps Globes And more The resource runs on a server Service = resource running on a server Exposed to the internet Users connect to the service to use it
GIS on the Web in 3 steps 1. Author content ArcGIS Desktop applications Create GIS resources 2. Serve content Publish GIS resources as services ArcCatalog and ArcGIS Server Manager 3. Consume services Web mapping application ArcGIS Explorer ArcGIS Desktop
Types of services Map View or query a 2D map on the server Globe View or query a 3D globe on the server Geocode Perform address matching on the server Geodata Perform data replication, extraction, or query over the intranet or Internet Geoprocessing Run a tool or model on the server and get the results back
Types of GIS services: Visualization and mapping Services for displaying data Map services Globe services
What can you do with a globe service? 3D data visualization Globe navigation Animations Query Collection of layers Can be added individually to client Document settings ignored (sun position, background color, etc.)
Types of GIS services: Spatial Analysis Services that provide functionality Geoprocessing services Geocoding services Network analysis services (requires ArcGIS Network Analyst extension)
Types of GIS services: Spatial data management Services that provide Web access to data Create local copies of remote data Execute database queries Synchronize edits with another database Geodata services: published geodatabase data Mobile data services: data access for mobile devices
Services are created from data and files GIS Service Map Globe Geocode GIS Resource Map document (.mxd or.pmf) Globe document (.3dd) Locator (.loc file or geodatabase) Geodata Geoprocessing Geodatabase or Map document with geodatabase layer Toolbox (.tbx) or Map document with tool layer
Authoring GIS content with ArcGIS Desktop ArcMap 2D GIS data Tool layers (models) ArcCatalog Geodatabases Address locators ArcGlobe 3D GIS layers Globes ArcToolbox Geoprocessing models
Publishing GIS services Web-enabled GIS resources (mxd, tbx, geodatabase) Choose functionality to expose Use ArcCatalog Right-click content (e.g.,.mxd) > Publish to ArcGIS Server wizard Right-click GIS server > Add New Service wizard Use ArcGIS Server Manager Publish a GIS Resource wizard Add New Service wizard More on this later
Consuming GIS services Out-of-the-box clients ArcGIS Desktop ArcGIS Explorer Web mapping applications Create Web Application wizard Custom Web applications Web ADF Mobile applications Mobile ADF
Consuming in other clients ArcGIS layer properties displayed in Google Earth Publish a map as a KML service Layer description: displayed below the layer name KML Description and KML Snippet: used in legend Can contain HTML formatted strings
Clients Users may connect with Browser (Internet Explorer, Firefox) Desktop client (ArcMap, ArcGIS Engine application, ArcGIS Explorer) Mobile client (ArcGIS Mobile application, smart phone application)
Consuming Services in ArcGIS Explorer ArcGIS Explorer information http://www.esri.com/software/arcgis/explorer/
-Author a map with ArcMap -Publish the map with ArcCatalog -Use the map in ArcGIS Explorer
Agenda: Introduction to ArcGIS Server Introduce Author, Publish, Consume pattern Use Manager and create a Web mapping application Add tasks to an application Describe ArcGIS Server components and architecture
ArcGIS Server Manager Web-based administration tool Publish GIS services Create Web mapping applications (ArcCatalog can t do this) Manage GIS server properties
Publish services with Manager You publish a document or set of data The data/document must be prepared Author a map (.MXD), globe (.3DD), etc. Publish in Manager or ArcCatalog
Create a Web mapping application with Manager
What is a Web mapping application? A web application (website) that uses GIS services Multi-service architecture Map can display multiple services From ArcGIS Servers on the Internet ArcIMS, WMS, ArcWeb Services, etc.
What can I add to a Web mapping application? Toolbar Map Tasks Query Search Find address Editing Overview Map More
How do I create a Web mapping application? ArcGIS Server Manager - non-programmers Menu and wizard approach Can customize the web application with developer tools Developer environment - programmers Use an integrated development environment (IDE).NET: Visual Studio 2005, Visual Web Developer Express (free from Microsoft) or other developer tools (Dreamweaver, etc.) Java: Eclipse, Sun Java Studio Creator, etc. Use Web Mapping Application template or add Web controls to a new or existing web application
Publishing a service from Manager Use in ArcMap Creating a Web Mapping Application Use in the Web App
Agenda: Introduction to ArcGIS Server Introduce Author, Publish, Consume pattern Use Manager and create a Web mapping application Add tasks to an application Describe ArcGIS Server components and architecture
Tasks Perform a function Lightweight on the client Use servers to get their jobs done Responsible for: Asking the question Displaying the answer In Web ADF applications, tasks: Are managed by a task manager Have their results displayed in task results Work asynchronously using callbacks
Task Results control Results presented as nodes in tree view Context menu for zoom or pan to a feature, highlight a feature in a result set, or remove task results
Out-of-the-box tasks Tasks provided as Web controls with the Web ADF Search attributes Find address Find place Query attributes Geoprocessing Editor Can be implemented without writing code
Search attributes task Searches feature layers provided by map resource manager Developer defines search fields Results provided as ADO.NET dataset Run time Design time
Query attributes task Searches feature layers provided by map resource manager Design time Developer defines parameters used to query values in field Provides drop-down list of preset choices at run time or a textbox Queries can use validator to restrict values entered Multiple queries can be grouped together to produce single result Creates single query on one map layer Can have compound criteria Results provided as ADO.NET dataset Run time
Find place task Find places by name provided by ArcWeb Services Control provides textbox to enter place name Results provided as ADO.NET dataset Must provide ArcWeb Services account Either Commercial Services or Public Services account Design time Run time
Find address task Requires geocode resource manager and geocode resource User input form created dynamically at run time Based on inputs required by geocode resource Geocode configuration (e.g. minimum match score) with geocode resource Results (match or address candidates) provided as ADO.NET dataset Design time Run time
Creating an editing application with Manager Choose map service Non-pooled with editable data From a local connection Define the account with which to connect Required for all applications that use a local connection User must be in agsusers or agsadmin group
Creating an editing application with Manager Add and configure the Editing task Choose versions and layers for editing Select which editing functionality to allow Configure snapping Allow or deny ability to change settings Advanced Advanced tab tab has has options options for for how how conflicts conflicts are are handled: handled: -Conflict -Conflict resolution resolution rule rule -Can -Can display display a a message message when when conflicts conflicts are are resolved resolved
Editing in a Web mapping application Select the Editing task Choose the version to edit Choose the layer to edit Make edits Save Tools Tools are are specific specific to to the the geometry geometry being being edited edited
Geoprocessing services in 3 steps Author create geoprocessing functionality Geoprocessing models Publish create the GIS service Toolbox (.tbx) Map document (.mxd) Consume use the service ArcGIS Desktop ArcGIS Explorer Web mapping application Custom clients
Authoring a geoprocessing service Service functionality is contained in models Additional considerations when publishing as a service: Restricted data types for parameters Data access and permissions Performance
Consuming a geoprocessing service ArcGIS Desktop clients Available as toolboxes in ArcToolbox Web mapping applications Add geoprocessing tasks when designing application ArcGIS Explorer Available as tasks Use Task Manager to add
Add tasks to the Web Application
What are geodata services? Provide Web access to data Create local copies of remote data Execute geodatabase queries Synchronize edits with another geodatabase Geodatabase only Personal for Microsoft Access, file, or ArcSDE Publish geodatabase directly Publish a map document that contains geodatabase data
Publishing a geodatabase Choose operations allowed Extraction data can be copied from the geodatabase Query queries can be executed against the geodatabase (requires custom clients) Replication (ArcSDE geodatabases only) edits can be synchronized with another geodatabase (More next!) Creates a single geodata service
Geodatabase replication Like dynamic copies of a geodatabase Changes (edits) can be synchronized Uses a pair of geodatabase replicas Replica in the original geodatabase = parent A related replica in the distributed geodatabase = child Each can be edited individually Local or Internet connections Parent Edits Changes from parent sent to child Changes from child sent to parent Edits Child
Geodatabase replication: 3 replica types ArcSDE geodatabase Geodatabase Checkout/ check-in Parent geodatabase Once only Child geodatabase ArcSDE geodatabase One-way Parent geodatabase Multiple times Child geodatabase Two-way Parent geodatabase Multiple times Child geodatabase
Replication workflow example: field crew Crew creates replica from utilities geodatabase (checkout) Edits are made in the field (while disconnected) At end of day, edits synchronized with parent (check-in) The next day or time, the entire process is repeated Utilities Synchronize only once Create replica (check out) 9:00 AM Synchronize (check in) 5:00 PM Field crew replica Checkout/check-in replication Edits made throughout the day
Replication workflow example: regional office Regional geodatabase must be kept current Read-only information from main office Replica is created from the main office geodatabase Each night, edits are synchronized Edits from main office geodatabase sent to regional geodatabase Only changes are sent Edits synchronized every night 11:59 PM Main office Editors One-way replication Region Viewers
Replication workflow example: editing teams Each team is responsible for a different set of data Utilities, transportation Edits from each team are synchronized to each geodatabase Each geodatabase has current information from both teams Few conflicts: editing responsibilities are well defined Transportation editors Transportation team Utilities team Utilities editors Two-way replication
Agenda: Introduction to ArcGIS Server Introduce Author, Publish, Consume pattern Use Manager and create a Web mapping application Add tasks to an application Describe ArcGIS Server components and architecture
ArcGIS Server: what's in the box? ArcGIS Server Manager ArcSDE ArcGIS Explorer (Free download too) Web ADF Mobile ADF (.NET only) Enterprise JavaBeans ADF (Java only) Help http://webhelp.esri.com/arcgisserver/9.2/ and more ArcGIS Server extensions (optional) 3D extension Data Interoperability extension Network extension Spatial extension
Components of the ArcGIS Server system GIS server: hosts GIS services Web server: hosts applications that consume GIS services Data server: provides data for GIS services Authoring tools: ArcGIS Desktop Administration tools: ArcGIS Server Manager, ArcCatalog Clients: Web mapping applications, ArcGIS Explorer, ArcGIS Desktop, mobile applications See Map on Next Page
Overview of the ArcGIS Server system Mobile devices Web browsers Desktop clients: -ArcGIS Explorer Consume GIS services -ArcGIS Desktop -ArcGIS Engine Internet ArcGIS Server Manager Web GIS ArcGIS Server Web server Administer ArcGIS Server GIS server ArcCatalog 3 Types Author content ArcGIS Desktop Data Visualize Analyze Geodata
ArcGIS Server components ArcGIS Server ArcSDE
ArcGIS Server components ArcGIS Server Server Object Container ArcSDE
ArcGIS Server components ArcGIS Server Server Object Manager Server Object Container ArcSDE
ArcGIS Server components ArcGIS Server Web Tier Server Object Manager Server Object Container ArcSDE
SOM and SOC instances up and running SOM Server Object Manager SOC Server Object Container Task Manager SOC SOC SOC SOM
Manage SOC instances in ArcCatalog Start and stop instances Modify instance properties Add instances SOC SOC SOC
Web Tier up and running Web Server running IIS Internet Information Services SOM Internet IIS
Database up and running SQL Server Express DBMS DBMS
Deployment scenarios Web Tier SOM Web Tier SOM SOC ArcSDE SOC ArcSDE DBMS DBMS
Workgroup Smaller organization One unit or group Local DBMS DBMS Web Tier SOM SOC ArcSDE What about growth? What if one component fails?
Small capacity enterprise Application tier and database tier First level of a distributed environment Development Testing All Server components on one machine DBMS is isolated on its own server Use the direct connect DBMS Web Tier SOM SOC ArcSDE Direct Connect
Small capacity enterprise and high availability Mission criticality Two machines all components multiple SOMs Cross-referencing SOCs Hardware and DBMS s in a failover or cluster Web Tier SOM SOC ArcSDE Web Tier SOM SOC ArcSDE Direct Connect Direct Connect DBMS DBMS
Medium capacity enterprise and high availability Four machines Isolate SOCs Greater instances More Servers Web Tier SOM Web Tier SOM SOC ArcSDE SOC ArcSDE Direct Connect Direct Connect DBMS DBMS
Large capacity enterprise and high availability N-tier. More traffic add more web tiers Extend SOC tier Web Tier SOM Web Tier SOM N machine scaling SOC ArcSDE SOC ArcSDE SOC ArcSDE SOC ArcSDE Direct Connects Direct Connects N machine scaling DBMS DBMS
How do the components work together? Processing a client request Browser Web Tier SOM SOC
Browser initiates a GIS action Browser Web Tier SOM SOC Internet Client pans or zooms Request sent to web server
Client request is sent to the SOC SOC Browser Web Tier SOM SOC Internet SOC Client pans or zooms Request sent to web server SOM passes request to a SOC
SOC processing Browser Web Tier SOM SOC Internet SOC generates new images Map resource Rivers Map resource Base map
SOC returns images Browser Internet Web Tier SOM SOC SOC generates new images SOC passes images to web tier
Web tier blending Browser Internet Web Tier SOM SOC Blending SOC generates new images SOC passes images to web tier Web tier blends images (optional)
Image sent to Browser Browser Internet Web Tier SOM SOC SOC generates new images SOC passes images to web tier Web tier blends images (optional) One image sent to browser
Browser blending Browser Internet Web Tier SOM SOC Browser blending is the default option SOC passes images to web tier
Images are sent to Browser Browser Web Tier SOM SOC Internet Browser blending is the default option SOC passes images to web tier Web tier sends images to browser
Browser creates one image Browser Web Tier SOM SOC Internet Blending Browser blending is the default option SOC passes images to web tier Web tier send images to browser Browser blends the images into one
Cached map services Browser Web Tier SOM SOC Internet Web server has ALL possible images pre-generated at several map scales
Cached images in arcgiscache folder
How many images are created for a cache? Many variables Scale levels Your map extent at smallest scale Tile size And more Takes time Takes disk space Speeds client access
Web tier has images ready Browser Web Tier SOM SOC Internet Request sent to web server
SOC discovers cache Browser Web Tier SOM SOC Internet Request sent to web server SOM passes request to a SOC SOC discovers cache, doesn t generate images
Cached images sent to browser Browser Web Tier SOM Internet Web tier sends images to browser After initial request, SOM doesn t pass any more to the SOC
Caching map services Benefits Speed Performance Quality Industry standard Drawbacks Time to generate files A few hours to a few days The more scales and data the longer Disk space to store files
What about data that changes often? For example: Parcels undergoing constant edits Tracking vehicles Monitor attributes of a device in the field, like water usage Possibilities Don t cache that layer If the layer is cached, use a script to update cache of changes only Display the layer as a graphics layer (Example next)
Agenda: Introduction to ArcGIS Server Introduce Author, Publish, Consume pattern Use Manager and create a Web mapping application Add tasks to an application Describe ArcGIS Server components and architecture