pollmaps - 2011 esri uc presentation

69
Esri International User Conference | San Diego, CA Technical Workshops | Poll Maps: Concept, Planning, Design and Implementation Alex Yule, Jim Herries, Mamata Akella, Kenny Ling Esri Mapping Center Team July 2011

Upload: alex-yule

Post on 16-Dec-2014

427 views

Category:

Technology


2 download

DESCRIPTION

 

TRANSCRIPT

Page 1: Pollmaps - 2011 Esri UC Presentation

Esri International User Conference | San Diego, CA

Technical Workshops |

Poll Maps: Concept, Planning, Design and ImplementationAlex Yule, Jim Herries, Mamata Akella, Kenny Ling

Esri Mapping Center Team

July 2011

Page 2: Pollmaps - 2011 Esri UC Presentation

mappingcenter.esri.com

Page 3: Pollmaps - 2011 Esri UC Presentation

Jim Herries

Poll Maps: Intro

Page 4: Pollmaps - 2011 Esri UC Presentation

The FanMap/PollMap Project

• How do people represent their opinions?

• Often opinions are represented on the map at a scale and aggregation level convenient to the database

• Can the map itself encourage participation through better representation?

Page 5: Pollmaps - 2011 Esri UC Presentation

The FanMap/PollMap Project

• Long term goal: a template that allows people to put their opinions on the map

• Short term goal: build something for a specific event

• What kind of map and application would encourage people to vote on a topic?

• Can it be something they would pass along to others?

Page 6: Pollmaps - 2011 Esri UC Presentation

The Plan

• Intro

• Superbowl FanMap

• Basketball FanMap

• Earth Day PollMap

• Configuring the PollMap Template

Superbowl Basketball Earth Day

8 Weeks 2 Weeks 1 Week

Page 7: Pollmaps - 2011 Esri UC Presentation

Alex Yule, Mamata Akella

FanMap: Superbowl Edition Demo

Page 8: Pollmaps - 2011 Esri UC Presentation

Building a Team

Photo credit: americanistadechiapas @ flickr

Page 9: Pollmaps - 2011 Esri UC Presentation

Building a Team

• Customer (Charlie Frye)

• Lead Developer (Alex Yule)

• Project Manager/Data Guru (Jim Herries)

• Cartographer/Designer (Mamata Akella)

• Sysadmin (Kenny Ling)

• Friends for testing, UI advice, moral support (Mapping Center Team & Co.)

Page 10: Pollmaps - 2011 Esri UC Presentation

Conceptual Planning

• Audience: General Public (sports fans)

• Functionality:- Vote submission

- Vote display

- Vote reporting

- Geolocation

• Look and feel: Dark, minimalist slate basemap with slick UI

Page 11: Pollmaps - 2011 Esri UC Presentation

Superbowl FanMap: Conceptual Planning

• Audience: General Public (sports fans)

• Functionality:- Vote submission

- Vote display

- Vote reporting

- Geolocation

• Look and feel: Dark, minimalist slate basemap with slick UI

• Platform: Flex

• User load: Low with slight potential for virality

• Deployment target: Single rack server

Page 12: Pollmaps - 2011 Esri UC Presentation

Superbowl FanMap: Production

Page 13: Pollmaps - 2011 Esri UC Presentation

Mamata Akella

Superbowl FanMap: Aesthetics

Page 14: Pollmaps - 2011 Esri UC Presentation

Superbowl FanMap: Basemap Design

• Less is more- Features

- Labels

- Color

• Supports better visualization of thematic content

Page 15: Pollmaps - 2011 Esri UC Presentation

Superbowl FanMap: “Map Sandwich”

• How it works- The ‘basemap’ is split into

two map services:- Reference (top)

- Base (bottom)

- Combined with thematic content (middle)

- Client-side Votes layer

Page 16: Pollmaps - 2011 Esri UC Presentation

Superbowl FanMap: Special Effects

Participating

city

Large city

Medium city

Small city

• Label hierarchy

- Cities with participating teams highest

Page 17: Pollmaps - 2011 Esri UC Presentation

Superbowl FanMap: Special Effects

• Projection- Winkel-Tripel

- Modified central meridian

Page 18: Pollmaps - 2011 Esri UC Presentation

Superbowl FanMap Production: Web Client

Page 19: Pollmaps - 2011 Esri UC Presentation

FanMap Production: Superbowl Story

Page 20: Pollmaps - 2011 Esri UC Presentation

Superbowl FanMap: Architecture

Client

Voting Logic

Vote Symbolization

Summarization

Web/Map Server

BasemapApplicationFeature Service

