BIT 285: ( Web) Application Programming Lecture 14 : Thursday, February 19, 2015 SQL Database and...

6
BIT 285: (Web) Application Programming Lecture 14: Thursday, February 19, 2015 SQL Database and LINQ Instructor: Craig Duckett

Transcript of BIT 285: ( Web) Application Programming Lecture 14 : Thursday, February 19, 2015 SQL Database and...

Page 1: BIT 285: ( Web) Application Programming Lecture 14 : Thursday, February 19, 2015 SQL Database and LINQ Instructor: Craig Duckett.

BIT 285: (Web) Application Programming

Lecture 14: Thursday, February 19, 2015

SQL Database and LINQ

Instructor: Craig Duckett

Page 2: BIT 285: ( Web) Application Programming Lecture 14 : Thursday, February 19, 2015 SQL Database and LINQ Instructor: Craig Duckett.

2Code Reviews

Page 3: BIT 285: ( Web) Application Programming Lecture 14 : Thursday, February 19, 2015 SQL Database and LINQ Instructor: Craig Duckett.

3 What is a code review? From Wikipedia:

"Code review is systematic examination (often known as peer review) of computer source code. It is intended to find and fix mistakes overlooked in the initial development phase, improving both the overall quality of software and the developers' skills. Reviews are done in various forms such as pair programming, informal walkthroughs, and formal inspections.[1]"

"Code review practices fall into three main categories: pair programming, formal code review and lightweight code review"

Formal review: "a careful and detailed process with multiple participants and multiple phases"

Lightweight: sometimes a walkthrough, but can be

"Typical code review rates are about 150 lines of code per hour."

Goals:

Ensure code quality

On-the-job technical training

I.e., this spreads best practices amongst the group

Page 4: BIT 285: ( Web) Application Programming Lecture 14 : Thursday, February 19, 2015 SQL Database and LINQ Instructor: Craig Duckett.

4 MSDN('Setup' is good, the rest is C++ specific) Hand out hard copies beforehand

Everyone needs to have read through this prior to the meeting

Also send out electronic copies for searching, using tools on, etc, etc

Avoid checking in stuff after printing

Each page needs:

File name

Page number

Line numbers

(Clearly, the idea is for a group of people to sit down & go over this stuff in person)

Page 5: BIT 285: ( Web) Application Programming Lecture 14 : Thursday, February 19, 2015 SQL Database and LINQ Instructor: Craig Duckett.

5 Today's work Google/Bing for existing checklists for 10 minutes

Remember items that you'd like to see in your checklist

Group list-making

Brainstorm

cull

Pick a code sample to review

Aim for a single thing, with ~150 lines of code or so.  I'm guessing that a single page/feature is probably about good.

Print out the stuff-to-review

Each reviewer should put their name on it

(I'm interested in seeing your mark-up/questions/comments)

Have everyone read through it (10-20 minutes) & mark it up

Do the code review

Discuss the code in a respectful, quality-oriented manner

Page 6: BIT 285: ( Web) Application Programming Lecture 14 : Thursday, February 19, 2015 SQL Database and LINQ Instructor: Craig Duckett.

6 For milestone 3 Each person needs to do one more code review for milestone 3

For each review, include:

Your checklist

List any sources that you used

Include a copy of the code at the time that you reviewed it

This should include your mark-up

The group's list of notes from the review

This includes both advice/changes to the reviewed code as well as general advice for everyone

In addition to whatever notes you want to include, it is expected that you will find some errors. 

Not finding errors would be extremely suspicious.

Each person needs to write up a short reflection on the experience.  These should be private, and given directly to the instructor.

I'm expecting ½ to 1 page, single-spaced, with some quality thoughts