INF 111 / CSE 121: Software Tools and Methods Lecture Notes for - - PDF document

inf 111 cse 121 software tools and methods
SMART_READER_LITE
LIVE PREVIEW

INF 111 / CSE 121: Software Tools and Methods Lecture Notes for - - PDF document

INF 111 / CSE 121: Software Tools and Methods Lecture Notes for Summer, 2008 Michele Rousseau Lecture Notes 1 Administrative / Intro to Software Eng. Announcements 1. Brush up on your Java 2. Read Van Vliet Chs. 1, 3 and 15 3. Lab 1 & 2


slide-1
SLIDE 1

1

INF 111 / CSE 121: Software Tools and Methods

Lecture Notes for Summer, 2008 Michele Rousseau

Lecture Notes 1 – Administrative / Intro to Software Eng.

Announcements

  • 1. Brush up on your Java
  • 2. Read Van Vliet Chs. 1, 3 and 15
  • 3. Lab 1 & 2 Due on Thursday
  • 4. WELCOME TO CLASS ☺

Lecture Notes 1 2

Today’s Lecture

Administrative details Review of Software Engineering

Lecture Notes 1 3

slide-2
SLIDE 2

2

Introductions

Instructor

  • Michele Rousseau
  • Email: michele@ics.uci.edu

◘ Please put INF111 in the Subject

Lecture Notes 1 4

◘ Please put INF111 in the Subject

  • Office Hours: by appointment
  • Office: DBH-5204 (for now)

Introductions

Teaching Assistant

  • Kristina Winbladh
  • Email: awinblad@ics.uci.edu
  • Office Hours: Thursday Noon

Lecture Notes 1 5

  • Office Hours: Thursday Noon

◘ In Lab

Pre-requisites

Informatics 43 OR ICS 52 OR CSE90

  • with a grade of C or better

ICS 6D / Mathematics 6D ICS 6B / Mathematics 6B

Lecture Notes 1 6

ICS 6B / Mathematics 6B Mathematics 6G or 3A Lower-division writing Please let me know if you have not

satisfied these requirements

slide-3
SLIDE 3

3

Class Information

Website

  • www.ics.uci.edu/~michele/Teaching/INF111-Sum08
  • Can access from my home page

◘ www.ics.uci.edu/~michele

Lecture Notes 1 7

Course Materials

Required textbooks

  • Van Vliet, Hans

Software Engineering: Principles and Practice. 3rd edition.

  • Brooks, Fredrick

Lecture Notes 1 8

The Mythical Man-Month. Anniversary edition. Will be announced on the website and in lecture

Recommended Readings

  • Humphrey, Watts

The Personal Software Process

  • Will be announced on the website and in lecture

Course Mechanics (1)

Lecture

  • TTh: 9a – 11:50a (ELH 110)

Discussion

  • Tue: 1p

1:50p (DBH 1200)

Lecture Notes 1 9

  • Tue: 1p - 1:50p (DBH 1200)

Lab

  • Thu: 1p - 1:50p (ICS 192)
slide-4
SLIDE 4

4

Discussion is for…

Discussing Details about the

Assignments / Labs

Presenting Tools Discussing Readings

Lecture Notes 1 10

Reviewing Material Preparing for Tests Reviewing Tests & Assignments

How to be successful (1)

Attend class

  • Much is covered that is not in the textbook

◘Material is core part of the exams ◘What is said in class supercedes all else

  • Official place for announcements

Lecture Notes 1 11

p

Attend Discussion Section & Lab Visit course Web site on a regular

basis

  • Assignments
  • Labs
  • Lecture Slides

How to be successful (2)

Check EEE Do the Assignments / Labs Do the Readings

Off

Lecture Notes 1 12

Use Office Hours Ask Questions

slide-5
SLIDE 5

5

Grading

Assignments 40% Labs 15%

Lecture Notes 1 13

Quizzes 20% Final 25%

Will scale only if necessary

Assignments (1)

3 Assignments

  • Will have at least 1 week to complete each

Assignment

f

Lecture Notes 1 14

Format of the assignments

  • Questions on Effort Estimation
  • Use a software tool to complete a task
  • Reflect on and document your experience

Assignments (2)