SDEGDB

Page 21: Pollmaps - 2011 Esri UC Presentation

Superbowl FanMap: Vote Symbology

• Symbolized in the client

• Color

- Classed, based on team colors

- Transparent!

•Size

- Number of total votes

•Outline

- Better visibility for overlapping

symbols

Page 22: Pollmaps - 2011 Esri UC Presentation

Superbowl FanMap: Tech Vocab

• SDE- Spatially-enables an RDBMS such as Microsoft SQL

Server and enables access from ArcGIS clients

- Required for publishing editing-enabled services

• FeatureService- Type of data service that allows client to access and edit

features

- Allows editing if used with a FeatureLayer and ArcSDE

Web/Map Server

BasemapApplicationFeature Service

SDEGDB

Page 23: Pollmaps - 2011 Esri UC Presentation

VIRAL: A nice problem to have

Sports Illustrated:

Page 24: Pollmaps - 2011 Esri UC Presentation

• High Server Load

- Slow response time for app, maps

• High Client Load

- High number of features result in slow drawing, panning

- UI lockup during vote summarization

Superbowl FanMap: Architectural Issues

Client

Voting

Vote Symbolization

Summarization

Web/Map Server

BasemapAppFeature Service

SDEGDB

Page 25: Pollmaps - 2011 Esri UC Presentation

Superbowl FanMap Production: Vote Collisions

Photo credit: viriyincy @ flickr

Page 26: Pollmaps - 2011 Esri UC Presentation

Alex Yule, Mamata Akella, Kenny Ling

Basketball FanMap: Demo

Page 27: Pollmaps - 2011 Esri UC Presentation

Conceptual Planning

• Audience: General Public (sports fans)

• Functionality:- Same as Superbowl app

- Configurability

• Look and feel: Dark, minimalist slate basemap with slick UI

• Existing codebase: Superbowl FanMap

• Platform: Javascript

• User load: Moderate with potential for large viral spikes - 10 concurrent users

• Deployment target: 4-tier Amazon cloud

Page 28: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap

• Architecture

• Production- Prototyping

- Building

- Designing

• Deployment

Page 29: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap: Architecture

Client

Web/Map Server

BasemapAppFeature Service

Voting

Vote Symbolization

Summarization

SDEGDB

Summarization

Voting

SDE GDB

GP ServerWeb/Map Servers

Maps

App

Load Balancer

Page 30: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap: Architecture

SDE GDB

GP Server

Summarizatio

n

Voting

• Multi-tier architecture

Web/Map Servers

Maps

App

Load Balancer

Page 31: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap: Production – Server-side!

Superbowl Basketball

Vote Symbology FeatureLayer Dynamic Map Service

Voting FeatureService Geoprocessing

Summarization Client Geoprocessing

Server / Client

Page 32: Pollmaps - 2011 Esri UC Presentation

FanMap Production: Prototyping the UI

Page 33: Pollmaps - 2011 Esri UC Presentation

FanMap Production: Prototyping the UI

Page 34: Pollmaps - 2011 Esri UC Presentation
Page 35: Pollmaps - 2011 Esri UC Presentation
Page 36: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap Prototyping: Voting

• Start with the highest risk functionality (voting)- Get that working, then move on

1. Mock out steps for vote service

Page 37: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap Prototyping: Voting Service

where locationfield == Locationfor vote in Votes: votefield += 1

Update Cursor (Places)

Votes

Inputs

Location

User ID

Insert new row with all vote data:User ID, DateTime, Location, Votes

Insert Cursor (Votes)

SDE GDB

Places

Votes

Page 38: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap Prototyping: Voting

• Start with the highest risk functionality (voting)- Get that working, then move on

1. Mock out steps for vote service

2. Test each step in ArcMap

3. Put steps together into script

4. Test in ArcMap as script tool

5. Publish and test as GP service

6. Integrate into App

Page 39: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap Prototyping: Summarization

Construct summary_stats String so we get SUM

for each field

Construct Stats String

Inputs

Fields(Teams)

Extent Select all features in Extent with at least some votes

for these teams

Select Features

Output Table

Stats

Get SUM of each fieldIn Selected Features

Summary Stats

Page 40: Pollmaps - 2011 Esri UC Presentation

Mamata Akella

Basketball FanMap Aesthetics

Page 41: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap: “Map Sandwich”

• How it works- The ‘basemap’ is split into

two map services:- Reference (top)

- Base (bottom)

- Combined with thematic content

- Votes (middle)

Page 42: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap: Vote Symbology Basics

• Color

- Based on each university’s team colors

- Gray = tied

