Cool CF Debugging Shlomy Gantz 07/29/01CF_ODYSSEY.

Slides:



Advertisements
Similar presentations
Introducing JavaScript
Advertisements

CF and JSP/Servlets Developed originally by Robi Sen For the CF UnderGround II Seminar, Apr 2001 Edited and enhanced by Charlie Arehart (Robi had an emergency.
Detecting Bugs Using Assertions Ben Scribner. Defining the Problem  Bugs exist  Unexpected errors happen Hardware failures Loss of data Data may exist.
Java Script Session1 INTRODUCTION.
Week 6: Chapter 6 Agenda Automation of SQL Server tasks using: SQL Server Agent Scheduling Scripting Technologies.
Error Handling With Fusebox Presentation By Eron Cohen.
The Web Warrior Guide to Web Design Technologies
Week 5 IBS 520. ColdFusion Variables CF uses variables to store data in memory. There are many different types of variables; each has its own.
15 Chapter 15 Web Database Development Database Systems: Design, Implementation, and Management, Fifth Edition, Rob and Coronel.
Working with JavaScript. 2 Objectives Introducing JavaScript Inserting JavaScript into a Web Page File Writing Output to the Web Page Working with Variables.
Fast Track to ColdFusion 9. Getting Started with ColdFusion Understanding Dynamic Web Pages ColdFusion Benchmark Introducing the ColdFusion Language Introducing.
Tutorial 10 Programming with JavaScript
HTML Recall that HTML is static in that it describes how a page is to be displayed, but it doesn’t provide for interaction or animation. A page created.
Week 2 IBS 685. Static Page Architecture The user requests the page by typing a URL in a browser The Browser requests the page from the Web Server The.
XP 1 Working with JavaScript Creating a Programmable Web Page for North Pole Novelties Tutorial 10.
DT228/3 Web Development Databases. Database Almost all web application on the net access a database e.g. shopping sites, message boards, search engines.
JavaScript, Fourth Edition
Microsoft ® Official Course Monitoring and Troubleshooting Custom SharePoint Solutions SharePoint Practice Microsoft SharePoint 2013.
Form Handling, Validation and Functions. Form Handling Forms are a graphical user interfaces (GUIs) that enables the interaction between users and servers.
4.1 JavaScript Introduction
PHP Tutorials 02 Olarik Surinta Management Information System Faculty of Informatics.
WaveMaker Visual AJAX Studio 4.0 Training Troubleshooting.
ASP.NET Programming with C# and SQL Server First Edition Chapter 6 Debugging and Error Handling.
Server-side Scripting Powering the webs favourite services.
The Art of Debugging Shlomy Gantz 02/13/01MDCFUG.
SIMPLE ROUTER The slide made by Salim Malakouti. Next we will create the Router  What do I we mean by a router?  Routers work similar to a map. It receives.
Exception Handling MDCFUG 6/12/2007 David Lakein Programmer / Analyst TeraTech Inc.
What’s New in CF 8 Admin MDCFUG 8/14/2007 Ajay Sathuluri Sr. Web and Database Engineer TeraTech Inc.
Lesson 19. JavaScript errors Since JavaScript is an interpreted language, syntax errors will usually cause the script to fail. Both browsers will provide.
COLD FUSION Deepak Sethi. What is it…. Cold fusion is a complete web application server mainly used for developing e-business applications. It allows.
Chapter 4 JavaScript and Dynamic Web pages. Objectives Static Web pages Dynamic Web pages JavaScript Variables Assignments. JavaScript Functions –(prompt(“”,””)
ColdFusion 9 and Flex 4: Application Development Ryan Stewart Platform Evangelist, Adobe Systems
Introduction to ColdFusion Yu Fu 2003 MEC Candidate.
XP Tutorial 10New Perspectives on Creating Web Pages with HTML, XHTML, and XML 1 Working with JavaScript Creating a Programmable Web Page for North Pole.
Tutorial 10 Programming with JavaScript. XP Objectives Learn the history of JavaScript Create a script element Understand basic JavaScript syntax Write.
Tutorial 10 Programming with JavaScript
Done by: Hanadi Muhsen1 Tutorial 1.  Learn the history of JavaScript  Create a script element  Write text to a Web page with JavaScript  Understand.
Creating Dynamic Web Pages Using PHP and MySQL CS 320.
ColdFusion Security Michael Smith President TeraTech, Inc ColdFusion, Database & VB custom development
JSTL Lec Umair©2006, All rights reserved JSTL (ni) Acronym of  JavaServer Pages Standard Tag Library JSTL (like JSP) is a specification, not an.
1 © Netskills Quality Internet Training, University of Newcastle HTML Forms © Netskills, Quality Internet Training, University of Newcastle Netskills is.
Introduction to Exception Handling and Defensive Programming.
Copyright © 2010 Certification Partners, LLC -- All Rights Reserved Perl Specialist.
Advanced ColdFusion: Error Handling Mosh Teitelbaum evoch, LLC.
Application.cfm tips and Tricks Michael Smith President TeraTech, Inc ColdFusion, database & VB custom development and training.
Dynamic Debug Output and Error Handling in CF5 and CFMX November 12, 2002 By Douglas M. Smith Application Architect for Teratech, Inc.
CF Pest Control By Shlomy Gantz President, BlueBrick Inc. Presented by Sandra Clark
Java server pages. A JSP file basically contains HTML, but with embedded JSP tags with snippets of Java code inside them. A JSP file basically contains.
XP Tutorial 10New Perspectives on HTML and XHTML, Comprehensive 1 Working with JavaScript Creating a Programmable Web Page for North Pole Novelties Tutorial.
FT228/3 Web Development Error processing. Introduction READ Chapter 9 of Java Server Pages from O’reilly 2 nd Edition Need to be able to 1) Diagnose and.
JavaScript Scripting language What is Scripting ? A scripting language, script language, or extension language is a programming language.
Copyright © 2003 ProsoftTraining. All rights reserved. Perl Fundamentals.
IS-907 Java EE World Wide Web - Overview. World Wide Web - History Tim Berners-Lee, CERN, 1990 Enable researchers to share information: Remote Access.
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
ASP. ASP is a powerful tool for making dynamic and interactive Web pages An ASP file can contain text, HTML tags and scripts. Scripts in an ASP file are.
Tutorial 10 Programming with JavaScript. 2New Perspectives on HTML, XHTML, and XML, Comprehensive, 3rd Edition Objectives Learn the history of JavaScript.
JavaScript Introduction and Background. 2 Web languages Three formal languages HTML JavaScript CSS Three different tasks Document description Client-side.
JavaScript, Sixth Edition
Tutorial 10 Programming with JavaScript. 2New Perspectives on HTML, XHTML, and XML, Comprehensive, 3rd Edition Objectives Learn the history of JavaScript.
1 CSC160 Chapter 1: Introduction to JavaScript Chapter 2: Placing JavaScript in an HTML File.
JavaScript and AJAX 2nd Edition Tutorial 1 Programming with JavaScript.
XP Tutorial 10New Perspectives on HTML, XHTML, and DHTML, Comprehensive 1 Working with JavaScript Creating a Programmable Web Page for North Pole Novelties.
Introduction to ASP.NET, Second Edition2 Chapter Objectives.
Error Handling Michael Smith President TeraTech, Inc ColdFusion, Database & VB custom development
Debuggers. Errors in Computer Code Errors in computer programs are commonly known as bugs. Three types of errors in computer programs –Syntax errors –Runtime.
SQL Database Management
Data Virtualization Tutorial… CORS and CIS
Chrome Developer Tools
Nate Nelson I*LEVEL, Inc.
How to debug a website using IE F12 tools
Presentation transcript:

Cool CF Debugging Shlomy Gantz 07/29/01CF_ODYSSEY

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Introduction - Famous Last words  “…if  “…if debugging is defined as the art of taking bugs out of a program, programming must be putting them in…”  “..It’s  “..It’s not a bug, It’s a feature “ (Microsoft)

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Types of bugs  Syntax  Syntax Error  Run-Time  Run-Time Errors  Logical  Logical Errors

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Types of bugs - Syntax Errors  Syntax Error Example View Example View Example

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Types of bugs - Run-Time Errors  Run-Time Error Example SELECT SUM(Salary) AS TotalSalary, COUNT(Emp_ID) as NumOfEmployees FROM AnnualSalary WHERE SALARY > #AVGSalary# View Example View Example

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Types of bugs - Logical Errors  Logical Error example #YesNoFormat(ShlomyExists_YN)# View Example View Example

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Other things that can go wrong  Database  Database connection (ODBC,MDAC …)  Cold  Cold Fusion server  Web  Web Server  OS  Hardware

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Debugging Steps  Plan  Back-up  Isolate  Find  Find The error  Fix  Fix - Don’t patch  Look  Look for similar  Document

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 “Debugger’s Block”  If  If all else fails  …  … and if that doesn’t work

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Cold Fusion Administrator

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Enable Performance Monitoring View Example View Example

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Enable CFML stack trace  CF tracks what tags have run during page process.  Can be used either through CFTRY/CFCATCH or the Studio Debugger Debugger

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Show Variables  Show all variables processed by ColdFusion: FORM FORM URL URL CGI CGI Cookie Cookie

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Show Processing Time  Show how long, in milliseconds, it takes for a page process to  run to completion

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Detail View  Breakdown of all templates run during a page process.  Proccessing time for each template

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Show SQL and Datasource Name  Shows SQL Statement & DSN in error messages

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Show Query Information  Query Name  RecordCount  Processing Time  Query Executed

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Display Template Path in Error Msg  Show the name of the actual template in which the error occurred

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Restrict Debug Access  By Default All when debugging is turned on all users can see debug information.  Restrict access by IP address

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Debugging with studio  Setting up Development Mapping.

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Using the interactive debugger

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Debugging CF applications  Show  Show your variables (not only once)  Create  Create breakpoints and Follow the flow  Use  Use Exception handling  Look  Look at your application logs  

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 &  Using CFABORT to create breakpoints Select * from Contacts WHERE Active_YN=1 #getContacts.recordcount#

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 &  Following the flow Step 1 Step 1.1 Step 1.2 Step 2 View Example View Example

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Debugging in CFML   View Example View Example View Example View Example

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Debugging CF applications  

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01   View Example View Example

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01   ... Add code here   ... Add exception processing code here ... Add exception processing code here ... Additional CFCATCH blocks go here ... Additional CFCATCH blocks go here

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01  

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Application Logs  Read your application logs regularly Error","TID=199","07/27/00","13:32:35"," ","Mozilla/4.0 (compatible; MSIE 4.01; Windows NT)","An error has occurred. HTTP/ Object Not Found" "Error","TID=199","07/27/00","13:32:45"," ","Mozilla/4.0 (compatible; MSIE 4.01; Windows NT)","Error resolving parameter SLOT_IDColdFusion was unable to determine the value of the parameter. This problem is very likely due to the fact that either: You have misspelled the parameter name, or You have not specified a QUERY attribute for a CFOUTPUT, CFMAIL, or CFTABLE tag.The error occurred while evaluating the expression: #slot_id# The error occurred while processing an element with a general identifier of (#slot_id#), occupying document position (4:12) to (4:20) in the template file D:\wwwroot\cfun2000\Examples\JS\JSexample1_CFMW\edit_def.cfmThe specific sequence of files included or processed is:D:\WWWROOT\CFUN2000\EXAMPLES\JS\JSEXAMPLE1_CFMW\EDIT_DEF.CFM.Date/Time: 07/27/00 13:32:45Browser: Mozilla/4.0 (compatible; MSIE 4.01; Windows NT)Remote Address: HTTP Referer: D:\wwwroot\cfun2000\Examples\JS\JSexample1_CFMW\edit_def.cfm" "Warning","TID=152","07/27/00","15:07:21","In a CF_TagName construct custom tag file 'C:\CFUSION\CustomTags\Pages.cfm' will occlude custom tag file 'C:\CFUSION\CustomTags\cf_pages\Pages.cfm'." "Warning","TID=152","07/27/00","15:07:21","In a CF_TagName construct custom tag file 'C:\CFUSION\CustomTags\Pages.cfm' will occlude custom tag file 'C:\CFUSION\CustomTags\cf_pages\images\Pages.cfm'." View Example View Example

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 CF_Objectdump/  Read your application logs regularly <CF_ObjectDump Object="#Object#" Deserialize="yes|no" > <CFDUMP <CFDUMP var = #variable_name#> var = #variable_name#> View Example View Example

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Debugging Databases  SQL query analyzer View Example View Example

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Debugging JavaScript  “Microsoft Script debugger”/“Netscape JavaScript Debugger”  Using alert() and return false;

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Debugging flash  No debug output  simulated flash requests  output in flash

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Tools   BugTraq ( BugTraq - Full ) BugTraq - Full BugTraq - Full   Automatic Code Generation Tools CodeSaver / CodeCharge / CommerceBlocks CodeSaver / CodeCharge / CommerceBlocks CodeSaverCodeChargeCommerceBlocks CodeSaverCodeChargeCommerceBlocks

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 What’s new in 5.0  Easier Log Analysis

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 What’s new in 5.0  New options on CF Admin debug setting

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 Thank You  Michael Dinowitz, Emily Kim, Michael Imhoff and Abraham Lloyd.  … Michael Smith

“Cool CF Debugging - Copyright Shlomy Gantz 2001 – 07/29/01 QA  Shlomy Gantz