Package properly

  • Every assignment…

◘ …has your student ID ◘ …has your name ◘ …has a cover page with class title, Name, student ID and assignment #

Lecture Notes 1 15

g ◘ …is properly stapled

  • Electronic Submissions through Checkmate

Quality over quantity Express yourself clearly

  • Be concise
slide-6
SLIDE 6

6

Assignments (3)

A new forum will be created on the

Noteboard for each assignment

  • Post your questions there
  • Ta, other students, and I will post answers,

suggestions and additional information

Lecture Notes 1 16

Don’t wait until the last minute to post

(The TA may not be awake or available)

Please turn in on time

  • Do not wait until the last minute

No late assignments

Exceptions for being late

At the TA/Instructor’s discretion

  • Contact the instructor/TA as soon as possible
  • Preferably before you are late

Valid reasons

Lecture Notes 1 17

  • Serious illness, accident, family emergency, etc.

Not-so-valid reasons

  • “No ink in my printer”, “didn’t know it was due

today”, “my computer crashed”, “couldn’t find parking”, etc.

Laboratories

We will drop the lowest lab (6 Labs)

  • Work needs to be completed by the END
  • f the lab session
  • No late labs will be accepted

Lecture Notes 1 18

  • Usually will require work to be done by the

end of Lab

  • Sometimes will need to submit a write-up

afterwards

  • Electronic submissions through Checkmate
slide-7
SLIDE 7

7

Quizzes and Final Exam

Quizzes

  • Weekly
  • Primarily based on lectures and readings
  • Must be in pen if you want it re-graded

Lecture Notes 1 19

No Make-up Quizzes Final will

  • Primarily based on lecture and readings
  • May include some elements from

assignments, discussion and labs

Grading

Performed by the TA Disputes

  • Let me know ASAP (by the next class)
  • Please don’t play the “points-game”

◘ I have limited time ◘ Check your grading thoroughly and ASAP

Lecture Notes 1 20

◘ Include a coversheet with your name, student ID, and a detailed description of the error

Re-grading

  • Will only accept re-grades at the beginning of the

class following the date they were returned

  • Must be accompanied with a clear explanation of

what needs to be reconsidered and why

  • Entire assignment will be considered

Questions

When in doubt

Ask Me or the TA

  • Open door policy
  • Attend Office Hours
  • Attend Discussion

Lecture Notes 1 21

Check the Noteboard (eee) Email me

  • If I think the whole class could benefit I’ll

forward it

  • let me know if you specifically don’t want it

forwarded

Ask your friends

slide-8
SLIDE 8

8 Academic Dishonesty (ugh)

Please don’t Cheat

  • Know the academic dishonesty policies (for ICS &

UCI)

  • ICS: http://www.ics.uci.edu/ugrad/policies/
  • UCI:

http://www.editor.uci.edu/catalogue/appx/appx.2.htm

22

If you do…

  • Final grade is an “F”, irrespective of partial grades

◘ Assignments, Quizzes, Labs, or Final

  • Letter in your UCI file

Anything copied from a book or website needs to

be quoted and the source provided

Help each other but don’t share work

Your TA is your friend, but your friend is not your TA

  • Your friend’s help may be cheating

To avoid being a cheater

  • Always do your work by yourself

◘ It is okay to…

  • … ask your friends about how solve/approach a problem

di i t

23

  • … discuss an assignment

◘ It is not okay to…

  • … ask for the answer/solution
  • … copy work
  • … have them do it for you!
  • …put your work on the Web
  • … borrow or lend work!

◘ When in doubt – ask me!

Use good Judgment

Add/Drop/Change of Grade Policy

Adding or Dropping the Class

  • Check with Summer Sessions
  • Check with the Department
  • If they are good with it – so am I

Changing Grade to P/NP option

24

g g p

  • Check with Summer Sessions
  • Check with the Department
  • If they are good with it – so am I

Please bring completed Add/Drop

Cards (2 cards)

  • In Pen PLEASE ☺
slide-9
SLIDE 9

9

Other Policies

Please use your UCI or ICS account

  • This is for your privacy
  • Needs to be activated if you are a new student
  • include INF111 in the subject of all email

Lecture Notes 1 25