•Size

- Total number of votes

•Outline

- Better visibility for overlapping

symbols

Page 43: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap: Vote Symbology Basics

• Quantities > Graduated Symbols

Page 44: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap: Vote Symbology Specifics

Page 45: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap: Vote Symbology Specifics

Page 46: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap: Vote Symbology Specifics

• Minimum Symbol Size- Non integer

- Better rendering

Page 47: Pollmaps - 2011 Esri UC Presentation

Basketball FanMap: Vote Symbology Specifics

• Vote symbology- Multi-scale

- Varied by time period

Low Vote High Vote

Page 48: Pollmaps - 2011 Esri UC Presentation

ITERATE!

Page 49: Pollmaps - 2011 Esri UC Presentation

ITERATE!

Page 50: Pollmaps - 2011 Esri UC Presentation

Kenny Ling

Basketball FanMap Deployment

Page 51: Pollmaps - 2011 Esri UC Presentation

FanMap – Deployment/Architecture

• Why use it?- Amazon Machine Images (AMIs)

- No need for new hardware requests or software installation

- Start up new machines or backup

- Data portability+reliability- Volumes

- Snapshots

- Deployment- Higher configuration machines

- Machine replicas

Page 52: Pollmaps - 2011 Esri UC Presentation

FanMap – Deployment/Architecture

• Replicating your servers- Updating services

- Load balancing

- Failsafe in case Amazon servers in one region goes down

• Monitoring your services- Set up Performance Monitor logs

- Track performance in Task Manager

Page 53: Pollmaps - 2011 Esri UC Presentation

FanMap – Deployment/Architecture

• Things to be aware of:- Instances are inaccessible whilst creating images

- Transferring your cache to the cloud may take a long time

- Option: Cache in the cloud

- Plan security settings/groups in advance- Security groups cannot be changed once instance is started

Page 54: Pollmaps - 2011 Esri UC Presentation

FanMap – Deployment/Architecture

SDE GDB

GP Server

Summarizatio

n

Voting

Web/Map Servers

Maps

App

Load Balancer

Security Group

Page 55: Pollmaps - 2011 Esri UC Presentation

FanMap – Deployment/Architecture

SDE GDB

GP Server

Summarizatio

n

Voting

Web/Map Servers

Maps

App

Load Balancer

Security Group 2

Security Group 3Security Group 1

Page 56: Pollmaps - 2011 Esri UC Presentation

Jim Herries

Part II: Using the PollMap Template

Page 57: Pollmaps - 2011 Esri UC Presentation

FanMap PollMap: Birth of a Template

http://bit.ly/pollmaptemplate

• What’s Included- Application source code

- Geoprocessing source code

- Map service MXDs

- Data for postal codes in the U.S. and Canada

- URLs to basemaps you can use during development

- Simple documentation

Page 58: Pollmaps - 2011 Esri UC Presentation

Superbowl Basketball Earth Day

Earth Day PollMap: the FanMap Goes Green!

8 Weeks 2 Weeks 1 Week

Page 59: Pollmaps - 2011 Esri UC Presentation

Download the PollMap Template

• W

Page 60: Pollmaps - 2011 Esri UC Presentation

Download the PollMap Template

• Download .ZIP file

• Unzip to a convenient folder

• Read the “Getting Started” document

Page 61: Pollmaps - 2011 Esri UC Presentation

Copy Application folder contents

• Open the Application folder

• Copy PollMap folder over to c:/inetpub/wwwroot (or equivalent)

Page 62: Pollmaps - 2011 Esri UC Presentation

Set up you Question First in VoteWindow.html

• Getting the question right takes iteration

• This template is best for multiple A vs. B types of questions

Page 63: Pollmaps - 2011 Esri UC Presentation

Set up choices in the config.js file

• Simple choices

Page 64: Pollmaps - 2011 Esri UC Presentation

Set up maps and services in the config.js file

• Follow the Getting Started document

Page 65: Pollmaps - 2011 Esri UC Presentation

Sample from Ireland

Page 66: Pollmaps - 2011 Esri UC Presentation

Sample from Ireland

Page 67: Pollmaps - 2011 Esri UC Presentation

Conclusion

Page 68: Pollmaps - 2011 Esri UC Presentation

Thank You!

• Alex Yule - [email protected] - twitter: @yuletide

• Jim Herries: [email protected] - twitter: @jherries

• Mamata Akella: [email protected]

• Kenny Ling: [email protected]

• Mapping Center Team- http://mappingcenter.esri.com

- twitter: @mappingcenter

Page 69: Pollmaps - 2011 Esri UC Presentation