Questions of general interest will be

forwarded to the board

  • if you don’t want it forwarded for some reason

please state that

If you need accommodations due to a

disability, talk to me

Miscellaneous

INF 111 / CSE 121 mimics the real-world

  • Package your assignments/labs properly
  • Use proper language and proper form

You get out of this class what you put

Lecture Notes 1 26

  • u get out o

t s c ass at you put into it

  • Attend Class, Discussion , & Labs

◘ Participate

  • Follow instructions
  • Read and study the textbook and slides
  • Help is available, do not be afraid to ask

questions

Course Objective

To teach you basic tools & methods

used in software engineering development

Lecture Notes 1 27

slide-10
SLIDE 10

10

Now to the fun part…

  • Brief review of S/W concepts
  • Overview of Software Tools and Methods

Lecture Notes 1 28

What is Software Engineering?

“A discipline that deals with the building of software

systems which are so large that they are built by a team or teams of engineers.” [Ghezzi, Jazayeri, Mandrioli]

“A discipline whose aim is the production of fault-free

software delivered on-time and within budget that

Lecture Notes 1 29

software, delivered on-time and within budget, that satisfies the user’s needs. Furthermore, the software must be easy to modify when the user’s needs change.” [Schach]

“Software engineering is concerned with theories,

methods and tools for professional software development” [Sommerville]

Best practices for Software Engineers

Software engineers should adopt a

systematic and organised approach to their work and use appropriate tools and

Lecture Notes 1 30

techniques depending on the problem to be solved, the development constraints and the resources available.

slide-11
SLIDE 11

11

Why Software Engineering?

Software Crisis – Software is typically

  • Late
  • Over Budget
  • Wrong product

Lecture Notes 1 31

OBJECTIVE:

  • Reduce costs and increase quality

Software Costs

Software costs often dominate system

costs.

  • In other words..

◘ The costs of software are often greater than the hardware cost

Lecture Notes 1 32

Software costs more to maintain than it

does to develop.

  • For systems with a long life

maintenance costs may be several times development costs

Analysis 2% Specification 5% Maintenance 67%

High Cost

Design 6% Lecture Notes 1 33 Module Testing 7% Integration 8%

[Schach]

Module Coding 5%

slide-12
SLIDE 12

12

What do me mean by HUGE?

Thousands of programmers Millions of lines of code Daily builds and regression testing

Lecture Notes 1 34

More testers then programmers Needs to work on many machines

  • Cross platform

Needs to be backwards compatible

The Five P’s of Software Engineering

People – those who develop, manage,

and run the software

Product - the software itself Project - the activity of creating the

Lecture Notes 1 35

Project - the activity of creating the

software

Process - the manner in which the

project proceeds

Professionalism - the attitude of all

involved

Software Engineering is not programming

Small project You Build what you want One product Huge project Teams Build what they want Family of products

Lecture Notes 1 36

Programming Engineering Few sequential changes Short-lived Cheap Small consequences Many parallel changes Long-lived Costly Large consequences

slide-13
SLIDE 13

13

Take a break!

Stretch, Relax Get some water, Use the restroom Get to know your classmates… Etc…..

When we return…

More Review of S/W Engineering Overview of Software Tools

  • Why we need them and what they are

Lecture Notes 1 37

From Programming to Engineering

People

  • Someone has get it done (generally many someones)
  • Range from novice to very experienced

Processes

  • To organize and manage the efforts of individuals

Lecture Notes 1 38

  • Range from informal to very formal

Tools

  • To support the people and the processes
  • Range from simple to very advanced

People + Processes + Tools ⇒ Product

People

The single most important factor in the

success/failure of a product

  • Quality
  • Suitability
  • Cost

Lecture Notes 1 39

People with these characteristics can be scarce Many different kinds of people

  • Managers
  • Programmers
  • Technical writers
  • Testers
slide-14
SLIDE 14

14

Processes

Essential to achieve a quality product Need these qualities (not always available)

  • Quality
  • Suitability
  • Cost

Lecture Notes 1 40

Time is also scarce resource

Many different kinds of processes

  • Bug tracking
  • Change approval
  • Quality assurance

Tools

Needed to support people and processes Scarce resource

  • Quality
  • Suitability
  • Cost

Lecture Notes 1 41

  • Cost

Many different kinds of tools

  • Drawing
  • Analysis
  • Project management
  • Source code management

people support process support

Result of applying people, processes, and

tools

Consists of many deliverables

  • Software
  • Documentation
  • User manuals

Product

Lecture Notes 1 42

  • User manuals
  • Test cases
  • Design documents

Intrinsic qualities

  • Safety
  • Reliability
  • User friendliness
slide-15
SLIDE 15

15

People, Processes, Tools, Products

Products are always the eventual goal

  • Selling products creates revenue
  • Selling good products creates lots of revenue
  • Selling bad products creates little revenue

People processes and tools are retained by

Lecture Notes 1 43

People, processes, and tools are retained by

  • rganization
  • Build a reputation through the quality of products
  • Create organizational culture
  • Important to keep the team intact

People + Processes + Tools ⇒ Product

Choose the Right Solution

Hawaii

Lecture Notes 1 44

Tijuana Europe

Matters of Scale

Lecture Notes 1 45

Need to choose the appropriate

technique/tool for the job.

  • elephant gun to kill a fly?
  • fly-swatter to ward off an elephant?
slide-16
SLIDE 16

16 What is a Software Lifecycle Model?

“A software life cycle model is either

a descriptive or prescriptive characterization of how software is or should be developed. “ [scacchi]

Lecture Notes 1 46

“abstract representation of a

process”[sommerville]

Typical Activities in the Lifecycle

Requirements

  • The User’s Needs
  • Eliciting requirements from the Client

◘ Interviews, Surveys ◘ Prototyping ◘ Usability testing… etc.. Specification

D fi i “Wh t th t ill d ”

  • Defining “What the system will do”
  • Articulation of the requirements
  • Informal Formal

Design

  • Abstract Representation of the system
  • Defining the structure of the system
  • Architecture (High Level) Components (Low Level)

◘ How do the components connect?

  • Design Patterns

47

Typical Activities in the Lifecycle

Testing

  • Verification: “Have we built the system right”
  • Validation: “Have we built the right system”
  • Perpetual Testing
  • Different Levels of Testing

S stem ◘ System ◘ Integration ◘ Unit ◘ Regression

Maintenance

  • Configuration management / Change

Management

48

slide-17
SLIDE 17

17

Software Life Cycle Models

Build-and-fix Waterfall Rapid prototyping

I t l

Lecture Notes 1 49

Incremental Spiral A software life cycle model is a high-level process

Build-and-Fix

Build first version Modify until client is satisfied Lecture Notes 1 50 Operations mode Retirement

Development Maintenance

Some argue if this is really a lifecycle model… it is a bad one at best. What about our basic activities?

Waterfall [Royce , 1970s]

Requirements phase Verify Specification phase Verify Design Changed requirements Verify Lecture Notes 1 51 Operations mode Retirement g phase Verify Implementation phase Test Integration phase Test

Development Maintenance

slide-18
SLIDE 18

18

Rapid Prototyping

Build and discard simple prototype Specification phase Verify Design Changed requirements Verify Lecture Notes 1 52 Operations mode Retirement g phase Verify Implementation phase Test Integration phase Test

Development Maintenance

Spiral [Boehm]

Risk l i Risk analysis Risk analysis Risk analysis Lecture Notes 1 53 analysis

Incremental [Mills]

Requirements phase Verify Specification phase Verify Architectural Lecture Notes 1 54 FOR EACH BUI LD Perform detailed design, implementation, and

  • integration. Test.

Deliver to client. Operations mode Retirement design Verify

Development Maintenance

slide-19
SLIDE 19

19

Moving on…

Methods and Tools

Lecture Notes 1 55

Tools Most Students Have Used:

  • Text editors
  • Maybe some have used IDE

(Integrated Development Environment like Netbeans)

Lecture Notes 1 56

  • File system to manage projects
  • Print statements for debugging

Problem – Approach Doesn’t Scale

May work for 1 or 2 students Doesn’t work with..

Lecture Notes 1 57

Doesn t work with..

  • More people
  • Bigger code
  • Different versions
  • Multiple Platforms
slide-20
SLIDE 20

20 Why Do We Need Tools and Methods?

Scaling Problem Ex: Longhorn project

  • 50+ Million lines of code
  • Daily Builds and Regression testing

Lecture Notes 1 58

◘ Takes 3 days from the time you submission to executable

  • Needs to be backwards compatible
  • Installation needs to work on millions of machines
  • 4000 Programmers
  • ~1.7 Testers for each programmer
  • $2 billion
  • 6 years in development

Challenges

Logistics

  • How do you design a process that will allow

thousands of people to work together at the same time?

  • How do you test?

So many platforms so little time

Lecture Notes 1 59

Design

  • How do you design a system with 50+ mill lines of

code?

  • How do you maintain conceptual (architectural)

integrity?

Software Technology

Types of Software Technology

  • Tools
  • Methods
  • Notations

How do they help?

Lecture Notes 1 60

y p

  • Automate tasks
  • Help people to do complex tasks
  • Improve s/w quality
  • Increase productivity
  • Permit verification and conformance checking
  • Project tracking
  • Establish procedures
slide-21
SLIDE 21

21

Tools

IDE (Integrated Development

Environment)

Compiler Debugger

Lecture Notes 1 61

Diagram Tools Automated testing Static checking

Methods

Process Models Unit / System Testing Pair Programming Test driven development

Lecture Notes 1 62

Class-Responsibility-Collaboration

Cards

Notations

Programming languages

  • Java, C, C++

Data formats

  • HTML, XML, Comma Delimited

Logic Notation

  • Propositional or Predicate Logic

Lecture Notes 1 63

p g

Design Notations

  • UML

Requirements Notations

  • Z notation, Larch, Nitpick, SCR, Natural Language
slide-22
SLIDE 22

22

Example: Guitar

Strum

Lecture Notes 1 64

Pick

… etc

#1 #2 3/4 G Am7 G 4/4 G E{|---------------------------|-----------------------------------| B{|---0-------1-------3-------|---12----12--12----12----12--12----| G{|-------0-------0-------0---|-------0-------0-------0-------0---| D{|---------------------------|-----------------------------------| A{|-----------0-------2-------|---10------10------10------10------| E{|---3-----------------------|-----------------------------------| + . + . + . + . + . + . + .

Lecture Notes 1 65

3/4 G Am7 G 4/4 G E||---------------------------|-----------------------------------| B||---0-------1-------3-------|---12----12--12----12----12--12----| G||.------0-------0-------0---|-------0-------0-------0-------0---| D||.--------------------------|-----------------------------------| A||-----------0-------2-------|---10------10------10------10------| E||---3-----------------------|-----------------------------------| + . + . + . + . + . + . + .

  • 1. Blackbird singing in the dead of night
  • 2. Blackbird singing in the dead of night

Analogy

Guitar => Tool How To Play => Method Tabs => Notation

Lecture Notes 1 66

slide-23
SLIDE 23

23

Selecting a Tool

Tools

I T y p i

Lecture Notes 1 67

Techniques S / W Process Model

D E A L i c a l l y

Conflict: Practice and Problems

Why is there a gap between actual

practice and state of the art?

  • Both for students and industry

Focus is on the end product – not the

Lecture Notes 1 68

Focus is on the end product – not the

process

  • Don’t have time for a new tool or method
  • Learning Curve

First time using a tool?

You know it might exist Have to find it

  • Decide which one to download

Download / Buy it Install it

Lecture Notes 1 69

Figure it out

  • (hmmm what does that button do?)
  • How do I get it to help me
  • Hmmm what does this error message mean….
  • Sheesh --- this is just slowing me down

Uncertain payoff

slide-24
SLIDE 24

24

Learning Curve

It takes >= 10,000 hours to become

and expert

A s/w eng needs to know:

  • Programming languages

Lecture Notes 1 70

  • Programming techniques
  • Tools
  • Methods
  • Notations
  • Domain knowledge

… and how & when to apply each of these

Personal Practices &S/W Eng GAP

Focus tends towards What and not

How

Steep learning curve and unclear

payoffs dissuades users

Lecture Notes 1 71

This course will help with all of these

payoffs dissuades users will help with all of these