Software Engineering II - CS605 Handouts
Software Engineering II - CS605 Handouts
VU
Table of Content
Table of Content...................................................................................................................2 Lecture No. 1........................................................................................................................4 Lecture No. 2......................................................................................................................12 Lecture No. 3......................................................................................................................14 Lecture No. 4......................................................................................................................1 Lecture No. 5......................................................................................................................23 Lecture No. 6......................................................................................................................2! Lecture No. !......................................................................................................................32 Lecture No. ......................................................................................................................35 Lecture No. ".....................................................................................................................3! Lecture No. 10....................................................................................................................41 Lecture No. 11....................................................................................................................46 Lecture No. 12....................................................................................................................65 #ea$ure$% #etric$ an& In&icator$......................................................................................65 #etric$ for $oftware 'ualit(...............................................................................................66 Lecture No. 13....................................................................................................................6! Lecture No. 14....................................................................................................................!1 )a$eline..............................................................................................................................!2 #etric$ for $*all organi+ation$..........................................................................................!2 Lecture No. 15....................................................................................................................!5 Lecture No. 16....................................................................................................................! Lecture No. 1!.................................................................................................................... 0 Lecture No. 1 .................................................................................................................... 4 Lecture No. 1".................................................................................................................... 5 Lecture No. 20.................................................................................................................... Lecture No. 21...................................................................................................................."2 Lecture No. 22...................................................................................................................."5 Lecture No. 23...................................................................................................................."" Lecture No. 24..................................................................................................................100 Lecture No. 25..................................................................................................................102 Lecture No. 26..................................................................................................................104 Lecture No. 2!..................................................................................................................106 Lecture No. 2 ..................................................................................................................10" Lecture No. 2"..................................................................................................................112 Lecture No. 30..................................................................................................................114 Lecture No. 31..................................................................................................................11! Lecture No. 32..................................................................................................................11 Lecture No. 33..................................................................................................................11" Lecture No. 34..................................................................................................................122 ,elea$e Nu*bering..........................................................................................................122 Internal ,elea$e Nu*bering.............................................................................................122 Lecture No. 35..................................................................................................................125 Lecture No. 36..................................................................................................................12 Lecture No. 3!..................................................................................................................133 Lecture No. 3 ..................................................................................................................135 Lecture No. 3"..................................................................................................................13 Lecture No. 40..................................................................................................................141
VU
Lecture No. 41..................................................................................................................142 Lecture No. 42..................................................................................................................143 Lecture No. 43..................................................................................................................154 Lecture No. 44..................................................................................................................16" Lecture No. 45..................................................................................................................1!3
VU
So all t/o$e t/ing t/at are relate& to $oftware are al$o relate& to $oftware engineering. So*e of (ou *ig/t /a2e t/oug/t t/at /ow .rogra**ing language &e$ign coul& be relate& to $oftware engineering. If (ou loo4 *ore clo$el( at t/e $oftware engineering &efinition$ &e$cribe& abo2e t/en (ou will &efinitel( $ee t/at $oftware engineering i$ relate& to all t/o$e t/ing$ t/at are /el.ful in $oftware &e2elo.*ent. So i$ t/e ca$e wit/ .rogra**ing language &e$ign. 3rogra**ing language &e$ign i$ one of t/e *a8or $ucce$$e$ in la$t fift( (ear$. T/e &e$ign of 9&a language wa$ con$i&ere& a$ t/e con$i&erable effort in $oftware engineering. T/e$e &a($ ob8ect-oriente& .rogra**ing i$ wi&el( being u$e&. If .rogra**ing language$ will not $u..ort ob8ect-orientation t/en it will be 2er( &ifficult to i*.le*ent ob8ectoriente& &e$ign u$ing ob8ect-oriente& .rinci.le$. 9ll t/e$e effort$ *a&e t/e ba$i$ of $oftware engineering.
ell-Engineered Software
Let:$ tal4 $o*et/ing about w/at i$ well-engineere& $oftware. ;ell-engineere& $oftware i$ one t/at /a$ t/e following c/aracteri$tic$. It i$ reliable It /a$ goo& u$er-interface It /a$ acce.table .erfor*ance It i$ of goo& 'ualit( It i$ co$t-effecti2e
VU
E2er( co*.an( can buil& $oftware wit/ unli*ite& re$ource$ but well-engineere& $oftware i$ one t/at confor*$ to all c/aracteri$tic$ li$te& abo2e. Software /a$ 2er( clo$e relation$/i. wit/ econo*ic$. ;/en e2er we tal4 about engineering $($te*$ we alwa($ fir$t anal(+e w/et/er t/i$ i$ econo*icall( fea$ible or not. T/erefore (ou /a2e to engineer all t/e acti2itie$ of $oftware &e2elo.*ent w/ile 4ee.ing it$ econo*ical fea$ibilit( intact. T/e *a8or c/allenge$ for a $oftware engineer i$ t/at /e /a$ to buil& $oftware wit/in li*ite& ti*e an& bu&get in a co$t-effecti2e wa( an& wit/ goo& 'ualit( T/erefore well-engineere& $oftware /a$ t/e following c/aracteri$tic$. 3ro2i&e$ t/e re'uire& functionalit( #aintainable ,eliable Efficient 1$er-frien&l( Co$t-effecti2e
)ut *o$t of t/e ti*e$ $oftware engineer$ en&$ u. in conflict a*ong all t/e$e goal$. It i$ al$o a big c/allenge for a $oftware engineer to re$ol2e all t/e$e conflict$.
9 Software Engineer i$ re'uire& to anal(+e t/e$e conflicting entitie$ an& trie$ to $tri4e a balance.
VU
Software Engineer$ alwa($ confront wit/ t/e c/allenge to *a4e a goo& balance of all t/e$e ting$ &e.en&ing on t/e re'uire*ent$ of t/e .articular $oftware $($te* at /an&. >e $/oul& anal(+e /ow *uc/ weig/t $/oul& all t/e$e t/ing$ get $uc/ t/at it will /a2e acce.table 'ualit(% acce.table .erfor*ance an& will /a2e acce.table u$er-interface. In $o*e $oftware t/e efficienc( i$ *ore i*.ortant an& &e$irable. =or e5a*.le if we tal4 about a crui$e *i$$ile or a nuclear reactor controller t/at are &ro2e& b( t/e $oftware $($te*$ t/en .erfor*ance an& reliabilit( i$ far *ore i*.ortant t/an t/e co$t-effecti2ene$$ an& u$er-frien&line$$. In t/e$e ca$e$ if (our $oftware &oe$ not react wit/in a certain a*ount of ti*e t/en it *a( re$ult in t/e &i$a$ter li4e C/ernob(l acci&ent. T/erefore $oftware &e2elo.*ent i$ a .roce$$ of balancing a*ong &ifferent c/aracteri$tic$ of $oftware &e$cribe& in t/e .re2iou$ $ection. 9n& it i$ an art to co*e u. wit/ $uc/ a goo& balance an& t/at art can be learne& fro* e5.erience.
cost
benefit
Software "ac(ground
- Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
6
VU
Ca.er ?one$ a renounce& .ractitioner an& re$earc/er in t/e file& of Software Engineering% /a& *a&e i**en$e re$earc/ in $oftware tea* .ro&ucti2it(% $oftware 'ualit(% $oftware co$t factor$ an& ot/er fiel&$ relate to $oftware engineering. >e *a&e a co*.an( na*e& Software 3ro&ucti2it( ,e$earc/ in w/ic/ t/e( anal(+e& *an( .ro8ect$ an& .ubli$/e& t/e re$ult$ in t/e for* of boo4$. Let:$ loo4 at t/e $u**ar( of t/e$e re$ult$. >e &i2i&e& $oftware relate& acti2itie$ into about twent(-fi2e &ifferent categorie$ li$te& in t/e table below. T/e( /a2e anal(+e& aroun& 10000 $oftware .ro8ect$ to co*e u. wit/ $uc/ a categori+ation. )ut /ere to cut &own t/e &i$cu$$ion we will onl( &e$cribe nine of t/e* t/at are li$te& below. 3ro8ect #anage*ent ,e'uire*ent Engineering 7e$ign Co&ing Te$ting Software @ualit( 9$$urance Software Configuration #anage*ent Software Integration an& ,e$t of t/e acti2itie$
Ane t/ing to note /ere i$ t/at (ou cannot $a( t/at an(one of t/e$e acti2itie$ i$ &o*inant a*ong ot/er$ in ter*$ of effort .utte& into it. >ere t/e .oint t/at we want to e*./a$i+e i$ t/at% t/oug/ co&ing i$ 2er( i*.ortant but it i$ not *ore t/an 13-14B of t/e w/ole effort of $oftware &e2elo.*ent. =re& )roo4 i$ a renowne& $oftware engineerC /e wrote a great boo4 relate& to $oftware engineering na*e& D9 #(t/ical #an #ont/E. >e co*bine& all /i$ article$ in t/i$ boo4. >ere we will &i$cu$$ one of /i$ article$ na*e& DNo Sil2er )ulletE w/ic/ /e inclu&e& in t/e boo4. #n e)cer*t fro' DNo Sil2er )ulletE F =re& )roo4$ Of all the monsters that fill the nightmares of our folklore, none terrify more than werewolves, because they transform unexpectedly from the familiar into horrors. For these we seek bullets of silver that can magically lay them to rest. he familiar software pro!ect has something of this character "at least as seen by the non#technical manager$, usually innocent and straight forward, but capable of becoming a monster of missed schedules, blown budgets, and flawed pro!ects. So we hear desperate cries for a silver bullet, something to make software costs drop as rapidly as computer hardware costs do. Scepticism is not pessimism, however. %lthough we see no startling breakthroughs, and indeed, such to be inconsistent with the nature of the software, many encouraging innovations are under way. % disciplined, consistent effort to develop, propagate and exploit them should indeed yield an order of magnitude improvement. here is no royal road, but there is a road. he first step towards the management of disease was replacement of demon theories and humours theories by the germ theory. he very first step, the beginning of hope, in itself dashed all hopes of magical solutions. &t told workers that progress would be made stepwise, at great effort, - Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
7
VU
and that a persistent, unremitting care would have to be paid to a discipline of cleanliness. So it is with software engineering today. So% accor&ing to =re& )roo4% in t/e e(e of an un$o./i$ticate& *anager $oftware i$ li4e a giant. So*eti*e$ it re2eal$ a$ an un$c/e&ule& &ela( an& $o*eti*e$ it $/ow$ u. in t/e for* of co$t o2errun. To 4ill t/i$ giant t/e *anager$ loo4 for *agical $olution$. )ut unfortunatel( *agic i$ not a realit(. ;e &o not /a2e an( *agic to &efeat t/i$ giant. T/ere i$ onl( one $olution an& t/at i$ to follow a &i$ci.line& a..roac/ to buil& $oftware. ;e can &efeat t/e giant na*e& $oftware b( u$ing &i$ci.line& an& engineere& a..roac/ towar&$ $oftware &e2elo.*ent. T/erefore% Software Engineering is nothing but a disciplined and systematic approach to software development. Now we will loo4 at $o*e of t/e acti2itie$ in2ol2e& in t/e cour$e of $oftware &e2elo.*ent. T/e acti2itie$ in2ol2e& in $oftware &e2elo.*ent can broa&l( be &i2i&e& into two *a8or categorie$ fir$t i$ con$truction an& $econ& i$ *anage*ent.
Software +e,elo*'ent
T/e con$truction acti2itie$ are t/o$e t/at are &irectl( relate& to t/e con$truction or &e2elo.*ent of t/e $oftware. ;/ile t/e *anage*ent acti2itie$ are t/o$e t/at co*.le*ent t/e .roce$$ of con$truction in or&er to .erfor* con$truction acti2itie$ $*oot/l( an& effecti2el(. 9 greater &etail of t/e acti2itie$ in2ol2e& in t/e con$truction an& *anage*ent categorie$ i$ .re$ente& below.
Con%truction
T/e con$truction acti2itie$ are t/o$e t/at &irectl( relate& to t/e &e2elo.*ent of $oftware% e.g. gat/ering t/e re'uire*ent$ of t/e $oftware% &e2elo. &e$ign% i*.le*ent an& te$t t/e $oftware etc. So*e of t/e *a8or con$truction acti2itie$ are li$te& below. ,e'uire*ent Gat/ering 7e$ign 7e2elo.*ent Co&ing Te$ting
-anage'ent
#anage*ent acti2itie$ are 4in& of u*brella acti2itie$ t/at are u$e& to $*oot/l( an& $ucce$$full( .erfor* t/e con$truction acti2itie$ e.g. .ro8ect .lanning% $oftware 'ualit( a$$urance etc. So*e of t/e *a8or *anage*ent acti2itie$ are li$te& below. 3ro8ect 3lanning an& #anage*ent Configuration #anage*ent Software @ualit( 9$$urance In$tallation an& Training
VU
Management
Project Planning and Management Configuration Management Quality Assurance Installation and Training
Construction
9$ we /a2e $ai& earlier t/at *anage*ent acti2itie$ are 4in& of u*brella acti2itie$ t/at $urroun& t/e con$truction acti2itie$ $o t/at t/e con$truction .roce$$ *a( .rocee& $*oot/l(. T/i$ fact i$ e*.at/i+e& in t/e =igure1. T/e figure $/ow$ t/at con$truction i$ $urroun&e& b( *anage*ent acti2itie$. T/at i$% certain .roce$$e$ an& rule$ go2ern all con$truction acti2itie$. T/e$e .roce$$e$ an& rule$ are relate& to t/e *anage*ent of t/e con$truction acti2itie$ an& not t/e con$truction it$elf.
T/e .roce$$e$ are $et of 4e( .roce$$ area$ HI39$J for effecti2el( *anage an& &eli2er 'ualit( $oftware in a co$t effecti2e *anner. T/e .roce$$e$ &efine t/e ta$4$ to be .erfor*e& an& t/e or&er in w/ic/ t/e( are to be .erfor*e&. E2er( ta$4 /a$ $o*e &eli2erable$ an& e2er( &eli2erable $/oul& be &eli2ere& at a .articular *ile$tone.
3roce$$e$:
#et/o&$ .ro2i&e t/e tec/nical D/ow-to:$E to carr(out t/e$e ta$4$. T/ere coul& be *ore t/an one tec/ni'ue to .erfor* a ta$4 an& &ifferent tec/ni'ue$ coul& be u$e& in &ifferent $ituation$.
#et/o&$6
Tool$ .ro2i&e auto*ate& or $e*i-auto*ate& $u..ort for $oftware .roce$$e$% *et/o&$% an& 'ualit( control.
Tool$6
VU
T O O L S
Quality Focus
In t/i$ $tage we tr( to fin& t/e $olution of t/e .roble* on tec/nical groun&$ an& ba$e our actual i*.le*entation on it. T/i$ i$ t/e $tage w/ere a new $($te* i$ actuall( &e2elo.e& t/at $ol2e$ t/e .roble* &efine& in t/e fir$t $tage.
Tec/nical 7e2elo.*ent :
If t/ere are alrea&( &e2elo.e& $($te*H$J a2ailable wit/ w/ic/ our new $($te* /a$ to interact t/en t/o$e $($te*$ $/oul& al$o be t/e .art of our new $($te*. 9ll t/o$e e5i$ting $($te*H$J integrate wit/ our new $($te* at t/i$ $tage.
Solution Integration:
9fter going t/roug/ t/e .re2iou$ t/ree $tage$ $ucce$$full(% w/en we actuall( &e.lo(e& t/e new $($te* at t/e u$er $ite t/en t/at $ituation i$ calle& $tatu$ 'uo. )ut once we get new re'uire*ent$ t/en we nee& to c/ange t/e $tatu$ 'uo.
Statu$ @uo:
9fter getting new re'uire*ent$ we .erfor* all t/e $te.$ in t/e $oftware &e2elo.*ent loo. again. T/e $oftware &e2elo.e& t/roug/ t/i$ .roce$$ /a$ t/e .ro.ert( t/at t/i$ coul& be e2ol2e& an& integrate& ea$il( wit/ t/e e5i$ting $($te*$.
10
VU
tatus Quo
Technical De"elo#ment
11
VU
1roce%% -aturit2 and C-T/e Software Engineering In$titute HSEIJ /a$ &e2elo.e& a fra*ewor4 to 8u&ge t/e .roce$$ *aturit( le2el of an organi+ation. T/i$ fra*ewor4 i$ 4nown a$ t/e Ca.abilit( #aturit( #o&el HC##J. T/i$ fra*ewor4 /a$ 5 &ifferent le2el$ an& an organi+ation i$ .lace& into one of t/e$e 5 le2el$. T/e following figure $/ow$ t/e C## fra*ewor4.
T/e$e le2el$ are briefl( &e$cribe& a$ follow$E 1. Le2el 1 F Initial6 T/e $oftware .roce$$ i$ c/aracteri+e& a$ a& /oc an& occa$ionall( e2en c/aotic. =ew .roce$$e$ are &efine&% an& $ucce$$ &e.en&$ u.on in&i2i&ual effort. )( &efault e2er( organi+ation woul& be at le2el 1. 2. Le2el 2 F ,e.eatable6 )a$ic .ro8ect *anage*ent .roce$$e$ are e$tabli$/e& to trac4 co$t% $c/e&ule% an& functionalit(. T/e nece$$ar( .ro8ect &i$ci.line i$ in .lace to re.eat earlier $ucce$$e$ on .ro8ect$ wit/ $i*ilar a..lication$. 3. Le2el 3 F 7efine&6 T/e $oftware .roce$$ for bot/ *anage*ent an& engineering acti2itie$ i$ &ocu*ente&% $tan&ar&i+e&% an& integrate& into an organi+ational $oftware .roce$$. 9ll .ro8ect$ u$e a &ocu*ente& an& a..ro2e& 2er$ion of t/e organi+ation:$ .roce$$ for &e2elo.ing an& $u..orting $oftware. 4. Le2el 4 F #anage&6 7etaile& *ea$ure$ for $oftware .roce$$ an& .ro&uct 'ualit( are controlle&. )ot/ t/e $oftware .roce$$ an& .ro&uct$ are 'uantitati2el( un&er$too& an& controlle& u$ing &etaile& *ea$ure$. 5. Le2el 5 F A.ti*i+ing6 Continuou$ .roce$$ i*.ro2e*ent i$ enable& b( 'ualitati2e fee&bac4 fro* t/e .roce$$ an& fro* te$ting inno2ati2e i&ea$ an& tec/nologie$. SEI /a$ a$$ociate& 4e( .roce$$ area$ wit/ eac/ *aturit( le2el. T/e I39$ &e$cribe t/o$e $oftware engineering function$ t/at *u$t be .re$ent to $ati$f( goo& .ractice at a .articular le2el. Eac/ I39 i$ &e$cribe& b( i&entif(ing t/e following c/aracteri$tic$6
12
VU
1. Goal$6 t/e o2erall ob8ecti2e$ t/at t/e I39 *u$t ac/ie2e. 2. Co**it*ent$6 re'uire*ent$ i*.o$e& on t/e organi+ation t/at *u$t be *et to ac/ie2e t/e goal$ or .ro2i&e .roof of intent to co*.l( wit/ t/e goal$. 3. 9bilitie$6 t/o$e t/ing$ t/at *u$t be in .lace F organi+ationall( an& tec/nicall( F to enable t/e organi+ation to *eet t/e co**it*ent$. 4. 9cti2itie$6 t/e $.ecific ta$4$ re'uire& to ac/ie2e t/e I39 function 5. #et/o&$ for *onitoring i*.le*entation6 t/e *anner in w/ic/ t/e acti2itie$ are *onitore& a$ t/e( are .ut into .lace. 6. #et/o&$ for 2erif(ing i*.le*entation6 t/e *anner in w/ic/ .ro.er .ractice for t/e I39 can be 2erifie&. Eac/ of t/e I39 i$ &efine& b( a $et of .ractice$ t/at contribute to $ati$f(ing it$ goal$. T/e 4e( .ractice$ are .olicie$% .roce&ure$% an& acti2itie$ t/at *u$t occur before a 4e( .roce$$ area /a$ been full( in$titute&. T/e following table $u**ari+e$ t/e I39$ &efine& for eac/ le2el. Le2el 1 2 I39$ No I39 i$ &efine& a$ organi+ation$ at t/i$ le2el follow a&-/oc .roce$$e$ K Software Configuration #anage*ent K Software @ualit( 9$$urance K Software $ubcontract #anage*ent K Software .ro8ect trac4ing an& o2er$ig/t K Software .ro8ect .lanning K ,e'uire*ent *anage*ent K 3eer re2iew$ K Inter-grou. coor&ination K Software .ro&uct Engineering K Integrate& $oftware *anage*ent K Training .rogra* K Argani+ation .roce$$ *anage*ent K Argani+ation .roce$$ focu$ K Software 'ualit( *anage*ent K @uantitati2e .roce$$ *anage*ent K 3roce$$ c/ange *anage*ent K Tec/nolog( c/ange *anage*ent K 7efect .re2ention
4 5
13
VU
7uring t/e$e ./a$e$% a nu*ber of acti2itie$ are .erfor*e&. 9 lifec(cle *o&el i$ a $erie$ of $te.$ t/roug/ w/ic/ t/e .ro&uct .rogre$$e$. T/e$e inclu&e re'uire*ent$ ./a$e% $.ecification ./a$e% &e$ign ./a$e% i*.le*entation ./a$e% integration ./a$e% *aintenance ./a$e% an& retire*ent. Software 7e2elo.*ent Lifec(cle #o&el$ &e.ict t/e wa( (ou organi+e (our acti2itie$. T/ere are a nu*ber of Software 7e2elo.*ent Lifec(cle #o&el$% eac/ /a2ing it$ $trengt/$ an& wea4ne$$e$ an& $uitable in &ifferent $ituation$ an& .ro8ect t(.e$. T/e li$t of *o&el$ inclu&e$ t/e following6 $ $ $ $ $ $ $ $ )uil&-an&-fi5 *o&el ;aterfall *o&el ,a.i& .rotot(.ing *o&el Incre*ental *o&el E5tre*e .rogra**ing S(nc/roni+e-an&-$tabili+e *o&el S.iral *o&el Ab8ect-oriente& life-c(cle *o&el$
In t/e following $ection$ we $/all $tu&( t/e$e *o&el$ in &etail an& &i$cu$$ t/eir $trengt/$ an& wea4ne$$e$.
14
VU
It i$ unfortunate t/at *an( .ro&uct$ are &e2elo.e& u$ing w/at i$ 4nown a$ t/e buil&-an&fi5 *o&el. In t/i$ *o&el t/e .ro&uct i$ con$tructe& wit/out $.ecification or an( atte*.t at &e$ign. T/e &e2elo.er$ $i*.l( buil& a .ro&uct t/at i$ rewor4e& a$ *an( ti*e$ a$ nece$$ar( to $ati$f( t/e client. T/i$ *o&el *a( wor4 for $*all .ro8ect$ but i$ totall( un$ati$factor( for .ro&uct$ of an( rea$onable $i+e. T/e co$t of buil&-an& fi5 i$ actuall( far greater t/an t/e co$t of .ro.erl( $.ecifie& an& carefull( &e$igne& .ro&uct. #aintenance of t/e .ro&uct can be e5tre*el( in t/e ab$ence of an( &ocu*entation.
aterfall -odel
T/e fir$t .ubli$/e& *o&el of t/e $oftware &e2elo.*ent .roce$$ wa$ &eri2e& fro* ot/er engineering .roce$$e$. )ecau$e of t/e ca$ca&e fro* one ./a$e to anot/er% t/i$ *o&el i$ 4nown a$ t/e waterfall *o&el. T/i$ *o&el i$ al$o 4nown a$ linear $e'uential *o&el. T/i$ *o&el i$ &e.icte& in t/e following &iagra*.
T/e .rinci.al $tage$ of t/e *o&el *a. &irectl( onto fun&a*ental &e2elo.*ent acti2itie$. It $ugge$t$ a $($te*atic% $e'uential a..roac/ to $oftware &e2elo.*ent t/at begin$ at t/e $($te* le2el an& .rogre$$e$ t/roug/ t/e anal($i$% &e$ign% co&ing% te$ting% an& *aintenance. In t/e literature% .eo.le /a2e i&entifie& fro* 5 to $tage$ of $oftware &e2elo.*ent.
T/e fi2e $tage$ abo2e are a$ follow$6 1. ,e'uire*ent 9nal($i$ an& 7efinition6 ;/at - T/e $($te*$ $er2ice$% con$traint$ an& goal$ are e$tabli$/e& b( con$ultation wit/ $($te* u$er$. T/e( are t/en &efine& in &etail an& $er2e a$ a $($te* $.ecification. 2. S($te* an& Software 7e$ign6 >ow F T/e $($te* &e$ign .roce$$ .artition$ t/e re'uire*ent$ to eit/er /ar&ware of $oftware $($te*$. It e$tabli$/e$ an& o2erall $($te* arc/itecture. Software &e$ign in2ol2e$ fun&a*ental $($te* ab$traction$ an& t/eir relation$/i.$.
15
VU
3. I*.le*entation an& 1nit Te$ting6 - >ow F 7uring t/i$ $tage t/e $oftware &e$ign i$ reali+e& a$ a $et of .rogra*$ or .rogra* unit$. 1nit te$ting in2ol2e$ 2erif(ing t/at eac/ unit *eet$ it$ $.ecification$. 4. Integration an& $($te* te$ting6 T/e in&i2i&ual .rogra* unit or .rogra*$ are integrate& an& te$te& a$ a co*.lete $($te* to en$ure t/at t/e $oftware re'uire*ent$ /a2e been *et. 9fter te$ting% t/e $oftware $($te* i$ &eli2ere& to t/e cu$to*er. 5. A.eration an& #aintenance6 Nor*all( t/i$ i$ t/e longe$t ./a$e of t/e $oftware life c(cle. T/e $($te* i$ in$talle& an& .ut into .ractical u$e. #aintenance in2ol2e$ correcting error$ w/ic/ were not &i$co2ere& in earlier $tage$ of t/e life-c(cle% i*.ro2ing t/e i*.le*entation of $($te* unit$ an& en/ancing t/e $($te*:$ $er2ice$ a$ new re'uire*ent$ are &i$co2ere&. In .rinci.le% t/e re$ult of eac/ ./a$e i$ one or *ore &ocu*ent$ w/ic/ are a..ro2e&. No ./a$e i$ co*.lete until t/e &ocu*entation for t/at ./a$e /a$ been co*.lete& an& .ro&uct$ of t/at ./a$e /a2e been a..ro2e&. T/e following ./a$e $/oul& not $tart until t/e .re2iou$ ./a$e /a$ fini$/e&. ,eal .ro8ect$ rarel( follow t/e $e'uential flow t/at t/e *o&el .ro.o$e$. In general t/e$e ./a$e$ o2erla. an& fee& infor*ation to eac/ ot/er. >ence t/ere $/oul& be an ele*ent of iteration an& fee&bac4. 9 *i$ta4e caug/t an( $tage $/oul& be referre& bac4 to t/e $ource an& all t/e $ub$e'uent $tage$ nee& to be re2i$ite& an& corre$.on&ing &ocu*ent$ $/oul& be u.&ate& accor&ingl(. T/i$ fee&bac4 .at/ i$ $/own in t/e following &iagra*.
)ecau$e of t/e co$t$ of .ro&ucing an& a..ro2ing &ocu*ent$% iteration$ are co$tl( an& re'uire $ignificant rewor4. T/e ;aterfall #o&el i$ a &ocu*entation-&ri2en *o&el. It t/erefore generate$ co*.lete an& co*.re/en$i2e &ocu*entation an& /ence *a4e$ t/e *aintenance ta$4 *uc/ ea$ier. It /owe2er $uffer$ fro* t/e fact t/at t/e client fee&bac4 i$ recei2e& w/en t/e .ro&uct i$ finall( &eli2ere& an& /ence an( error$ in t/e re'uire*ent $.ecification are not &i$co2ere& until t/e .ro&uct i$ $ent to t/e client after co*.letion. T/i$ t/erefore /a$ *a8or ti*e an& co$t relate& con$e'uence$.
16
VU
Integrating t!e
7e$.ite t/e *an( $ucce$$e$ of t/e waterfall *o&el% it /a$ a *a8or &rawbac4 in t/at t/e &eli2ere& .ro&uct *a( not fulfil t/e client:$ nee&$. Ane $olution to t/i$ i$ to co*bine ra.i& .rotot(.ing wit/ t/e waterfall *o&el. In t/i$ a..roac/% ra.i& .rotot(.ing can be u$e& a$ a re'uire*ent gat/ering tec/ni'ue w/ic/ woul& t/en be followe& b( t/e acti2itie$ .erfor*e& in t/e waterfall *o&el.
17
VU
ra.i& return on in2e$t*ent. >owe2er% t/i$ *o&el nee&$ an& o.en arc/itecture to allow integration of $ub$e'uent buil&$ to (iel& t/e bigger .ro&uct. 9 nu*ber of 2ariation$ are u$e& in ob8ect-oriente& life c(cle *o&el$. T/ere are two fun&a*ental a..roac/e$ to t/e incre*ental &e2elo.*ent. In t/e fir$t ca$e% t/e re'uire*ent$% $.ecification$% an& arc/itectural &e$ign for t/e w/ole .ro&uct are co*.lete& before i*.le*entation of t/e 2ariou$ buil&$ co**ence$.
18
VU
In a *ore ri$4( 2er$ion% once t/e u$er re'uire*ent$ /a2e been elicite&% t/e $.ecification$ of t/e fir$t buil& are &rawn u.. ;/en t/i$ /a$ been co*.lete&% t/e $.ecification tea*
Build 1 Specification Design Implementation, integration Deliver to client
Build 2 Specification Build 3 Specification Design Implementation, integration Deliver to client Design Implementation, integration Deliver to client
turn$ to t/e $.ecification of t/e $econ& buil& w/ile t/e &e$ign tea* &e$ign$ t/e fir$t buil&. T/u$ t/e 2ariou$ buil&$ are con$tructe& in .arallel% wit/ eac/ tea* *a4ing u$e of t/e infor*ation gaine& in t/e all t/e .re2iou$ buil&$. T/i$ a..roac/ incur$ t/e ri$4 t/at t/e re$ulting buil& will not fit toget/er an& /ence re'uire$ careful *onitoring.
19
VU
S*iral -odel
T/i$ *o&el wa$ &e2elo.e& b( )arr( )oe/*. T/e *ain i&ea of t/i$ *o&el i$ to a2ert ri$4 a$ t/ere i$ alwa($ an ele*ent of ri$4 in &e2elo.*ent of $oftware. =or e5a*.le% 4e( .er$onnel *a( re$ign at a critical 8uncture% t/e *anufacturer of t/e $oftware &e2elo.*ent *a( go ban4ru.t% etc. In it$ $i*.lifie& for*% t/e S.iral #o&el i$ ;aterfall *o&el .lu$ ri$4 anal($i$. In t/i$ ca$e eac/ $tage i$ .rece&e& b( i&entification of alternati2e$ an& ri$4 anal($i$ an& i$ t/en followe& b( e2aluation an& .lanning for t/e ne5t ./a$e. If ri$4$ cannot be re$ol2e&% .ro8ect i$ i**e&iatel( ter*inate&. T/i$ i$ &e.icte& in t/e following &iagra*.
,i$4 9nal($i$
9$ can be $een% a S.iral #o&el /a$ two &i*en$ion$. ,a&ial &i*en$ion re.re$ent$ t/e cu*ulati2e co$t to &ate an& t/e angular &i*en$ion re.re$ent$ t/e .rogre$$ t/roug/ t/e $.iral. Eac/ ./a$e begin$ b( &eter*ining ob8ecti2e$ of t/at ./a$e an& at eac/ ./a$e a new .roce$$ *o&el *a( be followe&.
20
VU
T/e *ain $trengt/ of t/e S.iral #o&el co*e$ fro* t/e fact t/at it i$ 2er( $en$iti2e to t/e ri$4. )ecau$e of t/e $.iral nature of &e2elo.*ent it i$ ea$( to 8u&ge /ow *uc/ to te$t an& t/ere i$ no &i$tinction between &e2elo.*ent an& *aintenance. It /owe2er can onl( be u$e& for large-$cale $oftware &e2elo.*ent an& t/at too for internal Hin-/ou$eJ $oftware onl(.
21
VU
22
VU
e:tre'e 1rogra''ing
It i$ a $o*ew/at contro2er$ial new a..roac/. In t/i$ a..roac/ u$er re'uire*ent$ are ca.ture& t/roug/ $torie$ w/ic/ are t/e $cenario$ .re$enting t/e feature$ nee&e& b( t/e clientL E$ti*ate for &uration an& co$t of eac/ $tor( i$ t/en carrie& out. Storie$ for t/e ne5t buil& are $electe&. T/en eac/ buil& i$ &i2i&e& into ta$4$. Te$t ca$e$ for ta$4 are &rawn u. fir$t before an& &e2elo.*ent an& continuou$ te$ting i$ .erfor*e& t/roug/out t/e &e2elo.*ent .roce$$.
Architectural s#ike )ser stories
Release Planning
Iteration
Acce#tance test
#ike
mall release
Ane 2er( i*.ortant feature of eMtre*e .rogra**ing i$ t/e conce.t of .air .rogra**ing. In t/i$% a tea* of two &e2elo.er$ &e2elo. t/e $oftware% wor4ing in tea* a$ a .air to t/e e5tent t/at t/e( e2en $/are a $ingle co*.uter. In eMtere*e 3rogra**ing *o&el% co*.uter$ are .ut in center of large roo* line& wit/ cubicle$ an& client re.re$entati2e i$ alwa($ .re$ent. Ane 2er( i*.ortant re$triction i*.o$e& in t/e *o&el i$ t/at no tea* i$ allowe& to wor4 o2erti*e for 2 $ucce$$i2e wee4$. M3 /a$ /a& $o*e $ucce$$e$. It i$ goo& w/en re'uire*ent$ are 2ague or c/anging an& t/e o2erall $co.e of t/e .ro8ect i$ li*ite&. It i$ /owe2er too $oon to e2aluate M3.
.ountain -odel
=ountain *o&el i$ anot/er ob8ect-oriente& lifec(cle *o&el. T/i$ i$ &e.icte& in t/e following &iagra*.
23
VU
Maintenance
Further de"elo#ment
*#erations
*!ject(oriented analysis
Requirement
In t/i$ *o&el t/e circle$ re.re$enting t/e 2ariou$ ./a$e$ o2erla.% e5.licitl( re.re$enting an o2erla. between acti2itie$. T/e arrow$ wit/in a ./a$e re.re$ent iteration wit/in t/e ./a$e. T/e *aintenance c(cle i$ $*aller% to $(*boli+e re&uce& *aintenance effort w/en t/e ob8ect oriente& .ara&ig* i$ u$e&.
24
VU
T/e criteria to be u$e& for &eci&ing on a *o&el inclu&e t/e organi+ation% it$ *anage*ent% $4ill$ of t/e e*.lo(ee$% an& t/e nature of t/e .ro&uct. No $ingle *o&el *a( fulfill t/e nee&$ in a gi2en $ituation. It *a( t/erefore be be$t to &e2i$e a lifec(cle *o&el tune& to (our own nee&$ b( creating a D#i5-an&-*atc/E life-c(cle *o&el.
25
VU
0erification i$ .erfor*e& at t/e en& of eac/ ./a$e w/erea$ 2ali&ation i$ .erfor*e& before &eli2ering t/e .ro&uct to t/e client. Si*ilarl(% e2er( ./a$e *u$t be full( &ocu*ente& before $tarting t/e ne5t ./a$e. It i$ i*.ortant to note t/at .o$t.one& &ocu*entation *a( ne2er be co*.lete& a$ t/e re$.on$ible in&i2i&ual *a( lea2e. 7ocu*entation i$ i*.ortant a$ t/e .ro&uct i$ con$tantl( c/angingNwe nee& t/e &ocu*entation to &o t/i$. T/e &e$ign Hfor e5a*.leJ will be *o&ifie& &uring &e2elo.*ent% but t/e original &e$igner$ *a( not be a2ailable to &ocu*ent it. T/e following table $/ow$ t/e @9 an& &ocu*entation acti2itie$ a$$ociate& wit/ eac/ $tage.
3/a$e ,e'uire*ent 7efinition =unctional S.ecification 7e$ign Co&ing 7ocu*ent$ $ $ $ $ $ $ $ $ $ $ $ $ ,a.i& .rotot(.e% or ,e'uire*ent$ &ocu*ent S.ecification &ocu*ent H$.ecification$J Software 3ro&uct #anage*ent 3lan 9rc/itectural 7e$ign 7etaile& 7e$ign Source co&e Te$t ca$e$ Source co&e Te$t ca$e$ C/ange recor& ,egre$$ion te$t ca$e$ @9 $ $ $ $ $ $ $ $ $ $ $ $ $ ,a.i& .rotot(.e ,e2iew$ Traceabilit( =S ,e2iew C/ec4 t/e S3#3 Traceabilit( ,e2iew Traceabilit( ,e2iew Te$ting Integration te$ting 9cce.tance te$ting ,egre$$ion te$ting
Integration #aintenance
26
VU
VU
.ro2e to be &ifficult to /an&le. ,e$ultantl(% it *a( totall( blow (ou off t/e trac4. So% t/e .ro8ect *anager $/oul& be careful in c/oo$ing t/e i*.le*entation tec/nolog( an& *u$t ta4e .ro.er $afeguar& *ea$ure$. + S($te* con$traint$ T/e non-functional re'uire*ent or $($te* con$traint$ $.ecif( t/e con&ition$ an& t/e re$triction$ i*.o$e& on t/e $($te*. 9 $($te* t/at fulfil$ all it$ functional re'uire*ent$ but &oe$ not $ati$f( t/e non-functional re'uire*ent$ woul& be re8ecte& b( t/e u$er. + 1$er re'uire*ent$ 9 $($te* /a$ to $ati$f( it$ u$er re'uire*ent$. =ailing to &o $o woul& ren&er t/i$ $($te* unu$able. + 92ailable re$ource$ 9 .ro8ect /a$ to be &e2elo.e& u$ing t/e a2ailable re$ource$ w/o 4now t/e &o*ain a$ well a$ t/e tec/nolog(. T/e .ro8ect *anager /a$ to en$ure t/at t/e re'uire& nu*ber of re$ource$ wit/ a..ro.riate $4ill-$et i$ a2ailable to t/e .ro8ect.
!2 1ro9ect% .ail=
9 .ro8ect *anager i$ ta$4e& to en$ure t/e $ucce$$ful &e2elo.*ent of a .ro&uct. Succe$$ cannot be attaine& wit/out un&er$tan&ing t/e rea$on$ for failure. T/e *ain rea$on$ for t/e failure of $oftware .ro8ect$ are6 1. c/anging cu$to*er re'uire*ent$ 2. a*biguou$Oinco*.lete re'uire*ent$ - Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
28
CS605 Software Engineering-II 3. 4. 5. 6. !. . unreali$tic &ea&line an /one$t un&ere$ti*ate of effort .re&ictable an&Oor un.re&ictable ri$4$ tec/nical &ifficultie$ *i$co**unication a*ong .ro8ect $taff failure in .ro8ect *anage*ent
VU
T/e fir$t two .oint$ relate to goo& re'uire*ent engineering .ractice$. 1n$table u$er re'uire*ent$ an& continuou$ re'uire*ent cree. /a$ been i&entifie& a$ t/e to. *o$t rea$on for .ro8ect failure. 9*biguou$ an& inco*.lete re'uire*ent$ lea& to un&e$irable .ro&uct t/at i$ re8ecte& b( t/e u$er. 9$ &i$cu$$e& earlier% &eli2er( &ea&line &irectl( influence$ t/e re$ource$ an& 'ualit(. ;it/ a reali$tic &ea&line% c/ance$ of &eli2ering t/e .ro&uct wit/ /ig/ 'ualit( an& rea$onable re$ource$ increa$e tre*en&ou$l( a$ co*.are& to an unreali$tic &ea&line. 9n unreali$tic &ea&line coul& be enforce& b( t/e *anage*ent or t/e client or it coul& be &ue to error in e$ti*ation. In bot/ t/e$e ca$e$ it often re$ult$ in &i$a$ter for t/e .ro8ect. 9 .ro8ect *anager w/o i$ not .re.are& an& wit/out a contingenc( .lan for all $ort$ of .re&ictable an& un.re&ictable ri$4$ woul& .ut t/e .ro8ect in 8eo.ar&( if $uc/ a ri$4 $/oul& /a..en. ,i$4 a$$e$$*ent an& antici.ation of tec/nical an& ot/er &ifficultie$ allow$ t/e .ro8ect *anager to co.e wit/ t/e$e $ituation$. #i$co**unication a*ong t/e .ro8ect $taff i$ anot/er 2er( i*.ortant rea$on for .ro8ect failure. Lac4 of .ro.er coor&ination an& co**unication in a .ro8ect re$ult$ in wa$tage of re$ource$ an& c/ao$.
1eo*le
Software &e2elo.*ent i$ a /ig/l( .eo.le inten$i2e acti2it(. In t/i$ bu$ine$$% t/e $oftware factor( co*.ri$e$ of t/e .eo.le wor4ing t/ere. >ence ta4ing care of t/e fir$t 3% t/at i$ .eo.le% $/oul& ta4e t/e /ig/e$t .riorit( on a .ro8ect *anager:$ agen&a.
1roduct
T/e .ro&uct i$ t/e outco*e of t/e .ro8ect. It inclu&e$ all 4in&$ of t/e $oftware $($te*$. No *eaningful .lanning for a .ro8ect can be carrie&-out until all t/e &i*en$ion$ of t/e .ro&uct inclu&ing it$ functional a$ well a$ non-functional re'uire*ent$ are un&er$too& an& all tec/nical an& *anage*ent con$traint$ are i&entifie&.
1roce%%
Ance t/e .ro&uct ob8ecti2e$ an& $co.e /a2e been &eter*ine&% a .ro.er $oftware &e2elo.*ent .roce$$ an& lifec(cle *o&el *u$t be c/o$en to i&entif( t/e re'uire& wor4 .ro&uct$ an& &efine t/e *ile$tone$ in or&er to en$ure $trea*line& &e2elo.*ent acti2itie$. It inclu&e$ t/e $et of all t/e fra*ewor4 acti2itie$ an& $oftware engineering ta$4$ to get t/e 8ob &one.
29
VU
1ro9ect
9 .ro8ect co*.ri$e$ of all wor4 t/e re'uire& to *a4e t/e .ro&uct a realit(. In or&er to a2oi& failure% a .ro8ect *anager an& $oftware engineer i$ re'uire& to buil& t/e $oftware .ro&uct in a controlle& an& organi+e& fa$/ion an& run it li4e ot/er .ro8ect$ foun& in *ore concrete &o*ain$. ;e now &i$cu$$ t/e$e 4 in *ore &etail.
1eo*le
In a $tu&( .ubli$/e& b( IEEE% t/e .ro8ect tea* wa$ i&entifie& b( t/e $enior e5ecuti2e$ a$ t/e *o$t i*.ortant contributor to a $ucce$$ful $oftware .ro8ect. >owe2er% unfortunatel(% .eo.le are often ta4en for grante& an& &o no get t/e attention an& focu$ t/e( &e$er2e. T/ere are a nu*ber of .la(er$ t/at .artici.ate in $oftware .roce$$ an& influence t/e outco*e of t/e .ro8ect. T/e$e inclu&e $enior *anager$% .ro8ect Htec/nicalJ *anager$% .ractitioner$% cu$to*er$% an& en&-u$er$. Senior *anager$ &efine t/e bu$ine$$ 2i$ion w/erea$ t/e .ro8ect *anager$ .lan% *oti2ate% organi+e an& control t/e .ractitioner$ w/o wor4 to &e2elo. t/e $oftware .ro&uct. To be effecti2e% t/e .ro8ect tea* *u$t be organi+e& to u$e eac/ in&i2i&ual to t/e be$t of /i$O/er abilitie$. T/i$ 8ob i$ carrie& out b( t/e tea* lea&er.
Tea' Leader
3ro8ect *anage*ent i$ a .eo.le inten$i2e acti2it(. It nee&$ t/e rig/t *i5 of .eo.le $4ill$. T/erefore% co*.etent .ractitioner$ often *a4e .oor tea* lea&er$. Lea&er$ $/oul& a..l( a .roble* $ol2ing *anage*ent $t(le. T/at i$% a .ro8ect *anager $/oul& concentrate on un&er$tan&ing t/e .roble* to be $ol2e&% *anaging t/e flow of i&ea$% an& at t/e $a*e ti*e% letting e2er(one on t/e tea* 4now t/at 'ualit( count$ an& t/at it will not be co*.ro*i$e&. #AI *o&el of lea&er$/i. &e2elo.e& b( ;einberg $ugge$t t/at a lea&er$/i. nee&$ #oti2ation% Argani+ation% an& Inno2ation. -oti,ation i$ t/e abilit( to encourage tec/nical .eo.le to .ro&uce to t/eir be$t. /rgani8ation i$ t/e abilit( to *ol& t/e e5i$ting .roce$$e$ Hor in2ent new one$J t/at will enable t/e initial conce.t to be tran$late& into a final .ro&uct% an& Idea or Inno,ation i$ t/e abilit( to encourage .eo.le to create an& feel creati2e. It i$ $ugge$te& t/at $ucce$$ful .ro8ect *anager$ a..l( a .roble* $ol2ing *anage*ent $t(le. T/i$ in2ol2e$ &e2elo.ing an un&er$tan&ing of t/e .roble* an& *oti2ating t/e tea* to generate i&ea$ to $ol2e t/e .roble*. E&ge*on $ugge$t$ t/at t/e following c/aracteri$tic$ are nee&e& to beco*e an effecti2e .ro8ect *anager6 $ $ 3roble* Sol2ing + S/oul& be able to &iagno$e tec/nical an& organi+ational i$$ue$ an& be willing to c/ange &irection if nee&e&. #anagerial I&entit( + #u$t /a2e t/e confi&ence to ta4e control w/en nece$$ar(
30
VU
9c/ie2e*ent + ,ewar& initiati2e Hcontrolle& ri$4 ta4ingJ an& acco*.li$/*ent Influence an& tea* buil&ing + #u$t re*ain un&er control in /ig/ $tre$$ con&ition$. S/oul& be able to rea& $ignal$ an& a&&re$$ .eo.le$: nee&$.
7e#arco $a($ t/at a goo& lea&er .o$$e$$e$ t/e following four c/aracteri$tic$6 + >eart6 t/e lea&er $/oul& /a2e a big /eart. + No$e6 t/e lea&er $/oul& /a2e goo& no$e to $.ot t/e trouble an& ba& $*ell in t/e .ro8ect. + Gut6 t/e lea&er $/oul& /a2e t/e abilit( to *a4e 'uic4 &eci$ion$ on gut feeling. + Soul6 t/e lea&er $/oul& be t/e $oul of t/e tea*. If anal(+e& clo$el(% all t/e$e re$earc/er$ $ee* to $a( e$$entiall( t/e $a*e t/ing an& t/e( actuall( co*.le*ent eac/ ot/er:$ .oint of 2iew.
31
VU
Con$tantine $ugge$t$ t/at tea*$ coul& be organi+e& in t/e following generic $tructural .ara&ig*$6 $ $ $ $ clo%ed *aradig'N$tructure$ a tea* along a tra&itional /ierarc/( of aut/orit( rando' *aradig'N$tructure$ a tea* loo$el( an& &e.en&$ on in&i2i&ual initiati2e of t/e tea* *e*ber$ o*en *aradig'Natte*.t$ to $tructure a tea* in a *anner t/at ac/ie2e$ $o*e of t/e control$ a$$ociate& wit/ t/e clo$e& .ara&ig* but al$o *uc/ of t/e inno2ation t/at occur$ w/en u$ing t/e ran&o* .ara&ig* %2nc!ronou% *aradig'Nrelie$ on t/e natural co*.art*entali+ation of a .roble* an& organi+e$ tea* *e*ber$ to wor4 on .iece$ of t/e .roble* wit/ little acti2e co**unication a*ong t/e*$el2e$
#antei $ugge$t$ t/e following t/ree generic tea* organi+ation$6 $ 7e*ocratic &ecentrali+e& H77J In t/i$ organi+ation t/ere i$ no .er*anent lea&er an& ta$4 coor&inator$ are a..ointe& for $/ort &uration. 7eci$ion$ on .roble*$ an& a..roac/ are *a&e b( grou. con$en$u$ an& co**unication a*ong tea* i$ /ori+ontal. $ Controlle& &ecentrali+e& HC7J In C7% t/ere i$ a &efine& lea&er w/o coor&inate$ $.ecific ta$4$. >owe2er% .roble* $ol2ing re*ain$ a grou. acti2it( an& co**unication a*ong $ubgrou.$ an& in&i2i&ual$ i$ /ori+ontal. 0ertical co**unication along t/e control /ierarc/( al$o occur$. $ Controlle& centrali+e& HCCJ In a Controlle& Centrali+e& $tructure% to. le2el .roble* $ol2ing an& internal tea* coor&ination are *anage& b( t/e tea* lea&er an& co**unication between t/e lea&er an& tea* *e*ber$ i$ 2ertical. Centrali+e& $tructure$ co*.lete ta$4$ fa$ter an& are *o$t u$eful for /an&ling $i*.le .roble*$. An t/e ot/er /an&% &ecentrali+e& tea*$ generate *ore an& better $olution$ t/an in&i2i&ual$ an& are *o$t u$eful for co*.le5 .roble*$ =or t/e tea* *orale .oint of 2iew% 77 i$ better.
32
VU
Tec/ni'ue$ t/at fall abo2e t/e regre$$ion line (iel& *ore 2alue to u$e ratio a$ co*.are& to t/e one$ below t/e line.
33
VU
In or&er to &e2elo. an e$ti*ate an& .lan for t/e .ro8ect% t/e $co.e of t/e .roble* *u$t be e$tabli$/e&. T/i$ inclu&e$ conte5t% infor*ation ob8ecti2e$% an& function an& .erfor*ance re'uire*ent$. T/e e$ti*ate an& .lan i$ t/en &e2elo.e& b( &eco*.o$ing t/e .roble* an& e$tabli$/ing a functional .artitioning.
T!e 1roce%%
T/e ne5t $te. i$ to &eci&e w/ic/ .roce$$ *o&el to .ic4. T/e .ro8ect *anager /a$ to loo4 at t/e c/aracteri$tic$ of t/e .ro&uct to be built an& t/e .ro8ect en2iron*ent. =or e5a*.le$% for a relati2el( $*all .ro8ect t/at i$ $i*ilar to .a$t effort$% &egree of uncertaint( i$ *ini*i+e& an& /ence ;aterfall or linear $e'uential *o&el coul& be u$e&. =or tig/t ti*eline$% /ea2il( co*.art*entali+e&% an& 4nown &o*ain% ,97 *o&el woul& be *ore $uitable. 3ro8ect$ wit/ large functionalit(% 'uic4 turn aroun& ti*e are be$t &e2elo.e& incre*entall( an& for a .ro8ect in w/ic/ re'uire*ent$ are uncertain% .rotot(.ing *o&el will be *ore $uitable.
34
VU
5@@ 1rinci*le
)arr( )oe/* /a$ $ugge$te& a $($te*atic a..roac/ to .ro8ect *anage*ent. It i$ 4nown a$ t/e ;;;;;>> .rinci.le. It co*.ri$e$ of ! 'ue$tion$. =in&ing t/e an$wer$ to t/e$e ! 'ue$tion$ i$ e$$entiall( all a .ro8ect *anager /a$ to &o. T/e$e are6 $ @A i$ t/e $($te* being &e2elo.e&L $ @#T will be &oneL $ )( @ENL $ @/ i$ re$.on$ible for a functionL $ @E4E t/e( are organi+ationall( locate&L $ @/ will t/e 8ob be &one tec/nicall( an& *anageriall(L $ @/ -UC@ of eac/ re$ource He.g.% .eo.le% $oftware% tool$% &ataba$eJ will be nee&e&L )oe/*:$ ;5>> .rinci.le i$ a..licable% regar&le$$ of t/e $i+e an& co*.le5it( of t/e .ro8ect an& .ro2i&e e5cellent .lanning outline.
Critical 1ractice%
T/e 9irlie Council /a$ &e2elo.e& a li$t of critical $ucce$$ .ractice$ t/at *u$t be .re$ent for $ucce$$ful .ro8ect *anage*ent. T/e$e are6 $ =or*al ri$4 anal($i$ $ E*.irical co$t an& $c/e&ule e$ti*ation $ #etric$-ba$e& .ro8ect *anage*ent $ Earne& 2alue trac4ing $ 7efect trac4ing again$t 'ualit( target$ $ 3eo.le aware .ro8ect *anage*ent
35
VU
=in&ing t/e $olution to t/e$e .ractice$ i$ t/e 4e( to $ucce$$ful .ro8ect$. ;e:ll t/erefore $.en& a con$i&erable a*ount of ti*e in elaborating t/e$e .ractice$.
36
VU
9 nu*ber of tec/ni'ue$ an& tool$ can be u$e& in e$ti*ating t/e $i+e of t/e $oftware. T/e$e inclu&e6 1. Line$ of co&e HLACJ 2. Nu*ber of ob8ect$ 3. Nu*ber of G1I$ 4. Nu*ber of &ocu*ent .age$ 5. =unctional .oint$ H=3J
37
VU
=3 *ea$ure$ t/e $i+e of t/e functionalit( .ro2i&e& b( t/e $oftware. T/e functionall( i$ *ea$ure& a$ a function of t/e &ata an& t/e o.eration$ .erfor*e& on t/at &ata. T/e *ea$ure i$ in&e.en&ent of t/e tool an& tec/nolog( u$e& an& /ence .ro2i&e$ a con$i$tent *ea$ure for co*.ari$on between 2ariou$ organi+ation$ an& .ro8ect$. T/e bigge$t a&2antage of =3 o2er LAC i$ t/at LAC can be counte& onl( 9=TE, t/e co&e /a$ been &e2elo.e& w/ile =3 can be counte& e2en at t/e re'uire*ent ./a$e an& /ence can be u$e& for .lanning an& e$ti*ation w/ile t/e LAC cannot be u$e& for t/i$ .ur.o$e. 9not/er *a8or &i$tinction between t/e =3 an& LAC i$ t/at t/e LAC *ea$ure$ t/e a..lication fro* a &e2elo.erQ$ .er$.ecti2e w/ile t/e =3 i$ a *ea$ure of t/e $i+e of t/e functionalit( fro* t/e u$erQ$ .er$.ecti2e. T/e u$erQ$ 2iew% a$ &efine& b( I=31G% i$ a$ follow$6 9 user view i$ a &e$cri.tion of t/e bu$ine$$ function$ an& i$ a..ro2e& b( t/e u$er. It re.re$ent$ a for*al &e$cri.tion of t/e u$er:$ bu$ine$$ nee&$ in t/e u$er:$ language. It can 2ar( in ./($ical for* He.g.% catalog of tran$action$% .ro.o$al$% re'uire*ent$ &ocu*ent% e5ternal $.ecification$% &etaile& $.ecification$% u$er /an&boo4J. 7e2elo.er$ tran$late t/e u$er infor*ation into infor*ation tec/nolog( language in or&er to .ro2i&e a $olution. =unction .oint count$ t/e a..lication $i+e fro* t/e u$er:$ .oint of 2iew. It i$ acco*.li$/e& u$ing t/e infor*ation in a language t/at i$ co**on to bot/ u$erH$J an& &e2elo.er$. T/erefore% =unction 3oint 9nal($i$ *ea$ure$ t/e $i+e of t/e functionalit( &eli2ere& an& u$e& b( t/e en& u$er a$ o..o$e& to t/e 2olu*e of t/e artifact$ an& co&e.
38
VU
ource Code i-e Acti"ity ( in #erson months Requirements Design Coding Documentation Integration and Testing Management Total 4ffort Total Cost Cost Per 6ine 6ines Per Person(Month
Assem!ler ,ersion Ada ,ersion Difference .//'/// 01'/// (21'/// ./ 01 .// .1 01 01 0// 5.'///'/// 5./ 1// ./ 01 0/ .1 .1 .1 .// 51//'/// 50/ 01/ / / (3/ / (./ (./ (.// (51//'/// 5./ (01/
39
VU
3. Go2ern*ent of t/e 9u$tralian $tate 0ictoria /a$ been u$ing =3 $ince 1""! for *anaging an& out$ourcing .ro8ect$ to t/e tune of 1SS 50 #illion e2er( (ear. 4. In t/e 1S $e2eral large go2ern*ent &e.art*ent$ inclu&ing I,S /a2e a&o.te& =3 anal($i$ a$ a $tan&ar& for out$ourcing% *ea$ure*ent% an& control of $oftware .ro8ect$. 5. 9 nu*ber of big organi+ation$ inclu&ing 7igital Cor.oration an& I)# /a2e been u$ing =3 for t/eir internal u$e for t/e la$t *an( (ear$. 1$age of =3 inclu&e$6 Effort Sco.e E$ti*ation 3ro8ect 3lanning 7eter*ine t/e i*.act of a&&itional or c/ange& re'uire*ent$ ,e$ource 3lanningO9llocation )enc/*ar4ing an& target $etting Contract Negotiation$ =ollowing i$ a li$t of $o*e of t/e =3 ba$e& *etric$ u$e& for t/e$e .ur.o$e$6 Si+e F =unction 3oint$ 7efect$ F 3er =unction 3oint Effort F Staff-#ont/$ 3ro&ucti2it( F =unction 3oint$ .er Staff-#ont/ 7uration F Sc/e&ule HCalen&arJ #ont/$ Ti*e Efficienc( F =unction 3oint$ .er #ont/ Co$t F 3er =unction
40
VU
IL= EI=
T/e$e $te.$ are elaborate& in t/e following $ub$ection$. T/e ter*$ an& &efinition$ are t/e one$ u$e& b( I=31G an& /a2e been ta4en &irectl( fro* t/e I=31G =unction 3oint Counting 3ractice$ #anual HC3#J ,elea$e 4.1. T/e following can t/erefore be treate& a$ an abri&ge& 2er$ion of t/e I=31G C3# ,elea$e 4.1.
41
VU
bJ all t/e function$ &eli2ere& cJ T/e a..lication boun&ar( of t/e two count$ i$ t/e $a*e an& i$ in&e.en&ent of t/e scope.
Control Infor'ation
- Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
42
VU
(ontrol &nformation i$ &ata t/at influence$ an ele*entar( .roce$$ of t/e a..lication being counte&. It $.ecifie$ w/at% w/en% or /ow &ata i$ to be .roce$$e&. =or e5a*.le% $o*eone in t/e .a(roll &e.art*ent e$tabli$/e$ .a(*ent c(cle$ to $c/e&ule w/en t/e e*.lo(ee$ for eac/ location are to be .ai&. T/e .a(*ent c(cle% or $c/e&ule% contain$ ti*ing infor*ation t/at affect$ w/en t/e ele*entar( .roce$$ of .a(ing e*.lo(ee$ occur$.
U%er Identifiable
T/e ter* user identifiable refer$ to &efine& re'uire*ent$ for .roce$$e$ an&Oor grou.$ of &ata t/at are agree& u.on% an& un&er$too& b(% bot/ t/e u$erH$J an& $oftware &e2elo.erH$J. =or e5a*.le% u$er$ an& $oftware &e2elo.er$ agree t/at a >u*an ,e$ource$ 9..lication will *aintain an& $tore E*.lo(ee infor*ation in t/e a..lication.
-aintained
T/e ter* maintained i$ t/e abilit( to *o&if( &ata t/roug/ an ele*entar( .roce$$. E5a*.le$ inclu&e% but are not li*ite& to% a&&% c/ange% &elete% .o.ulate% re2i$e% u.&ate% a$$ign% an& create.
Ele'entar2 1roce%%
9n elementary process i$ t/e $*alle$t unit of acti2it( t/at i$ *eaningful to t/e u$erH$J. =or e5a*.le% a u$er re'uire$ t/e abilit( to a&& a new e*.lo(ee to t/e a..lication. T/e u$er &efinition of e*.lo(ee inclu&e$ $alar( an& &e.en&ent infor*ation. =ro* t/e u$er .er$.ecti2e% t/e $*alle$t unit of acti2it( i$ to a&& a new e*.lo(ee. 9&&ing one of t/e .iece$ of infor*ation% $uc/ a$ $alar( or &e.en&ent% i$ not an acti2it( t/at woul& 'ualif( a$ an ele*entar( .roce$$. T/e elementary process *u$t be $elf-containe& an& lea2e t/e bu$ine$$ of t/e a..lication being counte& in a con$i$tent $tate. =or e5a*.le% t/e u$er re'uire*ent$ to a&& an e*.lo(ee inclu&e $etting u. $alar( an& &e.en&ent infor*ation. If all t/e e*.lo(ee infor*ation i$ not a&&e&% an e*.lo(ee /a$ not (et been create&. 9&&ing $o*e of t/e infor*ation alone lea2e$ t/e bu$ine$$ of a&&ing an e*.lo(ee in an incon$i$tent $tate. If bot/ t/e e*.lo(ee $alar( an& &e.en&ent infor*ation i$ a&&e&% t/i$ unit of acti2it( i$ co*.lete& an& t/e bu$ine$$ i$ left in a con$i$tent $tate.
43
VU
T/e following li$t outline$ /ow t/e rule$ are .re$ente&6 VWIL= i&entification rule$ VWEI= i&entification rule$ VWCo*.le5it( an& contribution rule$% w/ic/ inclu&e6 VW7ata ele*ent t(.e$ H7ET$J VW,ecor& ele*ent t(.e$ H,ET$J
+ET +efinition
9 data element type i$ a uni'ue u$er recogni+able% non-re.eate& fiel&.
+ET 4ule%
T/e following rule$ a..l( w/en counting 7ET$6 1. Count a 7ET for eac/ uni'ue u$er recogni+able% non-re.eate& fiel& *aintaine& in or retrie2e& fro* t/e IL= or EI= t/roug/ t/e e5ecution of an ele*entar( .roce$$. =or e5a*.le6 9n account nu*ber t/at i$ $tore& in *ulti.le fiel&$ i$ counte& a$ one 7ET.
44
VU
9 before or after i*age for a grou. of 10 fiel&$ *aintaine& for au&it .ur.o$e$ woul& count a$ one 7ET for t/e before i*age Hall 10 fiel&$J an& a$ one 7ET for t/e after i*age Hall 10 fiel&$J for a total of 2 7ET$. T/e re$ultH$J of a calculation fro* an ele*entar( .roce$$% $uc/ a$ calculate& $ale$ ta5 2alue for a cu$to*er or&er *aintaine& on an IL= i$ counte& a$ one 7ET on t/e cu$to*er or&er IL=. 9cce$$ing t/e .rice of an ite* w/ic/ i$ $a2e& to a billing file or fiel&$ $uc/ a$ a ti*e $ta*. if re'uire& b( t/e u$erH$J are counte& a$ 7ET$. If an e*.lo(ee nu*ber w/ic/ a..ear$ twice in an IL= or EI= a$ H1J t/e 4e( of t/e e*.lo(ee recor& an& H2J a foreign 4e( in t/e &e.en&ent recor&% count t/e 7ET onl( once. ;it/in an IL= or EI=% count one 7ET for t/e 12 #ont/l( )u&get 9*ount fiel&$. Count one a&&itional fiel& to i&entif( t/e a..licable *ont/. =or E5a*.le6 2. ;/en two a..lication$ *aintain an&Oor reference t/e $a*e IL=OEI=% but eac/ *aintain$Oreference$ $e.arate 7ET$% count onl( t/e 7ET$ being u$e& b( eac/ a..lication to $i+e t/e IL=OEI=. =or E5a*.le6 9..lication 9 *a( $.ecificall( i&entif( an& u$e an a&&re$$ a$ $treet a&&re$$% cit(% $tate an& +i. co&e. 9..lication ) *a( $ee t/e a&&re$$ a$ one bloc4 of &ata wit/out regar& to in&i2i&ual co*.onent$. 9..lication 9 woul& count four 7ET$C 9..lication ) woul& count one 7ET. 9..lication M *aintain$ an&Oor reference$ an IL= t/at contain$ a SSN% Na*e% Street Na*e% #ail Sto.% Cit(% State% an& Xi.. 9..lication X *aintain$ an&Oor reference$ t/e Na*e% Cit(% an& State. 9..lication M woul& count $e2en 7ET$C 9..lication X woul& count t/ree 7ET$. 3. Count a 7ET for eac/ .iece of &ata re'uire& b( t/e u$er to e$tabli$/ a relation$/i. wit/ anot/er IL= or EI=. In an >, a..lication% an e*.lo(eeQ$ infor*ation i$ *aintaine& on an IL=. T/e e*.lo(ee:$ 8ob na*e i$ inclu&e& a$ .art of t/e e*.lo(eeQ$ infor*ation. T/i$ 7ET i$ counte& becau$e it i$ re'uire& to relate an e*.lo(ee to a 8ob t/at e5i$t$ in t/e organi+ation. T/i$ t(.e of &ata ele*ent i$ referre& to a$ a foreign key. In an ob8ect oriente& HAAJ a..lication% t/e u$er re'uire$ an a$$ociation between ob8ect cla$$e$% w/ic/ /a2e been i&entifie& a$ $e.arate IL=$. Location na*e i$ a 7ET in t/e Location EI=. T/e location na*e i$ re'uire& w/en .roce$$ing e*.lo(ee infor*ationC con$e'uentl(% it i$ al$o counte& a$ a 7ET wit/in t/e E*.lo(ee IL=.
45
VU
4ET 4ule%
One of t/e following rule$ a..lie$ w/en counting ,ET$6 Count a ,ET for eac/ o.tional or *an&ator( $ubgrou. of t/e IL= or EI=. Or If t/ere are no $ubgrou.$% count t/e IL= or EI= a$ one ,ET.
VU
bJ In t/e .roce$$ functional &eco*.o$ition% i&entif( w/ere interface$ occur wit/ t/e u$er an& ot/er a..lication$. cJ ;or4 t/roug/ t/e .roce$$ &iagra* to get /int$. &J Cre&it IL=$ *aintaine& b( *ore t/an one a..lication to eac/ a..lication at t/e ti*e t/e a..lication i$ counte&. Anl( t/e 7ET$ being u$e& b( eac/ a..lication being counte& $/oul& be u$e& to $i+e t/e IL=OEI=. 3. I$ t/e &ata in an IL= *aintaine& t/roug/ an ele*entar( .roce$$ of t/e a..licationL aJ 9n a..lication can u$e an IL= or EI= *ulti.le ti*e$% but (ou count t/e IL= or EI= onl( once. bJ 9n ele*entar( .roce$$ can *aintain *ore t/an one IL=. cJ ;or4 t/roug/ t/e .roce$$ &iagra* to get /int$. &J Cre&it IL=$ *aintaine& b( *ore t/an one a..lication to eac/ a..lication at t/e ti*e t/e a..lication i$ counte&.
Entit2
9n entit( i$ &efine& b( &ifferent .eo.le a$ follow$6 K K K K K K 9 t/ing t/at can be &i$tinctl( i&entifie&. HC/enJ 9n( &i$tingui$/able ob8ect t/at i$ to be re.re$ente& in t/e &ataba$e. H7ateJ 9n( &i$tingui$/able .er$on% .lace% t/ing% e2ent or conce.t about w/ic/ infor*ation i$ 4e.t. H)ruceJ 9 &ata entit( re.re$ent$ $o*e Yt/ingY t/at i$ to be $tore& for later reference. T/e ter* entit( refer$ to t/e logical re.re$entation of &ata. H=in4el$teinJ 9n entit( *a( al$o re.re$ent t/e relation$/i. between two or *ore entitie$% calle& a%%ociati,e entit2. H,eingruberJ 9n entit( *a( re.re$ent a $ub$et of infor*ation rele2ant to an in$tance of an entit(% calle& %ubt2*e entit2. H,eingruberJ
T/at i$% an entit( i$ a .rinci.al &ata ob8ect about w/ic/ infor*ation i$ collecte& t/at i$ a fun&a*ental t/ing of rele2ance to t/e u$er% about w/ic/ a collection of fact$ i$ 4e.t. 9n entit( can be a wea4 entit( or a $trong entit(. 9 wea4 entit( i$ t/e one w/ic/ &oe$ not /a2e an( role in t/e .roble* &o*ain wit/out $o*e ot/er entit(. ;ea4 entitie$ are ,ET$ an& $trong entitie$ are IL=$ an& EI=$. I&entification of wea4 entitie$ i$ t/erefore i*.ortant for &i$tingui$/ing between ,ET$ an& logical file$.
ea( Entitie%
T/ere are t/ree t(.e$ of wea4 entitie$6 9$$ociati2e entit( t(.e$% attributi2e entit( t(.e% an& entit( $ubt(.e. T/e$e are elaborate& a$ follow$6 K #%%ociati,e Entit2 T2*e F 9n entit( w/ic/ &efine$ *an(-to-*an( relation$/i. between two or *ore entitie$. F Stu&ent F cour$e F 3art F &ealer
47
VU
#ttributi,e Entit2 T2*e E 9n entit( t(.e w/ic/ furt/er &e$cribe$ one or *ore c/aracteri$tic$ of anot/er entit(. F 3ro&uct F 3art F 3ro&uct F 3ro&uct 3rice Infor*ation Entit2 Subt2*e F 9 $ub&i2i$ion of entit(. 9 $ubt(.e in/erit$ all t/e attribute$ of it$ .arent entit( t(.e% an& *a( /a2e a&&itional% uni'ue attribute$. F E'*lo2ee 1er'anent E'*lo2ee Contract E'*lo2ee F E'*lo2ee -arried E'*lo2ee Single E'*lo2ee
Logical .ile%
Grou.ing of &ata into logical file$ i$ t/e re$ult of co*bine& effect of two grou.ing *et/o&$6 K >ow &ata i$ acce$$e& a$ a grou. b( ele*entar( .roce$$e$L H.roce$$ &ri2enJ K T/e relation$/i. between t/e entitie$ an& t/eir inter&e.en&enc( ba$e& on bu$ine$$ rule$. H&ata &ri2enJ T/e following gui&eline can be u$e& for t/i$ .ur.o$e6 K 3roce$$ 7ri2en 9..roac/ K 7ata 7ri2en 9..roac/
=or e5a*.le in t/e following $cenario$% t/e fir$t one i$ t/e e5a*.le of entit( &e.en&ence w/ile t/e $econ& one i$ t/e e5a*.le of entit( in&e.en&ence. - Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
48
VU
F E*.lo(ee F C/il& F E*.lo(ee - Co*.an( 9&o.te& C/il& T/e$e conce.t$ are $u**ari+e& in t/e following table6
EC4 Conce*t 3rinci.al &ata ob8ect$ about w/ic/ infor*ation i$ collecte& 9n entit( t(.e w/ic/ contain$ attribute$ w/ic/ furt/er &e$cribe relation$/i.$ between ot/er entitie$ 9n entit( t(.e t/at furt/er &e$cribe$ one or *ore c/aracteri$tic$ of anot/er entit( t(.e 9 &i2i$ion of an entit( t(.e% w/ic/ in/erit$ all t/e attribute$ an& relation$/i.$ of it$ .arent entit( t(.eC *a( /a2e a&&itional% uni'ue attribute$ an& relation$/i.$ EC4 Ter' Entit( or Entit( T(.e 9$$ociati2e entit( t(.e 9ttributi2e entit( t(.e Entit( $ubt(.e .1# Ter' IL= or EI= I.1UF C1- 5.1 +efinition =ile refer$ to a logicall( relate& grou. of &ata an& not t/e ./($ical i*.le*entation of t/o$e grou.$ of &ata. 1$er recogni+able $ubgrou. of &ata ele*ent$ wit/in an IL= or EI= 1$er recogni+able $ubgrou. of &ata ele*ent$ wit/in an IL= or EI= 1$er recogni+able $ubgrou. of &ata ele*ent$ wit/in an IL= or EI=
E)ternal In*ut%
9n e5ternal in.ut HEIJ i$ an ele*entar( .roce$$ t/at .roce$$e$ &ata or control infor*ation t/at co*e$ fro* out$i&e t/e a..lication boun&ar(. T/e .ri*ar( intent of an EI i$ to *aintain one or *ore IL=$ an&Oor to alter t/e be/a2ior of t/e $($te*.
E)ternal /ut*ut%
9n e5ternal out.ut HEAJ i$ an ele*entar( .roce$$ t/at $en&$ &ata or control infor*ation out$i&e t/e a..lication boun&ar(. T/e .ri*ar( intent of an e5ternal out.ut i$ to .re$ent infor*ation to a u$er t/roug/ .roce$$ing logic ot/er t/an% or in a&&ition to% t/e retrie2al of &ata or control infor*ation . T/e .roce$$ing logic *u$t contain at lea$t one *at/e*atical for*ula or calculation% or create &eri2e& &ata. 9n e5ternal out.ut *a( al$o *aintain one or *ore IL=$ an&Oor alter t/e be/a2ior of t/e $($te*.
E)ternal In&uir2
9n e5ternal in'uir( HE@J i$ an ele*entar( .roce$$ t/at $en&$ &ata or control infor*ation out$i&e t/e a..lication boun&ar(. T/e .ri*ar( intent of an e5ternal in'uir( i$ to .re$ent infor*ation to a u$er t/roug/ t/e retrie2al of &ata or control infor*ation fro* an IL= or EI=. T/e .roce$$ing logic contain$ no *at/e*atical for*ula$ or calculation$% an& create$ no &eri2e& &ata. No IL= i$ *aintaine& &uring t/e .roce$$ing% nor i$ t/e be/a2ior of t/e $($te* altere&.
49
VU
t/e *ain &ifference fro* EA$ an& E@$. So*e of t/e &ifference$ between EA$ an& E@$ are t/at an EA *a( .erfor* t/e function$ of altering t/e be/a2ior of t/e $($te* or *aintaining one or *ore IL=$ w/en .erfor*ing t/e .ri*ar( intent of .re$enting infor*ation to t/e u$er. At/er &ifference$ are i&entifie& in t/e $ection below t/at $u**ari+e$ for*$ of .roce$$ing logic u$e& b( eac/ tran$actional function. =unction 9lter t/e be/a2ior of t/e $($te* #aintain one or *ore IL=$ 3re$ent infor*ation to a u$er Tran$actional =unction T(.e EI EA E@ 3I = NO9 3I = NO9 = 3I 3I
Legen&6 3I T/e .ri*ar( intent of t/e tran$actional function t(.e = 9 function of t/e tran$actional function t(.e% but i$ not t/e .ri*ar( intent an& i$ $o*eti*e$ .re$ent NO9 T/e function i$ not allowe& b( t/e tran$actional function t(.e.
1roce%%ing Logic
1. 2. *rocessing logic i$ &efine& a$ re'uire*ent$ $.ecificall( re'ue$te& b( t/e u$er to co*.lete an ele*entar( .roce$$. T/o$e re'uire*ent$ *a( inclu&e t/e following action$6 0ali&ation$ are .erfor*e&. =or e5a*.le% w/en a&&ing a new e*.lo(ee to an organi+ation% t/e e*.lo(ee .roce$$ /a$ .roce$$ing logic t/at 2ali&ate$ t/e infor*ation being a&&e&. #at/e*atical for*ula$ an& calculation$ are .erfor*e&. =or e5a*.le% w/en re.orting on all e*.lo(ee$ wit/in an organi+ation t/e .roce$$ inclu&e$ calculating t/e total nu*ber of $alarie& e*.lo(ee$% /ourl( e*.lo(ee$ an& all e*.lo(ee$. E'ui2alent 2alue$ are con2erte& =or e5a*.le% an ele*entar( .roce$$ reference$ currenc( con2er$ion rate$ fro* 1S &ollar$ to ot/er currencie$. T/e con2er$ion i$ acco*.li$/e& b( retrie2ing 2alue$ fro* table$% $o calculation$ nee& not be .erfor*e&. 7ata i$ filtere& an& $electe& b( u$ing $.ecifie& criteria to co*.are *ulti.le $et$ of &ata. =or e5a*.le% to generate a li$t of e*.lo(ee$ b( a$$ign*ent% an ele*entar( .roce$$ co*.are$ t/e 8ob nu*ber of a 8ob a$$ign*ent to $elect an& li$t$ t/e a..ro.riate e*.lo(ee$ wit/ t/at a$$ign*ent. Con&ition$ are anal(+e& to &eter*ine w/ic/ are a..licable. =or e5a*.le% .roce$$ing logic e5erci$e& b( t/e ele*entar( .roce$$ w/en an e*.lo(ee i$ a&&e& an& will &e.en& on w/et/er an e*.lo(ee i$ .ai& ba$e& on $alar( or /our$ wor4e&. Ane or *ore IL=$ are u.&ate&. =or e5a*.le% w/en a&&ing an e*.lo(ee% t/e ele*entar( .roce$$ u.&ate$ t/e e*.lo(ee IL= to *aintain t/e e*.lo(ee &ata. Ane or *ore IL=$ or EI=$ are reference&. =or e5a*.le% w/en a&&ing an e*.lo(ee% t/e currenc( EI= i$ reference& to u$e t/e correct 1S &ollar con2er$ion rate to &eter*ine an e*.lo(ee:$ /ourl( rate. 7ata or control infor*ation i$ retrie2e&. aJ =or e5a*.le% to 2iew a li$t of .o$$ible .a( gra&e$% .a( gra&e infor*ation i$ retrie2e&. 7eri2e& &ata i$ create& b( tran$for*ing e5i$ting &ata to create a&&itional &ata.
3.
4.
5. 6. !. . ".
50
VU
=or e5a*.le% to &eter*ine H&eri2eJ a .atient:$ regi$tration nu*ber He.g.% S#I?A01J% t/e following &ata i$ concatenate&6 aJ t/e fir$t t/ree letter$ of t/e .atient:$ la$t na*e He.g.% S#I for S*it/J bJ t/e fir$t two letter of t/e .atient:$ fir$t na*e He.g.% ?A for ?o/nJ cJ a uni'ue two-&igit $e'uence nu*ber H$tarting wit/ 01J 10. )e/a2ior of t/e $($te* i$ altere&. =or e5a*.le% t/e be/a2ior of t/e ele*entar( .roce$$ of .a(ing e*.lo(ee$ i$ altere& w/en a c/ange i$ *a&e to .a( t/e* e2er( ot/er =ri&a( 2er$u$ on t/e 15t/ an& t/e la$t &a( of t/e *ont/. 11. 3re.are an& .re$ent infor*ation out$i&e t/e boun&ar(. =or e5a*.le% a li$t of e*.lo(ee$ &i$.la(e& for t/e u$er. 12. Ca.abilit( e5i$t$ to acce.t &ata or control infor*ation t/at enter$ t/e a..lication boun&ar(. =or e5a*.le% a u$er enter$ $e2eral .iece$ of infor*ation to a&& a cu$to*er or&er to t/e $($te*. 13. 7ata i$ re$orte& or rearrange&. =or e5a*.le% a u$er re'ue$t$ t/e li$t of e*.lo(ee$ in al./abetical or&er. Note< ,e$orting or rearranging a $et of &ata &oe$ not i*.act t/e i&entification of t/e t(.e or uni'uene$$ of a tran$actional function.
51
VU
it i$ 'andator2 t/at t/e function t(.e .erfor* t/e for* of .roce$$ing logic. it i$ 'andator2 t/at t/e function t(.e .erfor* at lea$t on of t/e$e H*TJ for*$ of .roce$$ing logic t/e function t(.e can .erfor* t/e for* of .roce$$ing logic% but it i$ not *an&ator(. function t(.e cannot .erfor* t/e for* of .roce$$ing logic
52
VU
VU
.T4 +efinition
9 file type referenced i$ VW9n internal logical file rea& or *aintaine& b( a tran$actional function or VW9n e5ternal interface file rea& b( a tran$actional function
+ET +efinition
9 data element type i$ a uni'ue u$er recogni+able% non-re.eate& fiel&.
=or e5a*.le% in or&er to *aintain t/e 1S /ourl( rate for /ourl( e*.lo(ee$ wor4ing in ot/er countrie$ wit/ ot/er currencie$% t/e local /ourl( rate i$ .ro2i&e& b( t/e u$er. 7uring t/e .roce$$ing of all t/e .iece$ of &ata .ro2i&e& to a&& an e*.lo(ee% a con2er$ion rate i$ retrie2e& fro* t/e currenc( $($te* to calculate t/e 1S /ourl( rate. T/e calculate& 1S /ourl( rate i$ *aintaine& on t/e e*.lo(ee IL= a$ a re$ult of a&&ing t/e e*.lo(ee. T/e 1S /ourl( rate woul& not be counte& a$ a 7ET for t/e EI becau$e it &oe$ not enter t/e boun&ar(% but i$ internall( calculate& Hi.e.% it i$ &eri2e& &ataJ. Count one 7ET for t/e ca.abilit( to $en& a $($te* re$.on$e *e$$age out$i&e t/e a..lication boun&ar( to in&icate an error occurre& &uring .roce$$ing% confir* t/at .roce$$ing i$ co*.lete or 2erif( t/at .roce$$ing $/oul& continue.
54
VU
=or e5a*.le% if a u$er trie$ to a&& an e5i$ting e*.lo(ee to a >u*an ,e$ource$ a..lication% t/e $($te* generate$ one of $e2eral error *e$$age$ an& t/e incorrect fiel& i$ /ig/lig/te&. Count one 7ET t/at inclu&e$ all t/e $($te* re$.on$e$ w/ic/ in&icate t/e error con&ition$% confir* t/at .roce$$ing i$ co*.lete or 2erif( t/at .roce$$ing $/oul& continue. Count one 7ET for t/e abilit( to $.ecif( an action to be ta4en e2en if t/ere are *ulti.le *et/o&$ for in2o4ing t/e $a*e logical .roce$$.
=or e5a*.le% if t/e u$er can initiate t/e a&&ing of an e*.lo(ee clic4ing on t/e AI button or b( .re$$ing a 3= 4e(% count one 7ET for t/e abilit( to initiate t/e .roce$$.
55
VU
=or e5a*.le HEAOE@J% a .ie c/art *ig/t /a2e a categor( label an& a nu*erical e'ui2alent in a gra./ical out.ut. Count two 7ET$ None for &e$ignating t/e categor( an& one for t/e nu*erical 2alue. If a 7ET bot/ enter$ an& e5it$ t/e boun&ar(% count it onl( once for t/e ele*entar( .roce$$. Count one 7ET for t/e ca.abilit( to $en& a $($te* re$.on$e *e$$age out$i&e t/e a..lication boun&ar( to in&icate an error occurre& &uring .roce$$ing% confir* t/at .roce$$ing i$ co*.lete or 2erif( t/at .roce$$ing $/oul& continue.
=or e5a*.le HEAOE@J% if a u$er trie$ to re'ue$t a li$ting% but &oe$ not /a2e acce$$ to t/e infor*ation% count one 7ET for t/e $($te* re$.on$e. Count one 7ET for t/e abilit( to $.ecif( an action to be ta4en e2en if t/ere are *ulti.le *et/o&$ for in2o4ing t/e $a*e logical .roce$$.
=or e5a*.le HEAOE@J% if t/e u$er can initiate t/e generation of a re.ort b( clic4ing on t/e AI button or b( .re$$ing a 3= 4e(% count one 7ET for t/e abilit( to initiate t/e re.ort. 7o not count fiel&$ t/at are retrie2e& or &eri2e& b( t/e $($te* an& $tore& on an IL= &uring t/e ele*entar( .roce$$ if t/e fiel&$ &i& not cro$$ t/e a..lication boun&ar(. =or e5a*.le HEAJ% w/en a .a(c/ec4 i$ .rinte&% a $tatu$ fiel& on t/e e*.lo(ee IL= i$ u.&ate& to in&icate t/at t/e c/ec4 /a$ been .rinte&. 7o not count t/e $tatu$ fiel& a$ a 7ET $ince it &i& not cro$$ t/e boun&ar(. 7o not count literal$ a$ 7ET$.
=or e5a*.le HEAOE@J% literal$ inclu&e re.ort title$% $creen or .anel i&entification% colu*n /ea&ing$% an& fiel& title$. 7o not count .aging 2ariable$ or $($te*-generate& $ta*.$. =or e5a*.le HEAOE@J% $($te*-generate& 2ariable$ an& $ta*.$ inclu&e 3age nu*ber$ 3o$itioning infor*ation $uc/ a$ Y,ow$ 3! to 54 of 211Y 3aging co**an&$ $uc/ a$ .re2iou$% ne5t% an& .aging arrow$ on a G1I a..lication 7ate an& ti*e fiel&$ if t/e( are &i$.la(e&.
VU
I$ &ata recei2e& fro* out$i&e t/e a..lication boun&ar(L o Loo4 at t/e wor4 flow. o I&entif( w/ere t/e u$er an& ot/er a..lication interface$ occur in t/e .roce$$ functional &eco*.o$ition. I$ t/e .roce$$ t/e $*alle$t unit of acti2it( fro* t/e u$er .er$.ecti2eL o Loo4 at t/e &ifferent .a.er or on-line for*$ u$e&. o ,e2iew t/e IL=$ to i&entif( /ow t/e u$er grou.$ t/e infor*ation. o I&entif( w/ere t/e u$er an& ot/er a..lication interface$ occur in t/e .roce$$ functional &eco*.o$ition. o Loo4 at w/at /a..ene& in t/e *anual $($te*. o Note t/at one ./($ical in.ut or tran$action file or $creen can% w/en 2iewe& logicall(% corre$.on& to a nu*ber of EI$% EA$ or E@$. o Note t/at two or *ore ./($ical in.ut or tran$action file$ or $creen$ can corre$.on& to one EI% EA or E@ if t/e .roce$$ing logic i$ i&entical. I$ t/e .roce$$ $elf-containe& an& &oe$ it lea2e t/e bu$ine$$ in a con$i$tent $tateL o ,e2iew ot/er e5ternal in.ut$% e5ternal out.ut$ an& e5ternal in'uirie$ to un&er$tan& /ow t/e u$er wor4$ wit/ t/e infor*ation. o ;or4 t/roug/ t/e .roce$$ &iagra* to get /int$. o Loo4 at w/at /a..ene& in t/e *anual $($te*. o C/ec4 for con$i$tenc( wit/ ot/er &eci$ion$. I$ t/e .roce$$ing logic uni'ue fro* ot/er EI$% EA$ an& E@$L o I&entif( batc/ in.ut$ or out.ut$ ba$e& on t/e .roce$$ing logic re'uire&. o ,e*e*ber t/at $orting or rearranging a $et of &ata &oe$ not *a4e .roce$$ing logic uni'ue. 9re t/e &ata ele*ent$ &ifferent fro* t/o$e for ot/er EI$% EA$ or E@$L o If t/e &ata ele*ent$ a..ear to be a $ub$et of t/e &ata ele*ent$ of anot/er EI% EA% or E@% be $ure two ele*entar( .roce$$e$ are re'uire& b( t/e u$er F one for t/e *ain &ata ele*ent$ an& one for t/e $ub$et$. I&entif( t/e .ri*ar( intent of t/e ele*entar( .roce$$ before cla$$if(ing it a$ an EI% EA% or E@. I&entification of t/e ele*entar( .roce$$He$J i$ ba$e& on a 8oint un&er$tan&ing or inter.retation of t/e re'uire*ent$ between t/e u$er an& t/e &e2elo.er$. Eac/ ele*ent in a functional &eco*.o$ition *a( not *a. to a uni'ue ele*entar( .roce$$. T/e i&entification of t/e ele*entar( .roce$$e$ re'uire$ inter.retation of t/e u$er re'uire*ent$. Count onl( one =T, for eac/ IL=OEI= reference& e2en if t/e IL=OEI= /a$ *ulti.le ,ET$.
57
VU
/ourl( .a( rate w/ic/ are all retrie2e& fro* t/e e*.lo(ee file. T/e re.ort al$o inclu&e$ t/e .ercentage .a( c/ange for t/e e*.lo(ee w/ic/ i$ calculate& fro* t/e &ata on t/e e*.lo(ee file. T/i$ i$ t/e $*alle$t unit of acti2it( fro* t/e u$er:$ .er$.ecti2e% an& no IL= i$ *aintaine& in t/e .roce$$. >owe2er% $ince t/e .roce$$ contain$ a *at/e*atical for*ula% t/i$ i$ one EA. 7eri2e& &ata for an EA &oe$ not /a2e to be &i$.la(e& on t/e out.ut. =or e5a*.le% eac/ *ont/% a re.ort i$ generate& li$ting all e*.lo(ee$ &ue for a..rai$al in t/e ne5t 30 &a($. T/e recor&$ are $electe& b( calculating ne5t a..rai$al &ate ba$e& on t/e e*.lo(ee:$ la$t a..rai$al &ate% w/ic/ i$ a fiel& on t/e e*.lo(ee file% an& t/e current &ate .lu$ 30 &a($. T/i$ woul& be counte& a$ one EA% an& not a$ an E@.
1. +#T# C/--UNIC#TI/NS
T/e data an& control infor*ation u$e& in t/e a..lication are $ent or recei2e& o2er co**unication facilitie$. Ter*inal$ connecte& locall( to t/e control unit are con$i&ere& to u$e co**unication facilitie$. 3rotocol i$ a $et of con2ention$ w/ic/ .er*it t/e tran$fer or e5c/ange of infor*ation between two $($te*$ or &e2ice$. 9ll &ata co**unication lin4$ re'uire $o*e t(.e of .rotocol. Score #%<
0 1 2 3 4 5
9..lication i$ .ure batc/ .roce$$ing or a $tan&alone 3C. 9..lication i$ batc/ but /a$ re*ote &ata entr( or re*ote .rinting. 9..lication i$ batc/ but /a$ re*ote &ata entr( and re*ote .rinting. 9..lication inclu&e$ online &ata collection or T3 Htele.roce$$ingJ front en& to a batc/ .roce$$ or 'uer( $($te*. 9..lication i$ *ore t/an a front-en&% but $u..ort$ onl( one t(.e of T3 co**unication$ .rotocol. 9..lication i$ *ore t/an a front-en&% an& $u..ort$ *ore t/an one t(.e of T3 co**unication$ .rotocol.
0 1 2 3 4 5
9..lication &oe$ not ai& t/e tran$fer of &ata or .roce$$ing function between co*.onent$ of t/e $($te*. 9..lication .re.are$ &ata for en& u$er .roce$$ing on anot/er co*.onent of t/e $($te* $uc/ a$ 3C $.rea&$/eet$ an& 3C 7)#S. 7ata i$ .re.are& for tran$fer% t/en i$ tran$ferre& an& .roce$$e& on anot/er co*.onent of t/e $($te* Hnot for en&-u$er .roce$$ingJ. 7i$tribute& .roce$$ing an& &ata tran$fer are online an& in one &irection onl(. 7i$tribute& .roce$$ing an& &ata tran$fer are online an& in bot/ &irection$. 3roce$$ing function$ are &(na*icall( .erfor*e& on t/e *o$t a..ro.riate co*.onent of t/e $($te*.
58
VU
3. 1E4./4-#NCE
9..lication .erfor*ance ob8ecti2e$% $tate& or a..ro2e& b( t/e u$er% in either re$.on$e or t/roug/.ut% influence Hor will influenceJ t/e &e$ign% &e2elo.*ent% in$tallation% an& $u..ort of t/e a..lication. Score #%< 0 No $.ecial .erfor*ance re'uire*ent$ were $tate& b( t/e u$er. 1 3erfor*ance an& &e$ign re'uire*ent$ were $tate& an& re2iewe& but no $.ecial action$ were re'uire&. 2 ,e$.on$e ti*e or t/roug/.ut i$ critical &uring .ea4 /our$. No $.ecial &e$ign for C31 utili+ation wa$ re'uire&. 3roce$$ing &ea&line i$ for t/e ne5t bu$ine$$ &a(. 3 ,e$.on$e ti*e or t/roug/.ut i$ critical &uring all bu$ine$$ /our$. No $.ecial &e$ign for C31 utili+ation wa$ re'uire&. 3roce$$ing &ea&line re'uire*ent$ wit/ interfacing $($te*$ are con$training. 4 In a&&ition% $tate& u$er .erfor*ance re'uire*ent$ are $tringent enoug/ to re'uire .erfor*ance anal($i$ ta$4$ in t/e &e$ign ./a$e. 5 In a&&ition% .erfor*ance anal($i$ tool$ were u$e& in t/e &e$ign% &e2elo.*ent% an&Oor i*.le*entation ./a$e$ to *eet t/e $tate& u$er .erfor*ance re'uire*ent$.
5. T4#NS#CTI/N 4#TE
T/e tran$action rate i$ /ig/ an& it influence& t/e &e$ign% &e2elo.*ent% in$tallation% an& $u..ort of t/e a..lication. Score #%< 1 2 3 4 3ea4 tran$action .erio& He.g.% *ont/l(% 'uarterl(% $ea$onall(% annuall(J i$ antici.ate&. ;ee4l( .ea4 tran$action .erio& i$ antici.ate&. 7ail( .ea4 tran$action .erio& i$ antici.ate&. >ig/ tran$action rateH$J $tate& b( t/e u$er in t/e a..lication re'uire*ent$ or $er2ice le2el agree*ent$ are /ig/ enoug/ to re'uire .erfor*ance anal($i$ ta$4$ in t/e &e$ign ./a$e.
59
VU
>ig/ tran$action rateH$J $tate& b( t/e u$er in t/e a..lication re'uire*ent$ or $er2ice le2el agree*ent$ are /ig/ enoug/ to re'uire .erfor*ance anal($i$ ta$4$ an&% in a&&ition% re'uire t/e u$e of .erfor*ance anal($i$ tool$ in t/e &e$ign% &e2elo.*ent% an&Oor in$tallation ./a$e$. Anline &ata entr( an& control function$ are .ro2i&e& in t/e a..lication.
Score #%< 0 1 2 3 None of t/e abo2e. Ane to t/ree of t/e abo2e. =our to fi2e of t/e abo2e. Si5 or *ore of t/e abo2e% but t/ere are no $.ecific u$er re'uire*ent$ relate& to efficienc(.
60
VU
Si5 or *ore of t/e abo2e% an& $tate& re'uire*ent$ for en& u$er efficienc( are $trong enoug/ to re'uire &e$ign ta$4$ for /u*an factor$ to be inclu&e& Hfor e5a*.le% *ini*i+e 4e( $tro4e$% *a5i*i+e &efault$% u$e of te*.late$J. Si5 or *ore of t/e abo2e% an& $tate& re'uire*ent$ for en& u$er efficienc( are $trong enoug/ to re'uire u$e of $.ecial tool$ an& .roce$$e$ to &e*on$trate t/at t/e ob8ecti2e$ /a2e been ac/ie2e&.
?. /NLINE U1+#TE
T/e a..lication .ro2i&e$ online u.&ate for t/e internal logical file$. Score #%< 0 1 2 3 4 5 None. Anline u.&ate of one to t/ree control file$ i$ inclu&e&. 0olu*e of u.&ating i$ low an& reco2er( i$ ea$(. Anline u.&ate of four or *ore control file$ i$ inclu&e&. 0olu*e of u.&ating i$ low an& reco2er( ea$(. Anline u.&ate of *a8or internal logical file$ i$ inclu&e&. In a&&ition% .rotection again$t &ata lo$t i$ e$$ential an& /a$ been $.eciall( &e$igne& an& .rogra**e& in t/e $($te*. In a&&ition% /ig/ 2olu*e$ bring co$t con$i&eration$ into t/e reco2er( .roce$$. >ig/l( auto*ate& reco2er( .roce&ure$ wit/ *ini*u* o.erator inter2ention are inclu&e&.
B. C/-1LE: 14/CESSINF
Co*.le5 .roce$$ing i$ a c/aracteri$tic of t/e a..lication. T/e following co*.onent$ are .re$ent6 Sen$iti2e control Hfor e5a*.le% $.ecial au&it .roce$$ingJ an&Oor a..lication $.ecific $ecurit( .roce$$ing E5ten$i2e logical .roce$$ing E5ten$i2e *at/e*atical .roce$$ing #uc/ e5ce.tion .roce$$ing re$ulting in inco*.lete tran$action$ t/at *u$t be .roce$$e& again% for e5a*.le% inco*.lete 9T# tran$action$ cau$e& b( T3 interru.tion% *i$$ing &ata 2alue$% or faile& 2ali&ation$ Co*.le5 .roce$$ing to /an&le *ulti.le in.utOout.ut .o$$ibilitie$% for e5a*.le% *ulti*e&ia% or &e2ice in&e.en&ence
Score #%< 0 1 2 3 4 5 None of t/e abo2e. 9n( one of t/e abo2e. 9n( two of t/e abo2e. 9n( t/ree of t/e abo2e. 9n( four of t/e abo2e. 9ll fi2e of t/e abo2e.
61
VU
10. 4EUS#"ILITA
T/e a..lication an& t/e co&e in t/e a..lication /a2e been $.ecificall( &e$igne&% &e2elo.e&% an& $u..orte& to be u$able in other a..lication$. Score #%< 0 1 2 3 4 5 No reu$able co&e. ,eu$able co&e i$ u$e& wit/in t/e a..lication. Le$$ t/an 10B of t/e a..lication con$i&ere& *ore t/an one u$erQ$ nee&$. Ten .ercent H10BJ or *ore of t/e a..lication con$i&ere& *ore t/an one u$erQ$ nee&$. T/e a..lication wa$ $.ecificall( .ac4age& an&Oor &ocu*ente& to ea$e re-u$e% an& t/e a..lication i$ cu$to*i+e& b( t/e u$er at $ource co&e le2el. T/e a..lication wa$ $.ecificall( .ac4age& an&Oor &ocu*ente& to ea$e re-u$e% an& t/e a..lication i$ cu$to*i+e& for u$e b( *ean$ of u$er .ara*eter *aintenance.
62
VU
1 - 4 Ane% $o*e% or all of t/e following ite*$ a..l( to t/e a..lication. Select all t/at a..l(. Eac/ ite* /a$ a .oint 2alue of one% e5ce.t a$ note& ot/erwi$e. Effecti2e $tart-u.% bac4-u.% an& reco2er( .roce$$e$ were .ro2i&e&% but o.erator inter2ention i$ re'uire&. Effecti2e $tart-u.% bac4-u.% an& reco2er( .roce$$e$ were .ro2i&e&% but no o.erator inter2ention i$ re'uire& Hcount a$ two ite*$J. T/e a..lication *ini*i+e$ t/e nee& for ta.e *ount$. T/e a..lication *ini*i+e$ t/e nee& for .a.er /an&ling. T/e a..lication i$ &e$igne& for unatten&e& o.eration. 1natten&e& o.eration *ean$ no operator intervention i$ re'uire& to o.erate t/e $($te* ot/er t/an to $tart u. or $/ut &own t/e a..lication. 9uto*atic error reco2er( i$ a feature of t/e a..lication.
0 1 2 3 4 5
1$er re'uire*ent$ &o not re'uire con$i&ering t/e nee&$ of *ore t/an one u$erOin$tallation $ite. Nee&$ of *ulti.le $ite$ were con$i&ere& in t/e &e$ign% an& t/e a..lication i$ &e$igne& to o.erate onl( un&er i&entical /ar&ware an& $oftware en2iron*ent$. Nee&$ of *ulti.le $ite$ were con$i&ere& in t/e &e$ign% an& t/e a..lication i$ &e$igne& to o.erate onl( under similar /ar&ware an&Oor $oftware en2iron*ent$. Nee&$ of *ulti.le $ite$ were con$i&ere& in t/e &e$ign% an& t/e a..lication i$ &e$igne& to o.erate under different /ar&ware an&Oor $oftware en2iron*ent$. 7ocu*entation an& $u..ort .lan are .ro2i&e& an& te$te& to $u..ort t/e a..lication at *ulti.le $ite$ an& t/e a..lication i$ a$ &e$cribe& b( 1 or 2. 7ocu*entation an& $u..ort .lan are .ro2i&e& an& te$te& to $u..ort t/e a..lication at *ulti.le $ite$ an& t/e a..lication i$ a$ &e$cribe& b( 3.
VU
Score #%<
0 1 2 3 4 5
None of t/e abo2e. 9n( one of t/e abo2e. 9n( two of t/e abo2e. 9n( t/ree of t/e abo2e. 9n( four of t/e abo2e. 9ll fi2e of t/e abo2e.
Adjusted F Count
Eac/ of t/e$e factor$ i$ $core& ba$e& between 0-5 on t/eir influence on t/e $($te* being counte&. T/e re$ulting $core will increa$e or &ecrea$e t/e 1na&8u$te& =unction 3oint count b( 35B. T/i$ calculation .ro2i&e$ u$ wit/ t/e 9&8u$te& =unction 3oint count. 7egree of Influence H7IJ Z $u* of $core$ of 14 general $($te* c/aracteri$tic$ 0alue 9&8u$t*ent =actor H09=J Z 0.65 P 7I O 100 T/e final =unction 3oint Count i$ obtaine& b( *ulti.l(ing t/e 09= ti*e$ t/e 1na&8u$te& =unction 3oint H1=3J. =3 Z 1=3 T 09=
64
VU
VU
#etric$ gi2e (ou a better in$ig/t into t/e $tate of t/e .roce$$ or .ro&uct. T/e$e in$ig/t$ are not t/e .roble*$ but 8u$t t/e indicators of .roble*$. 9 $oftware engineer$ collect$ *ea$ure$ an& &e2elo.$ *etric$ an& in&icator$. To* Gilb $a($% D9n(t/ing t/at (ou nee& to 'uantif( can be *ea$ure& in $o*e wa( t/at i$ $u.erior to not *ea$uring at allRE T/i$ 'uote /a$ two *e$$age$6 1. 9n(t/ing can be *ea$ure& 2. It i$ alwa($ better to *ea$ure t/an not &oing it e2en if (ou &o not /a2e a goo& *ea$uring &e2iceC it alwa($ gi2e$ (ou $o*e infor*ation t/at (ou can u$e.
66
VU
.actor% related wit! o*eration $ Correctne$$ + T/e e5tent to w/ic/ a .rogra* $ati$fie$ it$ $.ecification$ an& fulfill$ t/e cu$to*er:$ *i$$ion ob8ecti2e$ $ ,eliabilit( + T/e e5tent to w/ic/ a .rogra* can be e5.ecte& to .erfor* it$ inten&e& function wit/ re'uire& .reci$ion. Efficienc( + T/e a*ount of co*.uting re$ource$ re'uire& b( a .rogra* to .erfor* it$ function Integrit( + E5tent to w/ic/ acce$$ to $oftware or &ata b( unaut/ori+e& .er$on$ can be controlle&. 1$abilit( + Effort re'uire& to learn% o.erate% .re.are in.ut% an& inter.ret out.ut of a .rogra*
67
CS605 Software Engineering-II .actor% related wit! re,i%ion $ $ $ #aintainabilit( + Effort re'uire& to locate an& fi5 an error in a .rogra* =le5ibilit( + Effort re'uire& to *o&if( an o.erational .rogra*
VU
Te$tabilit( + Effort re'uire& to te$t a .rogra* to en$ure t/at it .erfor*$ it$ inten&e& function
.actor% related wit! ada*tation $ 3ortabilit( + Effort re'uire& tran$ferring t/e .rogra* fro* one /ar&ware an&Oor $oftware $($te* en2iron*ent to anot/er. ,eu$abilit( + E5tent to w/ic/ a .rogra* can be reu$e& in ot/er a..lication$ Intero.erabilit( + Effort re'uire& to cou.le one $($te* to anot/er.
$ $
It i$ intere$ting to note t/at t/e fiel& of co*.uting an& it$ t/eoretical /a2e gone t/roug/ ./eno*enal c/ange$ but #cCall:$ 'ualit( factor$ are $till a$ rele2ant a$ t/e( were al*o$t 25 (ear$ ago.
!easuring Quality
Gilb e5ten&$ #cCall:$ i&ea an& .ro.o$e$ t/at t/e 'ualit( can be *ea$ure& if we *ea$ure t/e correctne$$% *aintainabilit(% integrit(% an& u$abilit( of t/e .ro&uct. Correctne$$ i$ &efine& a$ t/e &egree to w/ic/ $oftware .erfor*$ it$ function. It can be *ea$ure& in &efect$OILAC or &efect$O=3 w/ere &efect$ are &efine& a$ 2erifie& lac4 of confor*ance to re'uire*ent$. T/e$e are t/e .roble*$ re.orte& b( t/e u$er after relea$e. T/e$e are counte& o2er a $tan&ar& .erio& of ti*e w/ic/ i$ t(.icall( &uring t/e fir$t (ear of o.eration. #aintainabilit( i$ &efine& a$ t/e ea$e wit/ w/ic/ a .rogra* can be correcte& if an error i$ encountere&% a&a.te& if en2iron*ent c/ange$% en/ance& if t/e cu$to*er re'uire$ an en/ance*ent in functionalit(. It i$ an in&irect *ea$ure of t/e 'ualit(. 9 $i*.le ti*e oriente& *etric to gauge t/e *aintainabilit( i$ 4nown a$ ##TC F *ean ti*e to c/ange. It i$ &efine& a$ t/e ti*e it ta4e$ to anal(+e t/e c/ange re'ue$t% &e$ign an a..ro.riate *o&ification% i*.le*ent t/e c/ange% te$t it% an& i*.le*ent it. 9 co$t oriente& *etric u$e& to a$$e$$ *aintainabilit( i$ calle& S.oilage. It i$ &efine& a$ t/e co$t to correct &efect$ encountere& after t/e $oftware /a$ been relea$e& to t/e u$er$. S.oilage co$t i$ .lotte& again$t t/e o2erall .ro8ect co$t a$ a function of ti*e to &eter*ine w/et/er t/e o2erall *aintainabilit( of $oftware .ro&uce& b( t/e organi+ation i$ i*.ro2ing. - Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
68
VU
Integrit( i$ an e5tre*el( i*.ortant *ea$ure e$.eciall( in to&a(:$ conte5t w/en t/e $($te* i$ e5.o$e& to all $ort$ to attac4$ becau$e of t/e internet ./eno*enon. It i$ &efine& a$ $oftware:$ abilit( to wit/$tan& attac4 Hbot/ acci&ental an& intentionalJ to it$ $ecurit(. It inclu&e$ integrit( of .rogra*% &ata% an& &ocu*ent$. To *ea$ure integrit(% two a&&itional attribute$ are nee&e&. T/e$e are6 t/reat an& $ecurit(. T/reat i$ t/e .robabilit( H&eri2e& or *ea$ure& fro* e*.irical e2i&enceJ t/at an attac4 of a $.ecific t(.e will occur wit/in a gi2en ti*e an& $ecurit( i$ t/e .robabilit( t/at an attac4 of a $.ecific t(.e will be re.elle&. So t/e integrit( of a $($te* i$ &efine& a$ t/e $u* of all t/e .robabilit( t/at t/e t/reat of a $.ecific t(.e will not ta4e .lace an& t/e .robabilit( t/at if t/at t/reat &oe$ ta4e .lace% it will not be re.elle&. Integrit( Z [ \H1-t/reatJ 5 H1-$ecurit(J] =inall(% u$abilit( i$ a *ea$ure of u$er frien&line$$ F t/e ea$e wit/ w/ic/ a $($te* can be u$e&. It can be *ea$ure& in ter*$ of 4 c/aracteri$tic$6 $ $ $ $ 3/($ical or intellectual $4ill re'uire& learn t/e $($te* T/e ti*e re'uire& to beco*e *o&eratel( efficient in t/e u$e of $($te* T/e net increa$e in .ro&ucti2it( 9 $ub8ecti2e a$$e$$*ent
It i$ i*.ortant to note t/at e5ce.t for t/e u$abilit(% t/e ot/er t/ree factor$ are e$$entiall( t/e $a*e a$ .ro.o$e& b( #cCall.
co*bine& wit/ &e$ign an& co&e in$.ection% t/e 7,E reac/e$ "!B. T/at *ean$% co&e an& - Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
69
VU
&e$ign in$.ection are e5tre*el( i*.ortant acti2ate$ t/at are unfortunatel( not gi2en t/eir &ue i*.ortance.
70
VU
71
VU
"a%eline
In or&er to u$e t/e &ata for e$ti*ation an& &rawing conclu$ion$% it *u$t be ba$e-line&. In t/e ba$eline% &ata fro* .a$t .ro8ect$ i$ collecte&% cleane&% an& .ut in a &ataba$e. Suc/ *etric$ ba$eline i$ u$e& to rea. benefit$ at t/e .roce$$% .ro8ect% an& .ro&uct le2el. 9$ *entione& abo2e% t/e *etric$ ba$eline con$i$t$ of &ata collecte& fro* .a$t .ro8ect o2er a .erio& of ti*e. To be effecti2e% t/e &ata *u$t be rea$onabl( accurate% it $/oul& be collecte& o2er *an( .ro8ect$% *ea$ure$ *u$t be con$i$tent F $a*e tec/ni'ue or (ar&$tic4 for &ata collection $/oul& /a2e been u$e&% a..lication$ $/oul& be $i*ilar to wor4 t/at i$ to be e$ti*ate&% an& fee&bac4 to i*.ro2e ba$eline:$ 'ualit(.
T/i$ &ata wa$ t/en collecte& an& $tore& in a $i*.le &ataba$e a$ $/own below.
72
VU
3ro8ect
,$.3age$ of3re&ocu*entation $/i.*ent error$ 365 1224 1050 134 321 256
T/i$ &ata i$ t/en nor*ali+e& on .er function .oint ba$i$ a$ follow$6 3ro8ect Si+e H=3J Effort Co$t H3*J H000J ,$.3age$ of3re&ocu*entation $/i.*ent error$ 3o$t3eo.le $/i.*ent &efect$ 3
0.2 1400 162" 15!0 3.04 4.53 5.25 1.12 1.1" 1.2 0.24
120 2!0
0.23 0.32
5 6
0.22 0.32
200
;e are now rea&( to u$e t/i$ &ata to anal(+e t/e re$ult$ of .roce$$ c/ange$ an& t/eir i*.act on t/e ti*e to i*.le*ent c/ange re'ue$t$.
73
VU
In or&er to &o t/at% we nee& to e*.lo( $o*e $tati$tical tec/ni'ue$ an& .lot t/e re$ult gra./icall(. T/i$ i$ 4nown a$ $tati$tical control tec/ni'ue$.
74
VU
1 2 3 4 5 6 ! " 10 11 12 13 14 15 16 1! 1 1" 20
3 4.5 1.2 5 3.5 4. 2 4.5 4.!5 2.25 3.!5 5.!5 4.6 3.25 4 5.5 5." 4 3.3 5.
75
VU
In or&er to &eter*ine w/et/er our c/ange in .roce$$ /a& an( i*.act% we u$e control c/art$. T/i$ &ata i$ fir$t .re$ente& in t/e gra./ for* a$ follow$6
;e now &e2elo. t/e #o2ing ,ange Control C/art a$ follow$6 1. Calculate t/e *o2ing range$6 t/e ab$olute 2alue$ of t/e $ucce$$i2e &ifference$ between eac/ .air of &ata .oint. 3lot t/e$e *o2ing range$ on (our c/art. Ht/e &ar4 blue lineJ 2. Calculate t/e *ean of t/e *o2ing range$. 3lot t/i$ on t/e c/art. Ht/e re& lineJ 3. #ulti.l( t/e *ean wit/ 3.26 . 3lot t/i$ a$ t/e 1..er Control Line H1CLJ. T/i$ line i$ 3 $tan&ar& &e2iation$ abo2e t/e line. Ht/e lig/t blue lineJ 4. To &eter*ine w/et/er t/e .roce$$ *etric$ &e$cri.tion i$ $table% a $i*.le 'ue$tion i$ a$4e&6 are t/e *o2ing range$ 2alue$ in$i&e t/e 1CLL If t/e an$wer i$ (e$ t/en t/e .roce$$ i$ $table ot/erwi$e it i$ un$table. T/i$ c/art i$ $/own in t/e following &iagra*6
76
VU
T/i$ c/art i$ t/en u$e& to &e2elo. t/e in&i2i&ual control c/art a$ follow$6 1. 3lot in&i2i&ual *etric 2alue$ 2. Co*.ute t/e a2erage 2alue for t/e *etric$ 2alue$ - 9* 3. #ulti.l( t/e *ean of *o2ing a2erage b( 2.66 an& a&& a2erage co*.ute& in $te. 2 abo2e. T/e re$ult i$ 1..er Natural 3roce$$ Li*it H1N3LJ 4. #ulti.l( t/e *ean of *o2ing a2erage b( 2.66 an& $ubtract a2erage co*.ute& in $te. 2 abo2e. T/e re$ult i$ Lower Natural 3roce$$ Li*it HLN3LJ 5. 3lot 1N3L an& LN3L. If LN3L i$ le$$ t/an +ero t/an it nee& not be .lotte& unle$$ t/e *etric being e2aluate& ta4e$ on 2alue$ t/at are le$$ t/an 0. 6. Co*.ute a $tan&ar& &e2iation a$ H1N3L F 9*JO3. !. 3lot line$ 1 an& 2 $tan&ar& &e2iation$ abo2e an& below 9*. . 9..l(ing t/e$e $te.$ we &eri2e an in&i2i&ual control c/art. T/i$ c/art *a( be u$e& to e2aluate w/et/er t/e c/ange$ re.re$ente& b( *etric$ in&icate a .roce$$ t/at i$ in control or out of control. =or t/i$% t/e following 4 criteria +one rule$ are u$e&. 1. 9 $ingle *etric$ 2alue lie$ out$i&e 1N3L 2. Two out of t/ree $ucce$$i2e 2alue$ la( *ore t/an 2 $tan&ar&$ &e2iation$ awa( fro* 9*. 3. =our out of fi2e $ucce$$i2e 2alue$ la( *ore t/an one $tan&ar& &e2iation awa(. 4. Eig/t con$ecuti2e 2alue$ lie on one $i&e of 9*. If an( of t/e$e te$t$ .a$$e$% t/e .roce$$ i$ out of control ot/erwi$e t/e .roce$$ i$ wit/in control. Since none of t/e te$t .a$$e$ for t/e &ata in our e5a*.le% our .roce$$ i$ in control an& t/i$ &ata can be u$e& for inference. ;e now anal(+e our re$ult$. It can be $een t/at t/e 2ariabilit( &ecrea$e& after .ro8ect 10. )( co*.uting t/e *ean 2alue of t/e fir$t 10 an& la$t 10 .ro8ect$% it can be $/own t/at t/e re*e&ial *ea$ure ta4en wa$ $ucce$$ful an& re$ulte& in 2"B i*.ro2e*ent in efficienc( of t/e .roce$$. >ence t/e .roce$$ c/ange$ incor.orate& were u$eful an& bore fruit.
77
VU
Defects
Time
Si*ilarl(% we can gain u$eful infor*ation b( .lotting t/e &efect$ re.orte& again$t t/e nu*ber of u$e ca$e$ run. ;e can u$e control line$ fro* our .re2iou$ &ata an& $ee if t/e actual &efect$ are wit/in t/o$e control li*it$. If t/e &efect$ at an( gi2en .oint in ti*e are le$$ t/an t/e lower li*it t/en it *a( *ean t/at out te$ting tea* i$ not &oing a goo& 8ob an& co2erage i$ not a&e'uate. An t/e ot/er /an&% if it cro$$e$ t/e u..er line t/en it in&icate$ t/at t/e &e$ign an& co&ing i$ not u. to *ar4 an& we .er/a.$ nee& to c/ec4 it.
)##er limit
Defects
Actual defects
6o7er limit
Test cases
78
VU
9not/er 2er( $i*.le gra./ a$ $/own below can gi2e a lot of in$ig/t into t/e &e$ign 'ualit(. In t/i$ ca$e% if t/e fre'uenc( of ri..le &efect$ i$ too large% t/en it *ean$ t/at t/en t/ere i$ tig/t cou.ling an& /ence t/e &e$ign i$ not *aintainable.
, 1 3 1 Defect 2 .ipple 1 1 1 $ 1 1 2 3 , ' ( & Defect /i0ed ) *
T2ree ne3 defects appeared as a conse4uence of fi0ing defect '
T/e following i$ (et anot/er 2er( $i*.le an& effecti2e wa( of getting in$ig/t into t/e
, 1 5ot 1 " 1 Defect 3 1 2 1 1 1 $ 1
Time
'ualit( of t/e re'uire*ent$. If a nu*ber of &efect$ t/at are re.orte& b( t/e te$ting tea* are ulti*atel( re$ol2e& a$ not-a-&efect t/en t/ere *a( be a $e2er .roble* wit/ t/e re'uire*ent$ &ocu*ent a$ two tea*$ H&e2elo.*ent an& te$tingJ are inter.reting it &ifferentl( an& /ence co*ing to &ifferent conclu$ion$.
79
VU
Software %co*e e%ti'ation Software $co.e &e$cribe$ t/e &ata an& control to be .roce$$e&% function% .erfor*ance% con$traint$% interface$% an& reliabilit(. 7eter*ination of t/e $oftware $co.e i$ a .rere'ui$ite of all $ort$ of e$ti*ate$% inclu&ing% re$ource$% ti*e% an& bu&get. In or&er to un&er$tan& t/e $co.e% a *eeting wit/ t/e client $/oul& be arrange&. T/e anal($t $/oul& $tart wit/ &e2elo.ing a relation$/i. wit/ t/e client re.re$entati2e an& $tart wit/ conte5t-free 'ue$tion$. 9n un&er$tan&ing of t/e .ro8ect bac4groun& $/oul& al$o be &e2elo.e&. T/i$ inclu&e$ un&er$tan&ing6 $ $ $ ;/o i$ be/in& t/e re'ue$t H$.on$orJL ;/o will u$e t/e $olution Hu$er$JL ;/at are t/e econo*ic benefit$ Hw/(JL
Now i$ t/e ti*e to a&&re$$ t/e fin& out t/e *ore about t/e .ro&uct. In t/i$ conte5t% t/e following 'ue$tion$ *a( be a$4e&6 $ $ $ $ $ $ $ $ $ >ow woul& (ou c/aracteri+e goo& out.utL ;/at .roble*$ will t/e $olution a&&re$$L Can (ou $/ow *e t/e en2iron*ent in w/ic/ t/e $olution will be u$e&L ;ill an( $.ecial .erfor*ance i$$ue$ or con$traint$ affect t/e wa( t/e $olution i$ a..roac/e&L 9re (ou t/e rig/t .er$on to an$wer t/e$e 'ue$tion$L 9re an$wer$ DofficialEL 9re *( 'ue$tion$ rele2ant to t/e .roble* t/at (ou /a2eL 9* I a$4ing too *an( 'ue$tion$L Can an(one el$e .ro2i&e a&&itional infor*ationL S/oul& I be a$4ing (ou an(t/ing el$eL
In t/i$ regar&$% a tec/ni'ue 4nown a$ .acilitated #**lication S*ecification Tec!ni&ue% or $i*.l( .#ST can be u$e&. T/i$ i$ a tea*-oriente& a..roac/ to re'uire*ent gat/ering t/at i$ u$e& &uring earl( $tage$ of anal($i$ an& $.ecification. In t/i$ ca$e 8oint tea* of cu$to*er$ an& &e2elo.er$ wor4 toget/er to i&entif( t/e .roble*% .ro.o$e ele*ent$ of t/e $olution% negotiate &ifferent a..roac/e$% an& $.ecif( a .reli*inar( $et of re'uire*ent$.
80
VU
.ea%ibilit2 T/e .ur.o$e of t/e fea$ibilit( anal($i$ i$ to &eter*ine can we buil& $oftware to *eet t/e $co.eL =or t/i$ .ur.o$e% t/e .ro8ect i$ anal(+e& on t/e following 4 &i*en$ion$6 Tec/nolog( K I$ t/e .ro8ect tec/nicall( fea$ibleL K I$ it wit/in t/e $tate of t/e artL K Can &efect$ be re&uce& to a le2el *atc/ing t/e a..lication nee&$L =inance K I$ it financiall( fea$ibleL K Can &e2elo.*ent be co*.lete& at a co$t t/at $oftware organi+ation% it$ client% or t/e *ar4et can affor&L Ti*e K ;ill t/e .ro8ect ti*e to *ar4et beat t/e co*.etitionL K Can we co*.lete t/e .ro8ect in t/e gi2en a*ount of ti*eL ,e$ource$ K 7oe$ t/e organi+ation /a2e re$ource$ nee&e& to $uccee&L T/e re$ource$ inclu&e6 K >;OS; tool$ K ,eu$able $oftware co*.onent$ K 3eo.le Software 1ro9ect E%ti'ation Ance t/e .ro8ect fea$ibilit( /a$ been &eter*ine&% t/e .ro8ect *anager $tart$ t/e e$ti*ation acti2it(. It i$ a relati2el( &ifficult e5erci$e an& /a$ not beco*e an e5act $cience. It i$ influence& b( /u*an% tec/nical% en2iron*ental% .olitical factor$. =or $oftware .ro8ect e$ti*ation% a .ro8ect *anager can u$e /i$toric &ata about it$ organi+ation$ .re2iou$ .ro8ect$% &eco*.o$ition tec/ni'ue$% an&Oor e*.irical *o&el$ &e2elo.e& b( &ifferent re$earc/er$. E'*irical -odel% E*.irical *o&el$ are $tati$tical *o&el$ an& are ba$e& u.on /i$toric &ata. 9lt/oug/ t/ere are *an( &ifferent *o&el$ &e2elo.e& b( &ifferent re$earc/er$% all of t/e* $/are t/e following ba$ic $tructure6 E Z 9 P ) T He2JC w/ere 9% )% c are e*.irical con$tant$% Ue2: i$ t/e effort in ter*$ of line$ of co&e or =3% an& UE: i$ t/e effort in ter*$ of .er$on *ont/$. T/e *o$t fa*ou$ of t/e$e *o&el$ i$ t/e CACA#A - CAn$tructi2e CA$t #A&el F *o&el. It al$o /a$ *an( &ifferent 2er$ion$. T/e $i*.le$t of t/e$e 2er$ion$ i$ gi2en below6 E Z 3.2 HILACJ1.05
81
VU
So*e of t/e$e *o&el$ ta4e into account t/e .ro8ect a&8u$t*ent co*.onent$ inclu&ing .roble* co*.le5it(% $taff e5.erience% an& &e2elo.*ent en2iron*ent. It i$ i*.ortant to note t/at t/ere are a nu*ber of *o&el$ wit/ eac/ (iel&ing a &ifferent re$ult. T/i$ *ean$ t/at an( *o&el *u$t be calibrate& for local nee&$ before it can be effecti2el( u$e&. T!e Software E&uation T/e $oftware e'uation $/own below i$ &(na*ic *ulti2ariable e$ti*ation *o&el. It a$$u*e$ a $.ecific &i$tribution of effort o2er t/e life of t/e $oftware &e2elo.*ent .ro8ect an& i$ &eri2e& fro* .ro&ucti2it( &ata collecte& for o2er 4000 .ro8ect$. E Z \LAC 5 )0.333O3]3 5 H1Ot4J ;/ere6 $ E F effort in .er$on *ont/$ or .er$on (ear$ $ t F .ro8ect &uration in *ont/$ or (ear$ $ ) F $.ecial $4ill factor + Increa$e$ $lowl( a$ t/e nee& for integration% te$ting% @9% &ocu*entation% an& *anage*ent $4ill$ grow $ 3 F .ro&ucti2it( .ara*eter + A2erall .roce$$ *aturit( an& *anage*ent .ractice$ + T/e e5tent to w/ic/ goo& SE .ractice$ are u$e& + T/e le2el of .rogra**ing language u$e& + T/e $tate of t/e $oftware en2iron*ent + T/e $4ill$ an& e5.erience of t/e $oftware tea* + T/e co*.le5it( of t/e a..lication "u2 ,er%u% build It i$ often *ore co$t-effecti2e to ac'uire t/an to buil&. T/ere *a( be $e2eral &ifferent o.tion$ a2ailable. T/e$e inclu&e6 K K K Aff-t/e-$/elf licen$e& $oftware Software co*.onent$ to be *o&ifie& an& integrate& into t/e a..lication Sub-contract
T/e final &eci$ion &e.en&$ u.on t/e criticalit( of t/e $oftware to be .urc/a$e& an& t/e en& co$t. T/e bu( 2er$u$ buil& &eci$ion .roce$$ in2ol2e$ t/e following $te.$6 $ $ $ $ $ 7e2elo. $.ecification for function an& .erfor*ance of t/e &e$ire& $oftware. 7efine *ea$urable c/aracteri$tic$ w/ene2er .o$$ible. E$ti*ate internal co$t an& ti*e to &e2elo. Select 3-4 can&i&ate a..lication$ t/at be$t *eet (our $.ecification$ Select reu$able $oftware co*.onent$ t/at will a$$i$t in con$tructing t/e re'uire& a..lication 7e2elo. co*.ari$on *atri5 t/at .re$ent$ a /ea&-to-/ea& co*.ari$on of 4e( function. 9lternati2el(% con&uct benc/*ar4 te$t$ to co*.are can&i&ate $oftware.
82
VU
E2aluate eac/ $oftware .ac4age or co*.onent ba$e& on .a$t .ro&uct 'ualit(% 2en&or $u..ort% .ro&uct &irection% re.utation% etc. Contact ot/er u$er$ of t/e $oftware an& a$4 for o.inion.
T/e following 4e( con$i&eration$ *u$t alwa($ be 4e.t in t/e .er$.ecti2e6 $ 7eli2er( &ate $ 7e2elo.*ent Co$t + 9c'ui$ition P cu$to*i+ation $ #aintenance Co$t 9 &eci$ion tree can be built to anal(+e &ifferent o.tion$ in t/i$ regar&$. 9$ an e5a*.le of t/i$% let u$ con$i&er t/e following. In t/i$ ca$e% we /a2e four &ifferent o.tion$% na*el(% buil&% reu$e% bu(% an& contract. ;e anal(+e eac/ one of t/e$e wit/ t/e /el. of a &eci$ion tree. Eac/ no&e of t/e tree i$ furt/er .artitione& a .robabilit( i$ a$$igne& to eac/ branc/. 9t t/e en&% co$t for eac/ .at/ in t/e tree% fro* root to a leaf% i$ e$ti*ate& an& a$$ociate& wit/ t/at .at/. T/i$ .roce$$ i$ $/own in t/e following &iagra*.
Si*.le H0.30J
)u il&
- 3 0%000
u$ ,e
)u (
Si*.le H0.20J - 310%000 #a8or Co*.le5 H0. 0J - 4"0%000 c/ange$ H0.60J #inor c/ange$ H0.!0J - 210%000 #a8or c/ange$ H0.30J - 400%000 ;it/out c/ange$ H0. 0J - 350%000 ;it/ c/ange$ H0.20J - 500%000
Ance t/e infor*ation in t/e tree i$ co*.lete% it i$ u$e& to &eter*ine t/e *o$t 2iable o.tion. =or eac/ o.tion t/e e5.ecte& co$t i$ &eter*ine& a$ follow$6 E5.ecte& co$t Z [ H.at/ .robabilit(JI 5 He$ti*ate& .at/ co$tJ 1$ing t/i$ for*ula% we calculate t/e e5.ecte& co$t of eac/ o.tion a$ follow$6 )uil& Z 0.30T3 0 P 0.!0T450000 Z 42"000 ,eu$e Z 0.4T2!5000 P 0.6T0.2T310000 P 0.6T0. T4"0000 Z 3 2400 T/e e5.ecte& co$t of )u( an& Contract can al$o be calculate& in a $i*ilar fa$/ion an& co*e$ out to be6 )u( Contract Z 26!000 Z 3 0000
T/erefore% accor&ing to t/i$ anal($i$% it i$ *o$t 2iable to bu( t/an an( ot/er o.tion.
tra on C
ct
83
VU
1nfortunatel(% In&iana ?one$ $t(le i$ *ore $uitable for fiction an& /a$ a rare c/ance of $ucce$$ in real life $ituation$. It i$ t/erefore i*.erati2e t/at we *anage ri$4 .roacti2el(. 9 ri$4 /a$ two c/aracteri$tic$6 $ 1ncertaint( F t/e ri$4 *a( or *a( not /a..en $ Lo$$ F if t/e ri$4 beco*e$ a realit(% unwante& con$e'uence$ or lo$$e$ will occur.
84
VU
9 ri$4 anal($i$ in2ol2e$ 'uantif(ing &egree of uncertaint( of t/e ri$4 an& lo$$ a$$ociate wit/ it. In t/i$ regar&$% t/e 3# trie$ to fin& an$wer$ to t/e following 'ue$tion$6 $ $ $ $ ;/at can go wrongL ;/at i$ t/e li4eli/oo& of it going wrongL ;/at will t/e &a*age beL ;/at can we &o about itL
85
CS605 Software Engineering-II Eac/ .ro8ect i$ face& wit/ *an( t(.e$ of ri$4$. T/e$e inclu&e6 $
VU
3ro8ect ri$4$ + ;ill i*.act $c/e&ule an& co$t + Inclu&e$ bu&getar(% $c/e&ule% .er$onnel% re$ource% cu$to*er% re'uire*ent .roble*$ Tec/nical ri$4$ + I*.act t/e 'ualit(% ti*eline$% an& co$t + I*.le*entation *a( beco*e &ifficult or i*.o$$ible + Inclu&e$ &e$ign% i*.le*entation% interface% 2erification an& *aintenance .roble*$ + Lea&ing e&ge tec/nolog( )u$ine$$ ri$4$ + #ar4etabilit( + 9lign*ent wit/ t/e o2erall bu$ine$$ $trateg( + >ow to $ell + Lo$ing bu&get or .er$onnel co**it*ent$
=urt/er*ore% t/ere are .re&ictable an& un.re&ictable ri$4$. 3re&ictable ri$4$ can be unco2ere& after careful e2aluation w/erea$ un.re&ictable ri$4$ cannot be i&entifie&. 4i%( Identification It i$ t/e re$.on$ibilit( of t/e .ro8ect *anager to i&entif( 4nown an& .re&ictable ri$4$. T/e$e ri$4$ fall in t/e following categorie$ of generic ri$4$ an& .ro&uct $.ecific ri$4$. 4eneric risks are t/reat$ to e2er( .ro8ect w/erea$ *roduct specific risks are $.ecific to a .articular .ro8ect. T/e 'ue$tion to be a$4e& in t/i$ conte5t i$6 w/at $.ecial c/aracteri$tic$ of t/i$ .ro8ect *a( t/reaten (our .ro8ect .lanL 9 u$eful tec/ni'ue in t/i$ regar&$ i$ t/e .re.aration of a ri$4 ite* c/ec4li$t. T/i$ li$t trie$ to a$4 an& an$wer 'ue$tion$ rele2ant to eac/ of t/e following to.ic$ for eac/ $oftware .ro8ect6 $ $ $ $ $ $ $ 3ro&uct $i+e )u$ine$$ i*.act Cu$to*er c/aracteri$tic$ 3roce$$ &efinition 7e2elo.*ent en2iron*ent Tec/nolog( to be built Staff $i+e an& e5.erience
#%%e%%ing /,erall 1ro9ect 4i%(% In or&er to a$$e$$ t/e o2erall .ro8ect ri$4$% t/e following 'ue$tion$ nee& to be a&&re$$e&6 $ $ $ $ $ $ >a2e to. $oftware an& cu$to*er *anager$ for*all( co**itte& to $u..ort t/e .ro8ectL 9re en&-u$er$ co**itte& to t/e .ro8ect an& t/e $($te*O.ro&uct to be builtL 9re re'uire*ent$ full( un&er$too&L >a2e cu$to*er$ been in2ol2e& full( in re'uire*ent &efinitionL 7o en&-u$er$ /a2e reali$tic e5.ectation$L 7oe$ t/e $oftware tea* /a2e rig/t *i5 of $4ill$L
86
VU
9re .ro8ect re'uire*ent$ $tableL 7oe$ t/e .ro8ect tea* /a2e e5.erience wit/ t/e tec/nolog( to be i*.le*ente&L I$ t/e nu*ber of .eo.le on t/e .ro8ect tea* a&e'uate to &o t/e 8obL
4i%( co'*onent% and dri,er% Eac/ ri$4 /a$ *an( co*.onent$ an& force$ be/in& t/e*. =ro* t/i$ .er$.ecti2e% ri$4$ can be categori+e& into t/e following categorie$6 3erfor*ance ri$4$ + 7egree of uncertaint( t/at t/e .ro&uct will *eet it$ re'uire*ent$ an& be fit for it$ inten&e& u$e $ Co$t ri$4$ + T/e &egree of uncertaint( t/at t/e .ro8ect bu&get will be *aintaine& $ Su..ort ri$4$ + ,e$ultant $oftware will be ea$( to correct% en/ance% an& a&a.t $ Sc/e&ule ri$4$ + 3ro&uct $c/e&ule will be *aintaine& Eac/ ri$4 /a$ it$ own i*.act an& can be c/aracteri+e& a$ negligible% *arginal% critical% or cata$tro./ic. T/i$ i$ $u**ari+e& in t/e following table6 4i%( I'*act 1erfor'ance Su**ort Co%t Sc!edule $
Cata%tro*!ic Con$e'uence of =ailure to *eet t/e ,e$ult$ in increa$e& error re'uire*ent$ will re$ult in co$t an& $c/e&ule *i$$ion failure &ela($. E5.ecte& 2alue in e5ce$$ of S500I Con$e'uence of Significant Non)u&get 1nac/ie2able failure to &egra&ation re$.on$i2e or o2errun ac/ie2e &e$ire& un$u..ortable li4el( re$ult Critical Con$e'uence of ;oul& &egra&e .erfor*ance ,e$ult$ in o.erational error to a .oint w/ere *i$$ion &ela($ an& or increa$e& $ucce$$ i$ 'ue$tionable co$t wit/ e5.ecte& 2alue of S100I-S500I Con$e'uence of So*e #inor &ela($ 3o$$ible 3o$$ible failure to re&uction in o2errun $li..age ac/ie2e &e$ire& tec/nical re$ult .erfor*ance -arginal Con$e'uence of ,e$ult in &egra&ation of E5.ecte& 2alue ^S100I error $econ&ar( *i$$ion Con$e'uence of S*all ,e$.on$i2e Sufficient ,eali$tic failure to re&uction financial ac/ie2e &e$ire& re$ource$ re$ult Negligible Con$e'uence of Incon2enience #inor error
87
CS605 Software Engineering-II Con$e'uence of No re&uction Su..ortable )u&get ac/ie2able failure to un&er run ac/ie2e &e$ire& .o$$ible re$ult
VU
4i%( 1ro9ection ,i$4 .ro8ection i$ concerne& wit/ ri$4 e$ti*ation. It atte*.t$ to rate ri$4$ in two wa($6 li4eli/oo& an& con$e'uence$. T/ere are four ri$4 .ro8ect acti2itie$. T/e$e are6 K K K K E$tabli$/ a $cale t/at reflect$ t/e .ercei2e& li4eli/oo& of ri$4 7elineate t/e con$e'uence$ E$ti*ate i*.act Note t/e o2erall accurac( of ri$4 .ro8ection
T/i$ .roce$$ i$ e5e*.lifie& wit/ t/e /el. of t/e following table6 ,i$4 Si+e e$ti*ate *a( be $ignificantl( low Larger nu*ber of u$er$ t/an .lanne& Le$$ reu$e t/an .lanne& En&-u$er$ re$i$t $($te* 7eli2er( &ea&line will be tig/tene& =un&ing will be lo$t Cu$to*er will c/ange re'uire*ent$ Tec/nolog( will not *eet e5.ectation$ Lac4 of training on tool$ Staff ine5.erience& Staff turno2er will be /ig/ Categor( 3S 3S 3S )1 )1 C1 3S TE 7E ST ST 3robabilit( I*.act 60B 2 30B 3 !0B 2 40B 3 50B 2 40B 1 0B 2 30B 1 0B 3 30B 2 60B 2 ,###
46 negligible
an& ,### $tan&$ for ri$4 *itigation% *onitoring% an& *anage*ent .lan.
88
CS605 Software Engineering-II =or eac/ ri$4 an e5.o$ure i$ calculate& a$ follow$6 ,E Z 3robabilit( of t/e ri$4 5 Co$t T/i$ ri$4 e5.o$ure i$ t/en u$e& to i&entif( t/e to. ri$4$ an& *itigation $trategie$. 9$ an e5a*.le% let u$ con$i&er t/e following ca$e6 $
VU
$ $
,i$46 + Anl( !0B of t/e $oftware co*.onent$ $c/e&ule& for reu$e will% in fact% be integrate& into t/e a..lication. T/e re*aining functionalit( will /a2e to be cu$to* &e2elo.e&. ,i$4 3robabilit( F 0B li4el( Hi.e. 0. J ,i$4 i*.act + 60 reu$able $oftware co*.onent$ were .lanne&. If onl( !0B can be u$e&% 1 co*.onent$ woul& /a2e to be &e2elo.e& fro* $cratc/. Since t/e a2erage co*.onent will co$t 100%000% t/e total co$t will be 1% 00%000. T/erefore% ,E Z 0. T 1% 00%000 Z 1%440%000
9 /ig/ le2el ri$4 *a( be refine& into finer granularit( to /an&le it efficientl(. 9$ an e5a*.le% t/e abo2e *entione& ri$4 i$ refine& a$ follow$6 1. Certain reu$able co*.onent$ were &e2elo.e& b( 3r& .art( wit/ no 4nowle&ge of internal &e$ign $tan&ar&. 2. 7e$ign $tan&ar& for co*.onent interface$ /a$ not been $oli&ifie& an& *a( not confor* to certain e5i$ting co*.onent$. 3. Certain reu$able co*.onent$ /a2e been i*.le*ente& in a language t/at i$ not $u..orte& on t/e target en2iron*ent. ;e can now ta4e t/e following *ea$ure$ to *itigate an& *onitor t/e ri$46 1. Contact 3r& .art( to &eter*ine confor*ance wit/ &e$ign $tan&ar&$. 2. 3re$$ for interface $tan&ar& co*.letionC con$i&er co*.onent $tructure w/en &eci&ing on interface .rotocol. 3. C/ec4 to &eter*ine if language $u..ort can be ac'uire&. T/i$ lea&$ u$ to t/e following #anage*entOContingenc( 3lan6 1. ,E co*.ute& to 1%440%000. 9llocate t/i$ a*ount wit/in .ro8ect contingenc( co$t. 2. 7e2elo. re2i$e& $c/e&ule a$$u*ing 1 a&&itional co*.onent$ will /a2e to be cu$to*-built 3. 9llocate $taff accor&ingl( 4i%( -itigationD -onitoringD and -anage'ent 64---7 T/e ,### .lan a$$i$t$ t/e .ro8ect tea* in &e2elo.ing $trateg( for &ealing wit/ ri$4. In t/i$ conte5t% an effecti2e $trateg( *u$t con$i&er6 + ,i$4 a2oi&ance + ,i$4 *onitoring + ,i$4 *anage*ent an& contingenc( .lan
89
VU
It *u$t alwa($ be re*e*bere& t/at a2oi&ance i$ alwa($ t/e be$t $trateg(. 9$ an e5a*.le% let con$i&er t/e following $cenario. In t/i$ ca$e /ig/ turn-o2er /a$ been i&entifie& a$ a ri$4 wit/ t/e following c/aracteri$tic$6 $ $ $ ,i$4 r8 - >ig/ turno2er Li4eli/oo& l8 Z 0.! I*.act 58 - .ro8ecte& at le2el 2 HcriticalJ
Let u$ now &e2i$e a *itigation $trateg( for re&ucing turno2er. In or&er to &o $o% t/e following $te.$ *a( be ta4en6 $ $ $ $ $ $ $ #eet wit/ current $taff to &eter*ine cau$e$ for turno2er He.g. .oor wor4ing con&ition$% low .a(% co*.etiti2e 8ob *ar4etJ #itigate t/o$e cau$e$ t/at are un&er our control before t/e .ro8ect $tart$ Ance t/e .ro8ect co**ence$% a$$u*e turno2er will occur an& &e2elo. tec/ni'ue$ to en$ure continuit( w/en .eo.le lea2e Argani+e .ro8ect tea*$ $o t/at infor*ation about eac/ &e2elo.*ent acti2it( i$ wi&el( &i$.er$e& 7efine &ocu*entation $tan&ar&$ an& e$tabli$/ *ec/ani$*$ to be $ure t/at &ocu*ent$ are &e2elo.e& in a ti*el( *anner Hto en$ure continuit(J Con&uct .eer re2iew$ of all wor4 H$o t/at *ore t/an one .er$on i$ u. to $.ee&J 9$$ign a bac4u. $taff *e*ber for e2er( critical tec/nolog(
Ance t/e $trateg( /a$ been &e2i$e&% t/e .ro8ect *u$t be *onitore& for t/i$ .articular ri$4. T/at i$% we *u$t 4ee. an e(e on t/e 2ariou$ factor$ t/at can in&icate t/at t/i$ .articular ri$4 i$ about to /a..en. In t/i$ ca$e% t/e factor$ coul& be6 $ $ $ $ $ General attitu&e of tea* *e*ber$ ba$e& on .ro8ect .re$$ure$ T/e &egree to w/ic/ t/e tea* i$ 8elle& Inter.er$onal relation$/i.$ a*ong tea* *e*ber$ 3otential .roble*$ wit/ co*.en$ation an& benefit$ T/e a2ailabilit( of 8ob$ wit/in t/e co*.an( an& out$i&e it
9l$o% t/e effecti2ene$$ of t/e ri$4 *itigation $te.$ $/oul& be *onitore&. So% in t/i$ e5a*.le% t/e 3# $/oul& *onitor &ocu*ent$ carefull( to en$ure t/at eac/ can $tan& on it$ own an& t/at eac/ i*.art$ infor*ation t/at woul& be nece$$ar( if a newco*er were force& to 8oin t/e $oftware tea* $o*ew/ere in t/e *i&&le of t/e .ro8ect. 4i%( -anage'ent and Contingenc2 1lan ,i$4 *anage*ent an& contingenc( .lanning a$$u*e$ t/at *itigation effort$ /a2e faile& an& t/at t/e ri$4 /a$ beco*e a realit(. $ $ $ $ ,i$4 /a$ beco*e a realit( F $o*e .eo.le announce t/at t/e( will be lea2ing If *itigation $trateg( /a$ been followe&% bac4u. i$ a2ailable% infor*ation /a$ been &ocu*ente&% an& 4nowle&ge /a$ been &i$.er$e& Te*.oraril( refocu$ an& rea&8u$t re$ource$ 3eo.le w/o are lea2ing are a$4e& to $to. all wor4 an& en$ure 4nowle&ge tran$fer
90
VU
,i$4 *itigation an& contingenc( i$ a co$tl( bu$ine$$. It i$ t/erefore i*.ortant to un&er$tan& t/at for ,### .lan% a co$tObenefit anal($i$ of eac/ ri$4 *u$t be carrie& out. T/e 3areto .rinci.le H 0-20 ruleJ i$ a..licable in t/i$ ca$e a$ well F 20B of t/e i&entifie& ri$4 account for 0B of t/e .otential for .ro8ect failure.
91
VU
=or t/i$% t/e $c/e&ule *u$t be fine graine&. Software 1ro9ect Sc!eduling Software .ro8ect $c/e&uling i$ an acti2it( t/at &i$tribute$ e$ti*ate& effort acro$$ t/e .lanne& .ro8ect &uration b( allocating t/e effort to $.ecific $oftware engineering ta$4$. It i$ i*.ortant to note t/at t/e $c/e&ule e2ol2e$ o2er ti*e. 7uring earl( $tage$ of .ro8ect .lanning% a *acro$co.ic $c/e&ule i$ &e2elo.e&. T/i$ t(.e of $c/e&ule i&entifie$ all *a8or SE acti2itie$ an& t/e .ro&uct function$ to w/ic/ t/e( are a..lie&. 9$ t/e .ro8ect get$ un&erwa( t/e$e ta$4$ are refine& into a &etaile& $c/e&ule. In or&er to co*e u. wit/ a reali$tic $c/e&ule% t/e following ba$ic .rinci.le$ are u$e&6 K Co*.art*entali+ation T/e .ro8ect *u$t be co*.art*entali+e& into a nu*ber of *anageable acti2itie$ an& ta$4$. To acco*.li$/ co*.art*entali+ation% bot/ t/e .ro&uct an& .roce$$ are &eco*.o$e&. K Inter&e.en&enc( T/e inter&e.en&enc( of eac/ co*.art*entali+e& acti2it( or ta$4 *u$t be &eter*ine&. So*e ta$4$ *u$t occur in $e'uence w/ile ot/er$ can occur in .arallel. So*e acti2itie$ cannot co**ence until t/e wor4 .ro&uct .ro&uce& b( anot/er i$ a2ailable.
92
VU
K Ti*e allocation Eac/ ta$4 to be $c/e&ule& *u$t be allocate& $o*e nu*ber of wor4 unit$ He.g. .er$on-&a($ of effortJ. In a&&ition% eac/ ta$4 *u$t be a$$igne& a $tart &ate an& an en& &ate w/ic/ i$ a function of t/e inter&e.en&encie$ an& nu*ber of re$ource$. K Effort 2ali&ation E2er( .ro8ect /a$ a &efine& nu*ber of $taff *e*ber$. 9$ ti*e allocation occur$% t/e .ro8ect *anager *u$t en$ure t/at no *ore t/an t/e allocate& nu*ber of .eo.le /a$ been $c/e&ule& at an( gi2en ti*e. K 7efine& re$.on$ibilitie$ E2er( ta$4 $/oul& be a$$igne& to a $.ecific tea* *e*ber. K 7efine& outco*e$ E2er( ta$4 $/oul& /a2e a &efine& outco*e% nor*all( a wor4 .ro&uct. K 7efine& *ile$tone$ E2er( ta$4 or grou. of ta$4$ $/oul& be a$$ociate& wit/ a .ro8ect *ile$tone. Software 1ro9ect Sc!eduling and -onitoring Software .ro8ect $c/e&uling i$ t/e ne5t ta$4 to be .erfor*e& b( t/e 3#. It i$ i*.ortant to note once again t/at in t/e rea$on$ for .ro8ect failure% unreali$tic &ea&line an& un&ere$ti*ate of effort in2ol2e& in t/e .ro8ect are two of t/e *o$t i*.ortant rea$on$ for .ro8ect failure. T/erefore% a goo& $c/e&ule e$ti*ate woul& increa$e t/e c/ance$ of t/e $ucce$$ of t/e .ro8ect. In t/i$ conte5t% a 3# /a$ to fir$t co*e u. wit/ t/e $c/e&ule an& t/en *onitor t/e .rogre$$ of t/e .ro8ect to en$ure t/at t/ing$ are /a..ening accor&ing to t/e $c/e&ule. It woul& not be out of .lace to 'uote =re& )roo4$ at t/i$ .oint. >e $a($% 5*ro!ects fall behind schedule one day at a time.6 T/at *ean$ a &ela( of a wee4 or a *ont/ or a (ear &oe$ not /a..en $u&&enl( F it /a..en$ one &a( at a ti*e. T/erefore% a .ro8ect *anager /a$ to be 2igilant to en$ure t/at t/e .ro8ect &oe$ not fall be/in& $c/e&ule. T/e realit( of a tec/nical .ro8ect i$ t/at /un&re&$ of $*all ta$4$ *u$t occur to acco*.li$/ a large goal. T/erefore t/e 3ro8ect *anager:$ ob8ecti2e$ inclu&e6 + + + + I&entification an& &efinition all .ro8ect ta$4$ )uil&ing a networ4 t/at &e.ict$ t/eir inter&e.en&encie$ I&entification of t/e ta$4$ t/at are critical wit/in t/e networ4 Trac4ing t/eir .rogre$$ to en$ure &ela( i$ recogni+e& one &a( at a ti*e
=or t/i$% t/e $c/e&ule *u$t be fine graine&. Software 1ro9ect Sc!eduling Software .ro8ect $c/e&uling i$ an acti2it( t/at &i$tribute$ e$ti*ate& effort acro$$ t/e .lanne& .ro8ect &uration b( allocating t/e effort to $.ecific $oftware engineering ta$4$. It i$ i*.ortant to note t/at t/e $c/e&ule e2ol2e$ o2er ti*e. 7uring earl( $tage$ of .ro8ect .lanning% a *acro$co.ic $c/e&ule i$ &e2elo.e&. T/i$ t(.e of $c/e&ule i&entifie$ all *a8or
93
VU
SE acti2itie$ an& t/e .ro&uct function$ to w/ic/ t/e( are a..lie&. 9$ t/e .ro8ect get$ un&erwa( t/e$e ta$4$ are refine& into a &etaile& $c/e&ule. In or&er to co*e u. wit/ a reali$tic $c/e&ule% t/e following ba$ic .rinci.le$ are u$e&6 K Co*.art*entali+ation T/e .ro8ect *u$t be co*.art*entali+e& into a nu*ber of *anageable acti2itie$ an& ta$4$. To acco*.li$/ co*.art*entali+ation% bot/ t/e .ro&uct an& .roce$$ are &eco*.o$e&. K Inter&e.en&enc( T/e inter&e.en&enc( of eac/ co*.art*entali+e& acti2it( or ta$4 *u$t be &eter*ine&. So*e ta$4$ *u$t occur in $e'uence w/ile ot/er$ can occur in .arallel. So*e acti2itie$ cannot co**ence until t/e wor4 .ro&uct .ro&uce& b( anot/er i$ a2ailable. K Ti*e allocation Eac/ ta$4 to be $c/e&ule& *u$t be allocate& $o*e nu*ber of wor4 unit$ He.g. .er$on-&a($ of effortJ. In a&&ition% eac/ ta$4 *u$t be a$$igne& a $tart &ate an& an en& &ate w/ic/ are a function of t/e inter&e.en&encie$ an& nu*ber of re$ource$. K Effort 2ali&ation E2er( .ro8ect /a$ a &efine& nu*ber of $taff *e*ber$. 9$ ti*e allocation occur$% t/e .ro8ect *anager *u$t en$ure t/at no *ore t/an t/e allocate& nu*ber of .eo.le /a2e been $c/e&ule& at an( gi2en ti*e. K 7efine& re$.on$ibilitie$ E2er( ta$4 $/oul& be a$$igne& to a $.ecific tea* *e*ber. K 7efine& outco*e$ E2er( ta$4 $/oul& /a2e a &efine& outco*e% nor*all( a wor4 .ro&uct. K 7efine& *ile$tone$ E2er( ta$4 or grou. of ta$4$ $/oul& be a$$ociate& wit/ a .ro8ect *ile$tone.
94
VU
It *a( be note& /ere t/at wit/ onl( a 5B co**unication o2er/ea& .er c/annel% t/e total wor4 acco*.li$/e& b( a tea* of 6 .eo.le woul& be le$$ t/an t/e 2olu*e of wor4 co*.lete& b( a tea* of 4 .eo.le. It i$ al$o intere$ting to note t/at it a..roac/e$ 0 a$ t/e tea* $i+e a..roac/e$ 20. Ta%( Set +efinition 9 .roce$$ *o&el &efine$ a ta$4 $et w/ic/ co*.ri$e$ of SE wor4 ta$4$% *ile$tone$% an& &eli2erable$. T/i$ enable a $oftware tea* to &efine% &e2elo.% an& $u..ort t/e $oftware. T/erefore% eac/ $oftware .roce$$ $/oul& &efine a collection of ta$4 $et$% &e$igne& to *eet t/e nee&$ of &ifferent t(.e$ of .ro8ect$. To &eter*ine t/e $et of ta$4$ to be .erfor*e& t/e t(.e of t/e .ro8ect an& t/e &egree of rigor re'uire& nee&$ to be e$tabli$/e&. 7ifferent
95
VU
t(.e$ of .ro8ect$ an& &ifferent &egree of rigor. T/e$e .ro8ect$ coul& fall into t/e following categorie$6 $ $ $ $ $ Conce.t &e2elo.*ent .ro8ect$ New a..lication &e2elo.*ent 9..lication en/ance*ent 9..lication *aintenance ,eengineering .ro8ect$
T/e &egree of rigor can al$o be categori+e& a$ Ca$ual% Structure&% Strict% or @uic4 ,eaction. T/e following .aragra./$ elaborate eac/ one of t/e$e. $ Ca$ual 9ll .roce$$ fra*ewor4 acti2itie$ are a..lie&% but onl( a *ini*u* ta$4 $et i$ re'uire&. It re'uire$ re&uce& u*brella ta$4$ an& re&uce& &ocu*entation. )a$ic .rinci.le$ of SE are /owe2er $till followe&. Structure& In t/i$ ca$e a co*.lete .roce$$ fra*ewor4 i$ a..lie&. 9..ro.riate fra*ewor4 acti2itie$% relate& ta$4$% an& u*brella acti2itie$ Hto en$ure /ig/ 'ualit(J are al$o a..lie&. S@9% SC#% &ocu*entation% an& *ea$ure*ent are con&ucte& in $trea*line& *anner. Strict In t/i$ ca$e a full .roce$$ i$ i*.le*ente& an& all u*brella acti2itie$ are a..lie&. T/e wor4 .ro&uct$ generate& in t/i$ ca$e are robu$t. @uic4 ,eaction T/i$ a..roac/ i$ ta4en in ca$e of an e*ergenc(. In t/i$ ca$e onl( ta$4 e$$ential for *aintaining goo& 'ualit( are a..lie&. 9fter t/e ta$4 /a$ been acco*.li$/e&% &ocu*ent$ are u.&ate& b( bac4-filling.
$ $
T/e ne5t 'ue$tion i$ /ow to &eci&e about t/e &egree of rigor. =or t/i$ .ur.o$e an a&a.tation criterion /a$ been &e2elo.e&. T/e following .ara*eter$ are con$i&ere& before a &eci$ion i$ *a&e6 $ Si+e of t/e .ro8ect $ Nu*ber of .otential u$er$ $ #i$$ion criticalit( $ 9..lication longe2it( $ Stabilit( of re'uire*ent$ $ Ea$e of cu$to*erO&e2elo.er co**unication $ Si+e of t/e .ro8ect $ Nu*ber of .otential u$er$ $ #i$$ion criticalit( $ 9..lication longe2it( $ Stabilit( of re'uire*ent$ $ Ea$e of cu$to*erO&e2elo.er co**unication T/e$e .ara*eter$ are u$e& to calculate w/at i$ 4nown a$ Ta%( Set Selector 6TSS7 w/ic/ i$ t/en u$e& to &eter*ine t/e &egree of rigor. It i$ co*.ute& a$ follow$6
96
VU
Eac/ a&a.tation criteria i$ a$$igne& a gra&e% weig/t% an& entr( .oint *ulti.lier. 1. 9 gra&e 2alue of between 1 an& 5 i$ a$$igne& to eac/ a&a.tation criteria a$ a..ro.riate. 2. T/e &efault 2alue of t/e weig/ting factor Ha$ gi2en in t/e table belowJ i$ re2iewe& an& *o&if( if nee&e&. T/e range$ $/oul& be between 0. to 1.2.
9&a.tation Criteria Si+e of .ro&uct Nu*ber of 1$er$ )u$ine$$ Criticalit( Longe2it( Stabilit( of re'uire*ent$ Ea$e of co**unication #aturit( of tec/nolog( 3erfor*ance Con$traint$ E*be&&e& O non-e*be&&e& 3ro8ect Staffing Intero.erabilit( ,eengineering factor$ Gra&e ;eig/t Entr( 3oint #ulti.lier Conc. New En/an. #aint. ,eeng. 7e2. 0 1 1 1 1 0 1 1 1 1 0 0 0 0 1 0 1 1 0 0 1 1 1 1 1 1 1 1 1 0 1 1 1 1 0 1 1 1 1 0 1 0 1 1 0 0 0 1 1 0 1 0 1 1 1 1 1 1 1 1 3ro&uct
1.2 1.1 1.1 0." 1.2 0." 0." 0. 1.2 1.0 1.1 1.2
3. #ulti.l( t/e gra&e entere& b( t/e weig/t an& b( entr( .oint *ulti.lier for t/e t(.e of .ro8ect un&erta4en. T/e entr( .oint *ulti.lier ta4e$ a 2alue of 0 or 1 an& in&icate$ t/e rele2ance of t/e a&a.tation criterion to t/e .ro8ect t(.e. 3ro&uct Z gra&e _ weig/t _ entr( .oint *ulti.lier T/e TSS i$ t/en co*.ute& a$ t/e a2erage of all t/e entrie$ in t/e .ro&uct colu*n. It i$ t/en u$e& to &eter*ine t/e &egree of rigor re'uire& a$ $/own in t/e table below. TSS ^ 1.2 1.0 F 3.0 ` 2.4 +egree of 4igor Ca$ual Structure& Strict
It *a( be note& t/at t/ere i$ o2erla. in TSS 2alue$. T/i$ o2erla. i$ intentional an& it &e.ict$ t/at $/ar. boun&arie$ are i*.o$$ible to &efine w/en *a4ing ta$4 $et $election. In t/e final anal($i$% t/e TSS 2alue% .a$t e5.erience% an& co**on $en$e *u$t all be factore& into t/e c/oice of t/e ta$4 $et for a .ro8ect.
97
VU
T/i$ conce.t i$ &e*on$trate& wit/ t/e /el. of following e5a*.le. In t/i$ ca$e TSS 2alue i$ co*.ute& for a new &e2elo.*ent .ro8ect. 9&a.tation Criteria Si+e of .ro&uct Nu*ber of 1$er$ )u$ine$$ Criticalit( Longe2it( Stabilit( of re'uire*ent$ Ea$e of co**unication #aturit( of tec/nolog( 3erfor*ance Con$traint$ E*be&&e& O non-e*be&&e& 3ro8ect Staffing Intero.erabilit( ,eengineering factor$ TSS Gra&e 2 3 4 3 2 2 2 3 3 2 4 0 ;eig/t 1.2 1.1 1.1 0." 1.2 0." 0." 0. 1.2 1.0 1.1 1.2 Entr( .oint *ulti.lier New 7e2elo.*ent 1 1 1 1 1 1 1 1 1 1 1 0 3ro&uct 2.4 3.3 4.4 2.! 2.4 1. 1. 2.4 3.6 2.0 4.4 0 2.6
Since t/e 2alue of TSS i$ 2.6% t/e &egree of rigor coul& be $tructure& or $trict. T/e .ro8ect *anager now nee&$ to u$e /i$ e5.erience to &eter*ine w/ic/ of t/e two a..roac/e$ $/oul& be ta4en. TSS ^ 1.2 1.0 F 3.0 ` 2.4 +egree of 4igor Ca$ual Structure& Strict
98
VU
+efining a Ta%( Networ( Ance t/e ta$4$ /a2e been i&entifie&% we nee& to &e2elo. a ta$4 networ4 to &eter*ine t/e $e'uence in w/ic/ t/e$e acti2itie$ nee& to be .erfor*e&. T/i$ will ulti*atel( lea& to t/e ti*e re'uire& to co*.lete t/e .ro8ect Hto be &i$cu$$e& laterJ. T/e following &iagra* $/ow$ t/e ta$4 networ4 for t/e abo2e .ro8ect.
1.6 Integrate
99
VU
T/e$e are 'uantitati2e tool$ t/at allow t/e $oftware .lanner to &eter*ine t/e critical .at/ F t/e c/ain of ta$4$ t/at &eter*ine$ t/e &uration of t/e .ro8ect an& e$tabli$/ *o$t li4el( ti*e e$ti*ate$ for in&i2i&ual ta$4$ b( a..l(ing $tati$tical *o&el$. T/e( al$o /el. t/e .lanner to calculate boun&ar( ti*e$ t/at &efine a ti*e win&ow for a .articular ta$4. T/e boun&ar( ti*e &efine$ t/e following .ara*eter$ for a .ro8ect6 $ $ $ $ $ T/e earlie$t ti*e t/at a ta$4 can begin w/en all .rece&ing ta$4$ are co*.lete& in t/e $/orte$t .o$$ible ti*e T/e late$t ti*e for ta$4 initiation before t/e *ini*u* .ro8ect co*.letion ti*e i$ &ela(e& T/e earlie$t fini$/ T/e late$t fini$/ T/e total float F t/e a*ount of $ur.lu$ ti*e or leewa( allowe& in $c/e&uling ta$4$ $o t/at t/e networ4 critical .at/ i$ *aintaine& on $c/e&ule
In or&er to u$e t/e 3E,T an& C3#% t/e following i$ re'uire&6 $ 9 &eco*.o$ition of .ro&uct function $ 9 $election of a..ro.riate .roce$$ *o&el an& ta$4 $et $ 7eco*.o$ition of ta$4$ F al$o 4nown a$ t/e wor4 brea4&own $tructure H;)SJ $ E$ti*ation of effort $ Inter&e.en&encie$ Ti'eline C!art To &e2elo. t/e $c/e&ule for a .ro8ect% ti*e re'uire& for eac/ acti2it( in t/e Ta$4 Networ4 i$ e$ti*ate&. T/i$ anal($i$ an& &eco*.o$ition lea&$ to t/e &e2elo.*ent of a Ti*eline or Gantt C/art for t/e .ro8ect w/ic/ .ortra($ t/e $c/e&ule for t/e .ro8ect. 9$ an e5a*.le% let u$ a$$u*e t/at Conce.t Sco.ing Ht/e fir$t ta$4 in t/e abo2e li$tJ i$ furt/er $ub&i2i&e& into t/e following $ub-ta$4$ wit/ t/e a$$ociate& e$ti*ate& ti*e re'uire*ent$6 1. 2. 3. 4. 5. 6. !. I&entification of nee&$ an& benefit$ H3 &a($J 7efinition of &e$ire& out.utOcontrolOin.ut H! &a($J 7efinition of t/e functionObe/a2iour H6 &a($J I$olation of $oftware ele*ent$ H1 &a(J ,e$earc/ing a2ailabilit( of e5i$ting $oftware H2 &a($J 7efinition tec/nical fea$ibilit( H4 &a($J #a4ing 'uic4 e$ti*ate of $i+e H1 &a(J
100
VU
;e al$o a$$u*e t/at t/e following ta$4 networ4 for t/i$ wa$ &e2elo.e&.
1.1.4 I$olation of $oftware ele*ent$
T/i$ i$ now con2erte& in t/e following $c/e&ule in t/e for* of a Gantt C/art. Note t/at% t/e conce.t of boun&ar( ti*e allow$ u$ to $c/e&ule Ta$4 Nu*ber$ 1.1.4 an& 1.1.5 an(w/ere along Ta$4 Nu*ber 1.1.3. T/e actual ti*e i$ &eter*ine& b( t/e .ro8ect *anager i$ ba$e& u.on t/e a2ailabilit( of re$ource$ an& ot/er con$traint$. Eac/ ta$4 i$ furt/er $ub&i2i&e& in $ub-ta$4$ in t/e $a*e *anner until t/e $c/e&ule for t/e co*.lete .ro8ect i$ &eter*ine&.
Trac(ing a Sc!edule
101
VU
T/e la$t two tec/ni'ue$ are &i$cu$$e& in furt/er &etail in t/e following .aragra./$6 Earned Value #nal2%i% Earne& 0alue 9nal($i$ or E09 i$ a 'uantitati2e tec/ni'ue for a$$e$$ing t/e .rogre$$ of a .ro8ect. T/e earne& 2alue $($te* .ro2i&e$ a co**on 2alue $cale for e2er( $oftware ta$4% regar&le$$ of t/e t(.e of wor4 being .erfor*e&. T/e total /our$ to &o t/e w/ole .ro8ect are e$ti*ate&% an& e2er( ta$4 i$ gi2en an earne& 2alue ba$e& on t/e e$ti*ate& .ercentage of t/e total. In or&er to &o t/e E09% t/e bu&gete& co$t of wor4 $c/e&ule H)C;SJ i$ &eter*ine& a$ follow$6 Let )C;Si Z effort H.er$on-&a($ etcJ for ta$4i )C;S i$ t/en t/e 3rogre$$ $o far F a&& all )C;Si $o far. Now )9C Z bu&get at co*.letion Z [ )C;Si Now if )C;3 i$ t/e )u&gete& Co$t of ;or4 3erfor*% t/en Sc/e&ule .erfor*ance in&e5 Sc/e&ule 2ariance S3I Z )C;3O)C;S S0 Z )C;3 F )C;S
S3I clo$e to 1 in&icate$ efficient e5ecution. Si*ilarl( 3ercent $c/e&ule& for co*.letion Z )C;SO)9C 3ercent co*.lete Z )C;3O)9C 9ctual co$t wor4 .erfor*e& 9C;3 Co$t .erfor*ance in&e5 C3I Z )C;3O9C;3 Co$t 2ariance C0 Z )C;3 F 9C;3 Now% 2alue of C3I clo$e to 1 *ean$ .ro8ect i$ wit/in it$ &efine& bu&get. - Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
102
VU
T/erefore% b( u$ing S3I an& C3I we e$ti*ate /ow t/e .ro8ect i$ .rogre$$ing. If we /a2e t/e$e 2alue$ clo$e to 1% it *ean$ t/at we /a2e /a& goo& e$ti*ate$ an& t/e .ro8ect i$ un&er control.
103
VU
;e now recor& t/e nu*ber of error$ foun& &uring eac/ SE $te. an& calculate current 2alue$ for Ere'% E&e$ign% an& Eco&e. T/e$e 2alue$ are t/en co*.are& to a2erage$ of .a$t .ro8ect$. If t/e current re$ult$ 2ar( *ore t/an 20B fro* a2erage% t/ere *a( be cau$e for concern an& t/ere i$ certainl( cau$e for in2e$tigation. E)a'*le $ $ Ere' for t/e current .ro8ect Z 2.1 Argani+ational a2erage Z 3.6 + Two .o$$ibilitie$ $ T/e tea* /a$ &one an out$tan&ing 8ob $ T/e tea* /a$ been la5 in it$ re2iew a..roac/ + If t/e $econ& $cenario a..ear$ li4el( $ )uil& a&&itional &e$ign ti*e be u$e& to better target re2iew an&Oor te$ting re$ource$ in t/e following 120 co*.onent$ 32 e5/ibit E&e$ign ` 1.2 a2erage 9&8u$t co&e re2iew re$ource$ accor&ingl(
104
VU
Ti*e-bo5ing i$ u$e& in $e2ere &ea&line .re$$ure. It i$ a u$e incre*ental $trateg( w/ere ta$4$ a$$ociate& wit/ eac/ incre*ent are ti*e-bo5e& in t/e following *anner6 $ $ $ Sc/e&ule for eac/ ta$4 i$ a&8u$te& b( wor4ing bac4war& fro* t/e &eli2er( &ate. 9 bo5 i$ .ut aroun& eac/ ta$4 ;/en a ta$4 /it$ t/e boun&ar( of t/e bo5% wor4 $to.$ an& ne5t ta$4 begin$
T/e .rinci.le be/in& ti*e-bo5ing i$ t/e "0-10 rule H$i*ilar to 3areto 3rinci.leJ F rat/er t/an beco*ing $tuc4 on t/e 10B of a ta$4% t/e .ro&uct .rocee&$ towar&$ t/e &eli2er( &ate in "0B of t/e ca$e$.
105
VU
9not/er 2er( i*.ortant 'ue$tion i$6 7o (ou nee& to worr( about it after t/e co&e /a$ been generate&L In fact% S@9 i$ an u*brella acti2it( t/at i$ a..lie& t/roug/out t/e $oftware .roce$$. 9l$o% &o we care about internal 'ualit( or t/e e5ternal 'ualit(L 9n& finall(% i$ t/ere a relation$/i. between internal an& e5ternal 'ualitie$L T/at i$% &oe$ internal 'ualit( tran$late in e5ternal 'ualit(L In t/e literature% 'ualit( /a$ been &efine& t/roug/ in *an( &ifferent *anner$. Ane grou. belie2e$ t/at t/e 'ualit( /a$ *ea$urable c/aracteri$tic $uc/ a$ c(clo*atic co*.le5it(% co/e$ion% an& cou.ling. ;e can t/en tal4 about 'ualit( fro* &ifferent a$.ect$. @ualit( of &e$ign trie$ to &eter*ine t/e 'ualit( of &e$ign relate& &ocu*ent$ inclu&ing re'uire*ent$% $.ecification$% an& &e$ign. @ualit( of confor*ance loo4$ at t/e i*.le*entation an& if it follow$ t/e &e$ign t/en t/e re$ulting $($te* *eet$ it$ goal$ t/en confor*ance 'ualit( i$ /ig/. 9re t/ere an( ot/er i$$ue$ t/at nee& to be con$i&ere&L Gla$$ &efine$ 'ualit( a$ a *ea$ure of u$er $ati$faction w/ic/ i$ &efine& b( co*.liant .ro&uct P goo& 'ualit( P &eli2er( wit/in bu&get an& $c/e&ule 7e#arco &efine$ .ro&uct 'ualit( a$ a function of /ow *uc/ it c/ange$ t/e worl& for t/e better. So% t/ere are *an( &ifferent wa( to loo4 at t/e 'ualit(. ;ualit2 #%%urance Goal of 'ualit( a$$urance i$ to .ro2i&e t/e *anage*ent wit/ t/e nece$$ar( &ata to be infor*e& about .ro&uct 'ualit(. It con$i$t$ of au&iting an& re.orting function$ of
106
VU
*anage*ent. If &ata .ro2i&e& t/roug/ @9 i&entifie$ .roble*$% t/e *anage*ent &e.lo($ t/e nece$$ar( re$ource$ to fi5 it an& /ence ac/ie2e$ &e$ire& 'ualit( control. Co%t of &ualit2 9 2er( $ignificant 'ue$tion i$6 &oe$ 'ualit( a$$urance a&& an( 2alue. T/at i$% i$ wort/ $.en&ing a lot of *one( in 'ualit( a$$urance .ractice$L In or&er to un&er$tan& t/e i*.act of 'ualit( a$$urance .ractice$% we /a2e to un&er$tan& t/e co$t of 'ualit( Hor lac4 t/ereofJ in a $($te*. @ualit( /a$ a &irect an& in&irect co$t in t/e for* of co$t of .re2ention% a..rai$al% an& failure. If we tr( to .re2ent .roble*$% ob2iou$l( we will /a2e to incur co$t. T/i$ co$t inclu&e$6 $ $ $ $ @ualit( .lanning =or*al tec/nical re2iew$ Te$t e'ui.*ent Training
;e will &i$cu$$ t/e$e in *ore &etail in t/e later $ection$. T/e co$t of a..rai$al inclu&e$ acti2itie$ to gain in$ig/t into t/e .ro&uct con&ition. It in2ol2e$ in-.roce$$ an& inter-.roce$$ in$.ection an& te$ting. 9n& finall(% failure co$t. =ailure co$t /a$ two co*.onent$6 internal failure co$t an& e5ternal failure co$t. Internal failure co$t re'uire$ rewor4% re.air% an& failure *o&e anal($i$. An t/e ot/er /an&% e5ternal failure co$t in2ol2e$ co$t for co*.laint re$olution% .ro&uct return an& re.lace*ent% /el.-line $u..ort% warrant( wor4% an& law $uit$. It i$ tri2ial to $ee t/at co$t increa$e$ a$ we go fro* .re2ention to &etection to internal failure to e5ternal failure. T/i$ i$ &e*on$trate& wit/ t/e /el. of t/e following e5a*.le6 Let u$ a$$u*e t/at a total of !053 /our$ were $.ent in$.ecting 200%000 line$ of co&e wit/ t/e re$ult t/at 3112 .otential &efect$ were .re2ente&. 9$$u*ing a .rogra**er co$t of S40 .er /our% t/e total co$t of .re2enting 3112 &efect$ wa$ S3 2%120% or roug/l( S"1 .er &efect. Let u$ now co*.are t/e$e nu*ber$ to t/e co$t of &efect re*o2al once t/e .ro&uct /a$ been $/i..e& to t/e cu$to*er. Su..o$e t/at t/ere /a& been no in$.ection$% an& t/e .rogra**er$ /a& been e5tra careful an& onl( one &efect one 1000 line$ e$ca.e& into t/e .ro&uct $/i.*ent. T/at woul& *ean t/at 200 &efect$ woul& $till /a2e to be fi5e& in t/e fiel&. 9$ an e$ti*ate& co$t of S25000 .er fi5% t/e co$t woul& be S5 #illion or a..ro5i*atel( 1 ti*e$ *ore e5.en$i2e t/an t/e total co$t of &efect .re2ention T/at *ean$% 'ualit( tran$late$ to co$t $a2ing$ an& an i*.ro2e& botto* line. S;# #cti,itie% T/ere are two &ifferent grou.$ in2ol2e& in S@9 relate& acti2itie$6 $ $ Software engineer$ w/o &o t/e tec/nical wor4 S@9 grou. w/o i$ re$.on$ible for @9 .lanning% o2er$ig/t% recor& 4ee.ing% anal($i$% an& re.orting Software engineer$ a&&re$$ 'ualit( b( a..l(ing $oli& tec/nical *et/o&$ an& *ea$ure$% con&ucting for*al an& tec/nical re2iew$% an& .erfor*ing well .lanne& $oftware te$ting. T/e S@9 grou. a$$i$t$ t/e $oftware tea* in ac/ie2ing a /ig/ 'ualit( .ro&uct.
107
VU
S;# Frou* #cti,itie% 9n S@9 .lan i$ &e2elo.e& for t/e .ro8ect &uring .ro8ect .lanning an& i$ re2iewe& b( all $ta4e /ol&er$. T/e .lan inclu&e$ t/e i&entification of6 $ $ $ $ $ $ E2aluation$ to be .erfor*e& 9u&it$ an& re2iewe& to be .erfor*e& Stan&ar&$ t/at are a..licable to t/e .ro8ect 3roce&ure$ for error re.orting an& trac4ing 7ocu*ent$ to be .ro&uce& b( t/e S@9 grou. 9*ount of fee&bac4 .ro2i&e& to t/e $oftware .ro8ect tea*
T/e grou. .artici.ate$ in t/e &e2elo.*ent of t/e .ro8ect:$ $oftware .roce$$ &e$cri.tion. T/e $oftware tea* $elect$ t/e .roce$$ an& S@9 grou. re2iew$ t/e .roce$$ &e$cri.tion for co*.liance wit/ t/e organi+ational .olicie$% internal $oftware $tan&ar&$% e5ternall( i*.o$e& $tan&ar&$% an& ot/er .art$ of t/e $oftware .ro8ect .lan. T/e S@9 grou. al$o re2iew$ $oftware engineering acti2itie$ to 2erif( co*.liance wit/ t/e &efine& $oftware .roce$$. It i&entifie$% &ocu*ent$% an& trac4$ &e2iation$ fro* t/e .roce$$ an& 2erifie$ t/at t/e correction$ /a2e been *a&e. In a&&ition% it au&it$ &e$ignate& $oftware wor4 .ro&uct$ to 2erif( co*.liance wit/ t/o$e &efine& a$ .art of t/e $oftware .roce$$. It% re2iew$ $electe& wor4 .ro&uct$% i&entifie$% &ocu*ent$% an& trac4$ &e2iation$C 2erifie$ t/at correction$ /a2e been *a&eC an& re.ort$ t/e re$ult$ of it$ wor4 to t/e .ro8ect *anager. T/e ba$i$ .ur.o$e i$ to en$ure t/at &e2iation$ in $oftware wor4 an& wor4 .ro&uct$ are &ocu*ente& an& /an&le& accor&ing to &ocu*ente& .roce&ure$. T/e$e &e2iation$ *a( be encountere& in t/e .ro8ect .lan% .roce$$ &e$cri.tion% a..licable $tan&ar&$% or tec/nical wor4 .ro&uct$. T/e grou. recor&$ an( non-co*.liance an& re.ort$ to $enior *anage*ent an& non-co*.liant ite*$ are recor&e& an& trac4e& until t/e( are re$ol2e&. 9not/er 2er( i*.ortant role of t/e grou. i$ to coor&inate t/e control an& *anage*ent of c/ange an& /el. to collect an& anal(+e $oftware *etric$. ;ualit2 Control T/e ne5t 'ue$tion t/at we nee& to a$4 i$% once we /a2e &efine& /ow to a$$e$$ 'ualit(% /ow are we going to *a4e $ure t/at our .roce$$e$ &eli2er t/e .ro&uct wit/ t/e &e$ire& 'ualit(. T/at i$% /ow are we going to control t/e 'ualit( of t/e .ro&uctL T/e ba$ic .rinci.le of 'ualit( control i$ to control t/e 2ariation a$ 2ariation control i$ t/e /eart of 'ualit( control. It inclu&e$ re$ource an& ti*e e$ti*ation% te$t co2erage% 2ariation in nu*ber of bug$% an& 2ariation in $u..ort. =ro* one .ro8ect to anot/er we want to *ini*i+e t/e .re&icte& re$ource$ nee&e& to co*.lete a .ro8ect an& calen&ar ti*e. T/i$ in2ol2e$ a $erie$ of in$.ection% re2iew$% an& te$t$ an& inclu&e$ fee&bac4 loo.. So 'ualit( control i$ a co*bination of *ea$ure*ent an& fee&bac4 an& co*bination of auto*ate& tool$ an& *anual interaction.
108
VU
9cce.tance Te$t
Integration Te$t
1nit Te$t
T/e 0-#o&el
109
VU
Tec/nical wor4 nee&$ re2iewing for t/e $a*e rea$on t/at .encil$ nee&$ era$er$6 To err i$ /u*an. T/e $econ& rea$on t/at we nee& tec/nical re2iew$ i$ alt/oug/ t/at .eo.le are goo& at catc/ing error$% large cla$$ of error$ e$ca.e t/e originator *ore ea$il( t/an t/e( e$ca.e an(one el$e. =ree&*an &efine$ a re2iew F an( re2iew F a$ a wa( of u$ing t/e &i2er$it( of a grou. of .eo.le to6 $ 3oint out nee&e& i*.ro2e*ent$ in t/e .ro&uct of a $ingle .er$on or tea* $ Confir* t/o$e .art$ of a .ro&uct in w/ic/ i*.ro2e*ent i$ eit/er not &e$ire& or no nee&e& $ 9c/ie2e tec/nical wor4 of *ore unifor*% or at lea$t *ore .re&ictable% 'ualit( t/an can be ac/ie2e& wit/out re2iew$% in or&er to *a4e tec/nical wor4 *ore *anageable. ,e2iew$ /el. t/e &e2elo.*ent tea* in i*.ro2ing t/e &efect re*o2al efficienc( an& /ence .la( an i*.ortant role in t/e &e2elo.*ent of a /ig/-'ualit( .ro&uct. T2*e% of 4e,iew% T/ere are *an( t(.e$ of re2iew$. In general t/e( can be categori+e& into two *ain categorie$ na*el( infor*al an& for*al tec/nical re2iew$. =or*al Tec/nical re2iew$ are $o*eti*e$ calle& a$ wal4t/roug/$ or in$.ection$. T/e( are t/e *o$t effecti2e filter fro* @9 $tan&.oint. To un&er$tan& t/e $ignificance of t/e$e re2iew$% let u$ loo4 at t/e &efect a*.lification *o&el $/own below. T/i$ *o&el &e.ict$ t/at eac/ &e2elo.*ent $te. in/erit$ certain error$ fro* t/e .re2iou$ $te.. So*e of t/e$e error$ are 8u$t .a$$e& t/roug/ to t/e ne5t $te. w/ile $o*e are wor4e& on an& /ence are a*.lifie& wit/ a ratio of 165. In a&&ition% eac/ $te. *a( al$o generate $o*e new error$. If eac/ $te. /a$ $o*e *ec/ani$* for error &etection% $o*e of t/e$e error$ *a( be &etecte& an& re*o2e& an& t/e re$t are .a$$e& on to t/e ne5t $te..
7efect$ Error$ fro* .re2iou$ $te. Error$ 3a$$e& T/roug/ 9*.lifie& Error$ 165 Newl( generate& error$
Development Step
Let u$ now a$$u*e t/at we &o not /a2e an( S@9 relate& acti2itie$ for t/e fir$t two $tage$ an& we are onl( u$ing te$ting for &etection of an( &efect$. Let u$ a$$u*e t/at t/e
110
VU
3reli*inar( &e$ign generate& 10 &efect$ w/ic/ were .a$$e& on to 7etaile& &e$ign. 9t t/at ./a$e% 6 &efect$ were .a$$e& on to t/e ne5t $tage$ an& 4 were a*.lifie& at a ration of 161.5. In a&&ition% t/ere were 25 new &efect$ intro&uce& at t/i$ $tage. T/erefore% a total of 3! &efect$ were .a$$e& on to t/e ne5t $tage a$ $/own in t/e &iagra*. In t/e Co&e an& 1nite te$t $tage% we $tart to te$t our $($te* an& a$$u*ing 20B &efect re*o2al efficienc( of t/i$ $tage% "4 &efect$ H 0B of H10 P 2! T 3 P 25JJ are .a$$e& on to t/e ne5t $tage. T/i$ .roce$$ continue$ an& t/e $($te* i$ &eli2ere& wit/ 12 &efect$ re*aining in t/e .ro&uct.
0 0 10
10 0B
3reli*inar( 7e$ign
"4
"4 0 0
50B
4! 0 0
50B
24 0 0
Integration te$t
0ali&ation te$t
S($te* te$t
If =T, are u$e& in t/e earlier $tage$% t/e 'ualit( of t/e en&-.ro&uct i$ *uc/ better a$ $/own in t/e following &iagra*. Note t/at in t/i$ ca$e we /a2e co&e in$.ection in a&&ition to unit te$ting at t/e t/ir& $tage an& t/e &efect re*o2al efficienc( of t/at $tage i$ 60B.
0 0 10
3 !0B
0 0
50B
Integration te$t
0ali&ation te$t
S($te* te$t
111
VU
4e,iew 4e*orting and 4ecord (ee*ing - Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
112
VU
7uring t/e =T, t/e recor&er note$ all t/e i$$ue$. T/e( are $u**ari+e& at t/e en& an& a re2iew i$$ue li$t i$ .re.are&. 9 $u**ar( re.ort i$ .ro&uce& t/at inclu&e$6 $ ;/at i$ re2iewe& $ ;/o re2iewe& it $ ;/at were t/e fin&ing$ an& conclu$ion$ It t/en beco*e$ .art of .ro8ect /i$torical recor&. T!e re,iew i%%ue li%t It i$ $o*eti*e$ 2er( u$eful to /a2e a .ro.er re2iew i$$ue li$t. It /a$ two ob8ecti2e$. $ $ I&entif( .roble* area$ wit/in t/e ;3 9ction ite* c/ec4li$t
It i$ i*.ortant to e$tabli$/ a follow-u. .roce&ure to en$ure t/at ite*$ on t/e i$$ue li$t /a2e been .ro.erl( a&&re$$e&. 4e,iew Fuideline% It i$ e$$ential to note t/at an uncontrolle& re2iew can be wor$e t/an no re2iew. T/e ba$i$ .rinci.le i$ t/at t/e re2iew $/oul& focu$ on t/e .ro&uct an& not t/e .ro&ucer $o t/at it &oe$ not beco*e .er$onal. ,e*e*ber to be $en$iti2e to .er$onal ego$. Error$ $/oul& be .ointe& out gentl( an& t/e tone $/oul& be loo$e an& con$tructi2e. T/i$ can be ac/ie2e& b( $etting an agen&a an& *aintaining it. In or&er to &o $o% t/e re2iew tea* $/oul&6 $ $ $ $ $ $ $ $ $ 92oi& &rift Li*it &ebate an& rebuttal Enunciate .roble* area$ but &on:t tr( to $ol2e all .roble*$ Ta4e written note$ Li*it t/e nu*ber of .artici.ant$ an& in$i$t u.on a&2ance& .re.aration 7e2elo. a c/ec4li$t for eac/ .ro&uct t/at i$ li4el( to be re2iewe& 9llocate re$ource$ an& $c/e&ule ti*e for =T,$ Con&uct *eaningful training for all re2iewer$ ,e2iew (our earl( re2iew$ 7eter*ine w/at a..roac/ wor4$ be$t for (ou
113
VU
114
CS605 Software Engineering-II Total 12 3!" ;e can ea$il( $ee t/e following6 $ $ 435 "42
VU
IES% #CC% an& E7, are t/e 2ital error$ F cau$e 53B of all error$ IES% E7,% 3LT% an& E7L are 2ital if onl( $eriou$ error$ are con$i&ere&
;e now $tart correcti2e action focu$e& on 2ital few. =or e5a*.le for E7, we re2iew t/e &ata re.re$entation tec/ni'ue$ to i&entif( t/e .o$$ible i*.ro2e*ent area$ an& a&o.t a u$e ca$e tool for &ata *o&eling an& .erfor* $tringent &ata &e$ign re2iew$. Error Inde) 6EI7 9not/er $tati$tical tec/ni'ue 4nown a$ Error In&e5 HEIJ i$ u$e& to &e2elo. an o2erall in&ication of i*.ro2e*ent in $oftware 'ualit(. T/e EI i$ co*.ute& a$ follow$6 Let $ $ $ $ $ $ Ei F t/e total nu*ber of error$ unco2ere& &uring t/e it/ $te. in t/e SE .roce$$ Si F nu*ber of $eriou$ error$ #i F nu*ber of *o&erate error$ Ti F nu*ber of *inor error$ 3S F .ro&uct $i+e at t/e it/ $te. w$% w*% wt F weig/ting factor$ for $eriou$% *o&erate% an& *inor error$. ,eco**en&e& 2alue$ for t/e$e are 10% 3% 1 re$.ecti2el(.
9t eac/ $te. of t/e $oftware .roce$$ a *hase &ndex i$ co*.ute& a$6 3Ii Z w$HSiOEiJ P w*H#iOEiJ P wtHTiOEiJ Now EI i$ co*.ute& a$ t/e cu*ulati2e effect on eac/ 3Ii Z [HI 5 3IiJO3S It i$ i*.ortant to note t/at weig/ting error$ encountere& in t/e SE .roce$$e$ *ore /ea2il( t/an t/o$e encountere& earlier. 9$ $tate& earlier% it can be u$e& to &e2elo. an o2erall in&ication of i*.ro2e*ent in $oftware 'ualit(. Software 4eliabilit2 Software reliabilit( i$ anot/er 2er( i*.ortant 'ualit( factor an& i$ &efine& a$ .robabilit( of failure free o.eration of a co*.uter .rogra* in a $.ecifie& en2iron*ent for a $.ecifie& ti*e. =or e5a*.le% a .rogra* M can be e$ti*ate& to /a2e a reliabilit( of 0."6 o2er ela.$e& /our$. Software reliabilit( can be *ea$ure&% &irecte&% an& e$ti*ate& u$ing /i$torical an& &e2elo.*ent &ata. T/e 4e( to t/i$ *ea$ure*ent i$ t/e *eaning of ter* failure. =ailure i$ &efine& a$ non-confor*ance to $oftware re'uire*ent$. It can be gra&e& in *an( &ifferent wa($ a$ $/own below6 $ $ $ =ro* anno(ing to cata$tro./ic Ti*e to fi5 fro* *inute$ to *ont/$ ,i..le$ fro* fi5ing
115
VU
It i$ al$o .ertinent to un&er$tan& t/e &ifference between /ar&ware an& $oftware reliabilit(. >ar&ware reliabilit( i$ .re&icte& on failure &ue to wear rat/er t/an failure &ue to &e$ign. In t/e ca$e of $oftware% t/ere i$ no wear an& tear. T/e reliabilit( of $oftware i$ &eter*ine& b( #ean ti*e between failure H#T)=J. #T)= i$ calculate& a$6 #T)= Z #TT= P #TT, ;/ere #TT= i$ t/e #ean Ti*e to =ailure an& #TT, i$ t/e #ean ti*e re'uire& to ,e.air. 9rguabl( #T)= i$ far better t/an &efect$O4loc a$ eac/ error &oe$ not /a2e t/e $a*e failure rate an& t/e u$er i$ concerne& wit/ failure an& not wit/ total error count. 9 relate& i$$ue i$ t/e notion of a2ailabilit(. It i$ &efine& a$ t/e .robabilit( t/at a .rogra* i$ o.erating accor&ing to re'uire*ent$ at a gi2en .oint in ti*e. It can be calculate& a$ 92ailabilit( Z H#TT=O#T)=J 5 100 an& clearl( &e.en&$ u.on #TT,.
116
VU
Ance $($te*-le2el /a+ar&$ are i&entifie&% anal($i$ tec/ni'ue$ are u$e& to a$$ign $e2erit(% an& .robabilit( of occurrence. T/i$ tec/ni'ue i$ $i*ilar to ri$4 anal($i$. To be effecti2e% $oftware *u$t be anal(+e& in t/e conte5t of t/e entire $($te*. 9nal($i$ tec/ni'ue$ $uc/ a$ fault tree anal($i$ can be u$e& to .re&ict t/e c/ain of e2ent$ t/at can cau$e /a+ar&$ an& t/e .robabilit( t/at eac/ of t/e$e e2ent$ will occur to create t/e c/ain. Ance /a+ar&$ are i&entifie& an& anal(+e&% $afet(-relate& re'uire*ent$ can be $.ecifie& for t/e $oftware.
,eliabilit( an& $afet( are clo$el( relate&. Software reliabilit( u$e$ $tati$tical tec/ni'ue$ to &eter*ine t/e li4eli/oo& t/at a $oftware failure will occur. Accurrence of a $oftware failure &oe$ not nece$$aril( re$ult in a /a+ar& or *i$/a.. An t/e ot/er /an&% $oftware $afet( e5a*ine$ t/e wa($ in w/ic/ failure$ re$ult in con&ition$ t/at can lea& to a *i$/a..
117
VU
C!aracteri%tic of a 1o(a-2o(e de,ice $ $ $ It i$ $i*.le an& c/ea. It i$ .art of t/e .roce$$ It i$ locate& near t/e .roce$$ ta$4 w/ere t/e *i$ta4e occur$
E)a'*le of 1o(a-2o(e in %oftware Let u$ a$$u*e t/at aa9 $oftware .ro&uct$ co*.an( $ell$ a..lication $oftware to an international *ar4et. T/e .ull-&own *enu$ an& a$$ociate& *ne*onic$ .ro2i&e& wit/ eac/ a..lication *u$t reflect t/e local language. =or e5a*.le% t/e Engli$/ language *enu ite* for DClo$eE /a$ t/e *ne*onic DCE a$$ociate& wit/ it. ;/en t/e a..lication i$ $ol& to 1r&u $.ea4ing u$er$% t/e $a*e *enu ite* i$ D)an& IarenE wit/ *ne*onic EbE. To i*.le*ent t/e a..ro.riate *enu entr( for eac/ locale% a Dlocali+erE tran$late$ t/e *enu$ accor&ingl(. T/e .roble* i$ to en$ure t/at eac/ *enu entr( confor*$ to a..ro.riate $tan&ar&$ an& t/ere are no conflict$% regar&le$$ of t/e language u$e&. ;e can con$i&er a .re2ention &e2ice to write a .rogra* to generate *ne*onic$ auto*aticall(% gi2en a li$t of label$ in eac/ *enu. It woul& .re2ent *i$ta4e$% but t/e .roble* of c/oo$ing a goo& *ne*onic i$ &ifficult an& t/e effort re'uire& woul& not be 8u$tifie& b( t/e benefit gaine&. It i$ t/erefore not a goo& 3o4a-(o4e &e2ice a$ it i$ not $i*.le. ;e now con$i&er anot/er .re2ention &e2ice. In t/i$ ca$e we write a .rogra* to .re2ent t/e locali+er fro* c/oo$ing *ne*onic$ t/at &i& not *eet t/e criteria. It woul& .re2ent *i$ta4e$ but t/e benefit i$ *ini*al a$ incorrect *ne*onic$ are ea$( enoug/ to &etect an& correct after t/e( occur. So once again t/i$ i$ not a goo& c/oice. ;e now con$i&er a &etection &e2ice. In t/i$ ca$e we write a .rogra* to 2erif( t/at t/e c/o$en *enu label$ an& *ne*onic$ *eet t/e criteria. ;e run t/i$ .rogra* to &etect error$. Error$ are $ent bac4 to locali+er. Since t/i$ &e2ice re'uire$ a lot of bac4 an& fort/ *o2e*ent% it 2iolate$ t/e .rinci.le of co-location. ;e now *o&if( it to t/e following &etection &e2ice. ;e write a .rogra* to 2erif( t/at t/e c/o$en *enu label$ an& *ne*onic$ *eet t/e criteria. T/e locali+er woul& run t/i$ .rogra* to &etect error$. It woul& gi2e 'uic4 fee&bac4 an& /ence it i$ a goo& 3o4a-(o4e &e2ice.
118
VU
119
CS605 Software Engineering-II T/ere wa$ a *inor .roble*% I fi5e& it but it i$ no longer wor4ing o I can:t figure-out t/e c/ange$ *a&e to t/e .re2iou$ 2er$ion. o I can:t go bac4
VU
T/en t/ere are $oftware &eli2er( .roble*$. D;/ic/ configuration &oe$ t/i$ cu$to*er /a2eLE D7i& we &eli2er a con$i$tent configurationLE D7i& t/e cu$to*er *o&if( t/e co&eLE DT/e cu$to*er $4i..e& t/e .re2iou$ two relea$e$. ;/at /a..en$ if we $en& /i* t/e new oneLE S/i..e& t/e wrong 2er$ion to t/e client.
T/i$ i$ not all. T/ere *a( be *ore c/ao$ in t/e following $/a.e$ an& for*$6 T/e &e$ign &ocu*ent i$ out of $(nc wit/ .rogra*$ I &on:t 4now if all t/e c/ange$ t/at were $ugge$te& /a2e been incor.orate& ;/ic/ co&e wa$ $ent to te$tingL
SC# i$ a function t/at% if i*.le*ente&% will re&uce t/e$e .roble*$ to a *ini*al le2el. Configuration 'anage'ent 9$ &efine& b( C##% t/e .ur.o$e of SC# i$ to e$tabli$/ an& *aintain t/e integrit( or $oftware .ro&uct$ t/roug/ t/e .ro8ect:$ life c(cle. Configuration *anage*ent i$ concerne& wit/ *anaging e2ol2ing $oftware $($te*$. It ac4nowle&ge$ t/at $($te* c/ange i$ a tea* acti2it( an& t/u$ it ai*$ to control t/e co$t$ an& effort in2ol2e& in *a4ing c/ange$ to a $($te*. SC# in2ol2e$ t/e &e2elo.*ent an& a..lication of .roce&ure$ an& $tan&ar&$ to *anage an e2ol2ing $oftware .ro&uct an& i$ .art of a *ore general 'ualit( *anage*ent .roce$$. "a%eline ;/en relea$e& to C#% $oftware $($te*$ are calle& baselines an& $er2e a$ t/e $tarting .oint for furt/er &e2elo.*ent.9 ba$eline i$ a $oftware configuration *anage*ent conce.t t/at /el.$ u$ to control c/ange wit/out $eriou$l( i*.e&ing 8u$tifiable c/ange. It i$ &efine& b( IEEE a$6 % specification or a product that has been formally reviewed and agreed upon, that thereafter serves as the basis for further development, and that can be changed only through formal change control procedures. Software Configuration Ite' 6SCI7 9 Software Configuration Ite* i$ t/e infor*ation t/at i$ create& a$ .art of t/e $oftware engineering .roce$$. T(.ical SCI$ inclu&e re'uire*ent $.ecification$% &e$ign $.ecification% $ource co&e% te$t ca$e$ an& recor&e& re$ult$% u$er gui&e$ an& in$tallation *anual$% e5ecutable .rogra*$% an& $tan&ar&$ an& .roce&ure$ Hfor e5a*.le CPP &e$ign gui&eline$J. Software Configuration -anage'ent Ta%(%
120
CS605 Software Engineering-II Software configuration *anage*ent ta$4$ inclu&e6 I&entification 0er$ion Control C/ange Control Configuration 9u&iting ,e.orting
VU
I&entification a&&re$$e$ /ow &oe$ an organi+ation i&entif( an& *anage t/e *an( e5i$ting 2er$ion$ of a .rogra* in a *anner t/at will enable c/ange$ to be acco**o&ate& efficientl(L 0er$ion Control tal4$ about /ow &oe$ an organi+ation control c/ange$ before an& after $oftware i$ relea$e& to a cu$to*erL It i$ actuall( a co*bination of .roce&ure$ an& tool$ to *anage &ifferent 2er$ion$ of t/e $oftware configuration. Cle** $tate$ t/at (onfiguration management allows the user to specify alternative configurations of the software system through the selection of the appropriate versions. his is supported by associating with each software version, and then allowing configuration to be specified and constructed by describing the set of desired attributes. 9 2er$ion /a$ *an( &ifferent attribute$. In t/e $i*.le$t for* a $.ecific 2er$ion nu*ber t/at i$ attac/e& to eac/ ob8ect an& in t/e co*.le5 for* it *a( /a2e a $tring of )oolean 2ariable$ H$witc/e$J t/at in&icate $.ecific t(.e$ of functional c/ange$ t/at /a2e been a..lie& to t/e $($te*. T/e C/ange Control .roce$$ a&&re$$e$ t/e i*.ortant 'ue$tion of w/o /a$ t/e re$.on$ibilit( for a..ro2ing an& ran4ing c/ange$. Configuration 9u&iting &eal$ wit/ en$uring t/at t/e c/ange$ /a2e been *a&e .ro.erl( an& finall( ,e.orting tal4$ about t/e *ec/ani$* u$e& to a..ri$e ot/er$ of c/ange$ t/at are *a&e. Configuration I&entification in2ol2e$ i&entification of a tool for SC#. T/en a ba$eline i$ e$tabli$/e& an& i&entifie& w/ic/ i$ t/en u$e& to i&entif( configurable $oftware ite*$. 9t t/e *ini*u*% all &eli2erable$ *u$t be i&entifie& a$ configurable ite*$. T/i$ inclu&e$ &e$ign% $oftware% te$t ca$e$% tutorial$% an& u$er gui&e$.
121
VU
4elea%e Nu'bering
Eac/ in&i2i&ual .ro&uct relea$e i$ 2iewe& a$ being in a uni'ue $tate w/ic/ i$ t/e total $et of functionalit( .o$$e$$e& b( t/e .ro&uct relea$e. ,elea$e nu*bering i$ a *ec/ani$* to i&entif( t/e .ro&uct:$ functionalit( $tate. Eac/ relea$e will /a2e a &ifferent .ro&uct $tate an& /ence will /a2e a &ifferent relea$e nu*ber. 9lt/oug/ t/ere i$ no in&u$tr( $tan&ar&% t(.icall(% a t/ree fiel& co*.oun& nu*ber of t/e for*at DM.<.XE i$ u$e&. T/e &ifferent fiel&$ co**unicate functionalit( infor*ation about t/e .ro&uct relea$e. T/e fir$t &igit% M% i$ u$e& for t/e *a8or relea$e nu*ber w/ic/ i$ u$e& to i&entif( a *a8or increa$e in t/e .ro&uct functionalit(. T/e *a8or relea$e nu*ber i$ u$uall( incre*ente& to in&icate a $ignificant c/ange in t/e .ro&uct functionalit( or a new .ro&uct ba$e-line. T/e $econ& &igit% <% $tan&$ for feature relea$e nu*ber. T/e feature relea$e nu*ber i$ iterate& to i&entif( w/en a $et of .ro&uct feature$ /a2e been a&&e& or $ignificantl( *o&ifie& fro* t/eir originall( &ocu*ente& be/a2iour. T/e t/ir& &igit% X% i$ calle& t/e &efect re.air nu*ber an& i$ incre*ente& w/en a $et of &efect$ i$ re.aire&. 7efect re.airO*aintenance i$ con$i&ere& to be an( acti2it( t/at $u..ort$ t/e relea$e functionalit( $.ecification an& it *a( a fi5 for $o*e bug$ or $o*e *aintenance to en/ance t/e .erfor*ance of t/e a..lication. Con2entionall(% a relea$e nu*ber $tart$ wit/ a *a8or nu*ber of one% followe& b( +ero for it$ feature an& *aintenance nu*ber$. T/i$ re$ult$ in a relea$e nu*ber 1.0.0. If t/e fir$t new relea$e t/at i$ nee&e& i$ a &efect re.air relea$e% t/e la$t &igit woul& be iterate& to one% re$ulting in 1.0.1. If two a&&itional &efect re.air relea$e$ are nee&e&% we woul& e2entuall( /a2e a relea$e nu*ber of 1.0.3. 9$$u*e t/at an u.gra&e feature relea$e i$ now nee&e&. ;e will nee& to iterate t/e $econ& fiel& an& will roll bac4 t/e &efect re.air nu*ber to 0% re$ulting in a relea$e nu*ber of 1.1.0. ;/en we iterate t/e *a8or relea$e i&entifier% bot/ t/e feature an& &efect nu*ber$ woul& be re$et bac4 to +ero.
122
VU
123
CS605 Software Engineering-II T/e following &iagra* &e.ict$ t/e abo2e *entione& 2er$ion nu*bering $($te*.
VU
.8/8/
.8/8.
.8/80
.8.8/
.8.8.
.808/
First Release
)#grade release to add features and fi& defects8 can !e !ased on .8/8/' .8/8.' or .8/80
)#grade release to add features and fi& defects8 can !e !ased on .8.8/ or .8.8.
C!ange control ?a*e$ )ac4 .oint$ out t/e &ifficultie$ relate& to c/ange control a$ follow$6 (hange control is vital. 7ut the forces that make it necessary also make it annoying. ,e worry about change because a tiny perturbation in the code can cause a big failure in the product. 7ut it can also fix a big failure or enable wonderful new capabilities. ,e worry about change because a single rogue developer could sink the pro!ect- yet brilliant ideas originate in the minds of those rogues, and a burdensome change control process could discourage them from doing creative work. T/at i$% li4e all engineering acti2itie$% c/ange control i$ t/e na*e of a balancing act. Too *uc/ or too little c/ange control create$ &ifferent t(.e$ of .roble*$ a$ uncontrolle& c/ange ra.i&l( lea&$ to c/ao$. T/e c/ange control .roce$$ i$ elaborate& in t/e following $ub-$ection.
124
VU
125
VU
S(nc/roni+ation control i*.le*ent$ a control on u.&ate$. ;/en a co.( i$ c/ec4e&-out% ot/er co.ie$ can be c/ec4e& out for u$e onl( but t/e( cannot be *o&ifie&. In e$$ence% it i*.le*ent$ a $ingle-writer *ulti.le-rea&er$ .rotocol. T/i$ .roce$$ i$ &e.icte& in t/e following &iagra*.
Check( in
unlock
oft7are engineer
Access control
*7nershi# info
Project D9
Configuration #udit Configuration au&it en$ure$ t/at a c/ange /a$ been .ro.erl( i*.le*ente&. It in2ol2e$ for*al tec/nical re2iew$ an& $oftware configuration au&it. Configuration au&it a$$e$$ a configuration ob8ect for c/aracteri$tic$ t/at are generall( not con$i&ere& &uring au&it. It i$ con&ucte& b( t/e S@9 grou.. It loo4$ into t/e following a$.ect$ of t/e c/ange6 >a$ t/e c/ange $.ecifie& in t/e ECA been *a&eL >a2e an( a&&itional *o&ification$ been incor.orate&L >a$ a =T, been con&ucte& to a$$e$$ tec/nical correctne$$L >a$ t/e $oftware .roce$$ been followe&L >a2e t/e SE $tan&ar&$ been .ro.erl( a..lie&L >a$ t/e c/ange been /ig/lig/te& in t/e SCIL o C/ange &ate an& aut/or o >a2e t/e attribute$ of t/e configuration ob8ect been u.&ate&L >a2e t/e SC# .roce&ure$ for noting t/e c/ange% recor&ing it% an& re.orting it been followe&L >a2e all relate& SCI:$ been .ro.erl( u.&ate&L
9n au&it re.ort i$ finall( generate& an& an( non-co*.liance$ are /ig/lig/te& $o t/at t/e( *a( be correcte&.
126
VU
Configuration Statu% re*orting 6CS47 Configuration Statu$ ,e.orting HCS,J i$ al$o 4nown a$ $tatu$ accounting. It re.ort$ on t/e following ite*$6 F F F F ;/at /a..ene&L ;/o &i& itL ;/en &i& it /a..enL ;/at el$e will be affecte&L
If it i$ not &one t/en t/e organi+ation face$ t/e left /an& not 4nowing w/at t/e rig/t /an& i$ &oing $(n&ro*e. ;it/out it% if a .er$on re$.on$ible for t/e c/ange lea2e$ for w/ate2er rea$on% it woul& be &ifficult to un&er$tan& t/e w/ole $cenario. CS, re.ort$ are generate& on regular ba$i$. Eac/ ti*e an SCI i$ a$$igne& a new i&entification% a CS, entr( i$ *a&e. Eac/ ti*e a c/ange i$ a..ro2e& b( CC9% a CS, entr( i$ *a&e. 9l$o% eac/ ti*e configuration au&it i$ con&ucte&% t/e re$ult$ are re.orte& a$ .art of CS, ta$4.
127
VU
Lecture No. 36 4e&uire'ent -anage'ent and C-C- %tandard% C# $/oul& alwa($ be ba$e& on a $et of $tan&ar&$ w/ic/ are a..lie& wit/in an organi$ation. Stan&ar&$ $/oul& &efine /ow ite*$ are i&entifie&% /ow c/ange$ are controlle& an& /ow new 2er$ion$ are *anage&. Stan&ar&$ *a( be ba$e& on e5ternal C# $tan&ar&$ He.g. IEEE $tan&ar& for C# 9NSIOIEEE St&. No. 2 -1" 3% 1042-1" !% 102 1" J. E5i$ting $tan&ar&$ are ba$e& on a waterfall .roce$$ *o&el - new $tan&ar&$ are nee&e& for e2olutionar( &e2elo.*ent. T!e 4e&uire'ent 1roble' T/e goal of $oftware &e2elo.*ent i$ to &e2elo. 'ualit( $oftware F on ti*e an& on bu&get F t/at *eet$ cu$to*er$: real nee&$. 3ro8ect $ucce$$ &e.en&$ on goo& re'uire*ent *anage*ent. It *a( be recalle& t/at re'uire*ent error$ are t/e *o$t co**on t(.e of $oftware &e2elo.*ent error$ an& t/e *o$t co$tl( to fi5. It *a( al$o be recalle& t/at re'uire*ent error$ are li$te& a$ one of t/e root$ cau$e$ of $oftware .ro8ect failure. 9ccor&ing to a Stan&i$/ Grou. re.ort% lac4 of u$er in.ut i$ re$.on$ible for13B of all .ro8ect failure$C inco*.lete re'uire*ent$ an& $.ecification$ for 12B of all .ro8ect failure$C an& c/anging re'uire*ent$ are re$.on$ible for 12B of all .ro8ect failure$.
T/e abo2e gra./ $/ow$ t/e re$ult of an in&u$tr( $ur2e(. It i$ clear to $ee t/at re'uire*ent $.ecification$ are con$i&ere& to be t/e *o$t $ignificant cau$e of *a8or $oftware .roble*$ b( a *a8orit( of .ractitioner$.
128
VU
4e&uire'ent -anage'ent ,e'uire*ent *anage*ent i$ al$o one of t/e 5 I39 &efine& at C## le2el 2. ;it/out /a2ing a .ro.er re'uire*ent *anage*ent function% c/ance$ of a .ro8ect:$ $ucce$$ are $li*. ,e'uire*ent$ #anage*ent I39 Goal$ $tate*ent $a($ t/at6 1. T/e $oftware re'uire*ent$ are controlle& to e$tabli$/ a ba$eline for $oftware engineering an& *anage*ent u$e. 2. Software .lan$% .ro&uct$% an& acti2itie$ are 4e.t con$i$tent wit/ t/e $oftware re'uire*ent$. ,e'uire*ent #anage*ent i$ &efine& a$ a $($te*atic a..roac/ to eliciting% organi+ing% an& &ocu*enting t/e re'uire*ent$ of t/e $($te*% an& a .roce$$ t/at e$tabli$/e$ an& *aintain$ agree*ent between t/e cu$to*er an& t/e .ro8ect tea* on t/e c/anging re'uire*ent$ of t/e $($te*. It inclu&e$ e$tabli$/ing an& *aintaining an agree*ent wit/ t/e cu$to*er on t/e re'uire*ent for t/e $oftware .ro8ect. It in2ol2e$ 7efining t/e re'uire*ent ba$eline ,e2iewing .ro.o$e& re'uire*ent c/ange$ an& e2aluating t/e li4el( i*.act of eac/ .ro.o$e& c/ange before &eci&ing w/et/er to a..ro2e it Incor.orating a..ro2e& re'uire*ent c/ange$ in t/e .ro8ect in a controlle& *anner Iee.ing .ro8ect .lan$ current wit/ t/e re'uire*ent$ Negotiating new co**it*ent$ ba$e& on e$ti*ate& i*.act on c/ange& re'uire*ent$ Tracing in&i2i&ual re'uire*ent$ to t/eir corre$.on&ing &e$ign% $ource co&e% an& te$t ca$e$ Trac4ing re'uire*ent $tatu$ an& c/ange acti2it( t/roug/out t/e .ro8ect 4e&uire'ent #ttribute% ;e nee& to tag re'uire*ent$ wit/ certain attribute$ in or&er to *anage t/e* in an or&erl( fa$/ion. 9ttribute$ are u$e& to e$tabli$/ a conte5t an& bac4groun& for eac/ re'uire*ent. T/e( go be(on& t/e &e$cri.tion of inten&e& functionalit(. T/e( can be u$e& to filter% $ort% or 'uer( to 2iew $electe& $ub$et of t/e re'uire*ent$. 9 li$t of .o$$ible attribute$ i$ enu*erate& a$ below6 1. 2. 3. 4. 5. 6. !. . ". ,e'uire*ent I7 Creation &ate Create& b( La$t *o&ifie& on La$t *o&ifie& b( 0er$ion nu*ber Statu$ Arigin Sub$($te*
129
CS605 Software Engineering-II 10. 3ro&uct ,elea$e 11. 3riorit( 4e&uire'ent Statu%
VU
T/e re'uire*ent $tatu$ attribute i$ one of t/e *o$t u$eful one$. It can be u$e& to 4ee. trac4 of &ifferent re'uire*ent$ going t/roug/ &ifferent ./a$e$. T/e .o$$ible $tatu$ 2alue$ are .ro.o$e&% a..ro2e&% i*.le*ente&% 2erifie&% an& &elete&. T/e$e are elaborate& in t/e following .aragra./$. 1. 3ro.o$e&6 T/e re'uire*ent /a$ been re'ue$te& b( a $ource w/o /a$ t/e aut/orit( to .ro2i&e re'uire*ent$. 2. 9..ro2e&6 T/e re'uire*ent /a$ been anal(+e&% it$ i*.act on t/e re$t of t/e .ro8ect /a$ been e$ti*ate&% an& it /a$ been allocate& to t/e ba$eline for a $.ecific buil& nu*ber or .ro&uct relea$e. T/e $oftware &e2elo.*ent grou. /a$ co**itte& to i*.le*ent t/e re'uire*ent. 3. I*.le*ente&6 T/e co&e t/at i*.le*ent$ t/e re'uire*ent /a$ been &e$igne&% written% an& unit te$te&. 4. 0erifie&6 T/e i*.le*ente& re'uire*ent /a$ been 2erifie& t/roug/ t/e $electe& a..roac/% $uc/ a$ te$ting or in$.ection. T/e re'uire*ent /a$ been trace& to .ertinent te$t ca$e$. T/e re'uire*ent i$ now con$i&ere& co*.lete. 5. 7elete&6 9 .lanne& re'uire*ent /a$ been &elete& fro* t/e ba$eline. Inclu&e an e5.lanation of w/( an& b( w/o* t/e &eci$ion wa$ *a&e to &elete t/e re'uire*ent. C!ange 4e&ue%t Statu% 9$ t/e re'uire*ent go t/roug/ &ifferent ./a$e$% t/eir $tatu$ i$ u.&ate& accor&ingl(. T/e following $tate tran$ition &iagra* ca.ture$ t/e $e'uence of re'uire*ent $tatu$ c/ange$.
*riginator su!mits su!mitted a change request 4"aluator CC9 decided #erformed not to 4"aluated Rejected im#act make the analysis change Change A##ro"ed A##ro"ed Change 7as canceled
,erification failed
Canceled
Change 7as Change Made Modifier has installed the canceled #roduct ,erifier has confirmed Closed the change Change 7as Modifier has installed the ,erified #roduct canceled
130
VU
T/e c/ange$ in t/e re'uire*ent $tatu$ can be .lotte& a$ $/own below to get an i&ea of t/e $tabilit( of t/e re'uire*ent$ an& t/e .rogre$$ of t/e .ro8ect. It i$ ea$( to $ee t/at it i$ nor*al to /a2e un$table re'uire*ent$ in t/e beginning but if t/e( re'uire*ent$ $ta(e& 2olatile till t/e en& t/en t/e .rogre$$ woul& be $low.
131
VU
-anaging Sco*e Cree* ;e *u$t alwa($ re*e*ber t/at re'uire*ent$ will c/ange% no *atter w/at . T/at *ean$ we /a2e to be able to *anage c/anging re'uire*ent$. Software organi+ation$ an& .rofe$$ional$ *u$t learn to *anage c/anging re'uire*ent$. 9 *a8or i$$ue in re'uire*ent$ engineering i$ t/e rate at w/ic/ re'uire*ent$ c/ange once t/e re'uire*ent$ ./a$e /a$ Dofficiall(E en&e&. ;e t/erefore nee& to tr( to ta4e it to a *ini*u* le2el. =or t/at we nee& to *ea$ure t/e c/ange acti2it(.
132
VU
133
VU
4e&uire'ent Traceabilit2 ,e'uire*ent traceabilit( i$ a 2er( i*.ortant con$i&eration for re'uire*ent *anage*ent. It i$ reall( /ar& to *anage re'uire*ent$ t/at are not traceable. 9 Software ,e'uire*ent S.ecification HS,SJ i$ trace& if t/e origin of it$ re'uire*ent$ i$ clear. T/at *ean$ t/at t/e S,S inclu&e$ reference$ to earlier $u..orti2e &ocu*ent$. 9n S,S i$ traceable if it written in a *anner t/at facilitate$ t/e referencing of eac/ in&i2i&ual re'uire*ent $tate& t/erein. It i$ i*.ortant to trace re'uire*ent$ bot/ wa($. T/at i$ fro* origin of a re'uire*ent to /ow it i$ i*.le*ente&. T/i$ i$ a continuou$ .roce$$. It i$ al$o i*.ortant t/at t/e rationale of re'uire*ent$ *u$t al$o be trace&. Traceabilit( i$ i*.ortant for t/e .ur.o$e$ of certification% c/ange i*.act anal($i$% *aintenance% .ro8ect trac4ing% reengineering% reu$e% ri$4 re&uction% an& te$ting. T/at i$ it .la($ an i*.ortant role in al*o$t e2er( a$.ect of t/e .ro8ect an& it$ life c(cle.
134
VU
A##lication oft7are
uses
4m!eds kno7ledge of
9usiness Rules
Constrains
Runs on
uses
ystem <ard7are
A##lication Data
9usiness Processes
-aintaining Legac2 S2%te' #aintaining legac( $($te* i$ e5.en$i2e. It i$ often t/e ca$e t/at &ifferent .art$ of t/e $($te* /a2e been i*.le*ente& b( &ifferent tea*$% lac4ing con$i$tenc(. 3art or all of t/e $($te* *a( be i*.le*ente& u$ing an ob$olete language. In *o$t ca$e$ $($te* &ocu*entation i$ ina&e'uate an& out of &ate. In $o*e ca$e$ t/e onl( &ocu*entation i$ t/e $ource co&e. In $o*e ca$e$ e2en t/e $ource co&e i$ not a2ailable. #an( (ear$ of *aintenance /a2e u$uall( corru.te& t/e $($te* $tructure% *a4ing it increa$ingl( &ifficult to un&er$tan&. T/e &ata .roce$$e& b( t/e $($te* *a( be *aintaine& in &ifferent file$ w/ic/ /a2e inco*.atible $tructure$. T/ere *a( be &ata &u.lication an& t/e &ocu*entation of t/e &ata it$elf *a( be out of &ate% inaccurate% an& inco*.lete. 9$ far a$ t/e $($te* /ar&ware i$ concerne&% t/e /ar&ware .latfor* *a( be out&ate& an& i$ /ar& to *aintain. In *an( ca$e$% t/e legac( $($te*$ /a2e been written for *ainfra*e /ar&ware w/ic/ i$ no longer a2ailable% e5.en$i2e to *aintain% an& not be co*.atible wit/ current organi+ational IT .urc/a$ing .olicie$. Su..ort $oftware inclu&e$ AS% &ataba$e% an& co*.iler etc. Li4e /ar&ware% it *a( be ob$olete an& no longer $u..orte& b( t/e 2en&or$. 9 ti*e t/erefore co*e$ w/en an organi+ation /a$ to *a4e t/i$ &eci$ion w/et/er to 4ee. t/e ol& legac( $($te* or to *o2e it to new .latfor* an& en2iron*ent. #o2ing it to new en2iron*ent i$ 4nown a$ legac( $($te* *igration.
135
VU
Legac2 'igration ri%(% Legac( $($te* *igration /owe2er i$ not an ea$( ta$4 an& t/ere are a nu*ber of ri$4$ in2ol2e& t/at nee& to be *itigate&. =ir$t of all% t/ere i$ rarel( a co*.lete $.ecification of t/e $($te* a2ailable. T/erefore% t/ere i$ no $traig/t forwar& wa( of $.ecif(ing t/e $er2ice$ .ro2i&e& b( a legac( $($te*. T/u$% i*.ortant bu$ine$$ rule$ are often e*be&&e& in t/e $oftware an& *a( not be &ocu*ente& el$ew/ere. )u$ine$$ .roce$$e$ an& t/e wa( legac( $($te*$ o.erate are often intertwine&. New $oftware &e2elo.*ent *a( ta4e $e2eral (ear$. New $oftware &e2elo.*ent i$ it$elf ri$4( a$ c/ange$ to one .art of t/e $($te* ine2itabl( in2ol2e furt/er c/ange$ to ot/er co*.onent$. ;e t/erefore nee& to a$$e$$ a legac( $($te* before a &eci$ion for *igration i$ *a&e. Legac2 S2%te' #%%e%%'ent =or eac/ legac( $($te*% t/ere are four $trategic o.tion$6 1. Scra. t/e $($te* co*.letel(6 T/i$ i$ t/e ca$e w/en $($te* i$ not *a4ing an effecti2e contribution to bu$ine$$ .roce$$e$ an& bu$ine$$ .roce$$e$ /a2e c/ange& $ignificantl( an& t/e organi+ation i$ no longer co*.letel( &e.en&ent u.on t/e $($te*. 2. Continue *aintaining t/e $($te*6 T/i$ o.tion i$ u$e& w/en $($te* i$ $till re'uire&% it i$ $table% an& re'uire*ent$ are not c/anging fre'uentl( 3. Tran$for* t/e $($te* in $o*e wa( to i*.ro2e it$ *aintainabilit(6 t/i$ o.tion i$ e5erci$e& w/en $($te* 'ualit( /a$ been &egra&e& an& regular c/ange$ to t/e $($te* are re'uire&. 4. ,e.lace t/e $($te* wit/ a new $($te*6 t/i$ .at/ i$ ta4en w/en ol& $($te* cannot continue in o.eration an& off-t/e $/elf alternati2e i$ a2ailable or $($te* can be &e2elo.e& at a rea$onable co$t. =or t/e$e &eci$ion$% a legac( $($te* can be a$$e$$e& fro* two &ifferent .er$.ecti2e$ F bu$ine$$ 2alue an& 'ualit(. T/e following four 'ua&rant a$$e$$*ent *atri5 can be u$e& for t/i$ .ur.o$e.
9usiness ,alue
$Im#ortant for !usiness $Cannot !e scra##ed $6o7 quality means high o#erational cost $Candidates for system transformation or re#lacement $=ee#ing these systems in o#eration 7ill !e e&#ensi"e $Rate of return to the !usiness is small $Candidates for scra##ing
$Must !e ke#t in !usiness $<igh quality means lo7 cost of maintenance $%ot necessary to transform or re#lace $Continue normal o#eration $6o7 !usiness "alue !ut not "ery e&#ensi"e to maintain $%ot 7orth the risk of re#lacing them $ hould !e normally maintained or scra##ed
6o7
<igh
6o7
- Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan Quality
<igh
136
VU
"u%ine%% Value #%%e%%'ent It i$ i*.ortant to note t/at t/i$ i$ a $ub8ecti2e 8u&g*ent an& re'uire$ &ifferent bu$ine$$ 2iew.oint$. T/e$e 2iew .oint$ inclu&e en&-u$er$% cu$to*er$% line *anager$% IT *anager$% an& $enior *anager$. En& 1$er$ a$$e$$ t/e $($te* fro* t/e .er$.ecti2e of /ow effecti2e &o t/e( fin& t/e $($te* in $u..orting t/eir bu$ine$$ .roce$$e$ an& /ow *uc/ of t/e $($te* functionalit( i$ u$e&. T/e cu$to*er$ loo4 at t/e $($te* an& a$4 i$ t/e u$e of t/e $($te* tran$.arent to cu$to*er or are t/eir interaction con$traine& b( t/e $($te*% are t/e( 4e.t waiting becau$e of t/e $($te*% an& &o $($te* error$ /a2e a &irect i*.act on t/e cu$to*er. =ro* an IT #anager:$ .er$.ecti2e t/e following 'ue$tion$ nee& to be a$4e&6 9re t/ere &ifficultie$ in fin&ing .eo.le to wor4 on t/e $($te*L 7oe$ t/e $($te* con$u*e re$ource$ w/ic/ coul& be &e.lo(e& *ore effecti2el( on ot/er $($te*$L Line #anager$ a$46 &o *anager$ t/in4 t/at t/e $($te* i$ effecti2e in contributing to $ucce$$ of t/eir unitL I$ t/e co$t of 4ee.ing t/e $($te* in u$e 8u$tifie&L I$ t/e &ata *anage& b( t/e $($te* critical for t/e functioning of t/e *anager:$ unitL Senior #anager$ loo4 at t/e $($te* fro* t/e angle t/at &oe$ t/e $($te* an& a$$ociate& bu$ine$$ .roce$$ *a4e an effecti2e contribution to t/e bu$ine$$ goalL
137
VU
138
VU
3rogra**ing Language6 9re *o&ern co*.iler$ a2ailable for t/e .rogra**ing languageL I$ t/e language $till u$e& for new $($te* &e2elo.*entL Te$t 7ata6 7oe$ te$t &ata for t/e $($te* e5i$tL I$ t/ere a recor& of regre$$ion te$t$ carrie& out w/en new feature$ /a2e been a&&e& to t/e $($te*L 3er$onnel $4ill$6 9re t/ere .eo.le a2ailable w/o /a2e t/e $4ill$ to *aintain t/e $($te*L 9$ *igration i$ a 2er( co$tl( an& ri$4( bu$ine$$% t/e &eci$ion to *igrate t/e $($te* i$ *a&e after a$$e$$ing it fro* all t/e$e angle$ an& it i$ &eter*ine& t/at t/e ti*e /a$ co*e to *igrate t/i$ $($te* an& it i$ wort/ $.en&ing t/e re'uire& a*ount of *one( an& ti*e for un&erta4ing t/at effort. Software 4eengineering Software $olution$ often auto*ate t/e bu$ine$$ b( i*.le*enting bu$ine$$ rule$ an& bu$ine$$ .roce$$e$. In *an( ca$e$% t/e $oftware *a4e$ t/e bu$ine$$ .roce$$e$. 9$ t/e$e rule$ an& .roce$$e$ c/ange% t/e $oftware *u$t al$o c/ange. 9 ti*e co*e$ w/en t/e$e c/ange$ beco*e 2er( &ifficult to /an&le. So reengineering i$ re-i*.le*enting legac( $($te*$ to *a4e t/e* *ore *aintainable. It i$ a long ter* acti2it(. Software 4eengineering 1roce%% -odel T/e $oftware reengineering i$ a non-tri2ial acti2it(. ?u$t li4e legac( *igration% careful anal($i$ *u$t be carrie& out before a &eci$ion for reengineering i$ ta4en. T/e following .roce$$ *o&el can be u$e& to reengineer a legac( $($te*.
/or3ard 6ngineering
Inventor! anal!sis
Data restructuring
Document restructuring
Code restructuring
.everse engineering
In,entor2 anal2%i% In2entor( anal($i$ i$ t/e fir$t $te. in t/e reengineering .roce$$. 9t t/i$ $tage% in2entor( of all a..lication$ i$ ta4en a note of t/eir $i+e% age% bu$ine$$ criticalit(% an& current *aintainabilit( i$ *a&e. In2entor( $/oul& be u.&ate& regularl( a$ t/e $tatu$ of t/e a..lication can c/ange a$ a function of ti*e.
139
VU
+ocu'ent re%tructuring T/e ne5t $te. in t/e reengineering .roce$$ i$ &ocu*ent re$tructuring. ;ea4 &ocu*entation i$ a tra&e*ar4 of *an( legac( a..lication$. ;it/out .ro.er &ocu*entation% t/e /i&&en rule$% bu$ine$$ .roce$$e$% an& &ata cannot be ea$il( un&er$too& an& reengineere&. In t/i$ regar&$% t/e following o.tion$ are a2ailable6 1. Create &ocu*entation6 Creating &ocu*entation fro* $cratc/ i$ 2er( ti*e con$u*ing. If .rogra* i$ relati2el( $table an& i$ co*ing to t/e en& of it$ u$eful life t/en 8u$t lea2e it a$ it i$. 2. 1.&ate &ocu*entation6 T/i$ o.tion al$o nee&$ a lot of re$ource$. 9 goo& a..roac/ woul& be to u.&ate &ocu*entation w/en t/e co&e i$ *o&ifie&. 4e,er%e engineering ,e2er$e engineering i$ t/e ne5t $te. in t/e .roce$$. ,e2er$e engineering for $oftware i$ a .roce$$ for anal(+ing a .rogra* in an effort to create a re.re$entation of t/e .rogra* at a /ig/er le2el of ab$traction t/an t/e $ource co&e. ,e2er$e engineering i$ t/e .roce$$ of &e$ign reco2er(. 9t t/i$ $tage% &ocu*entation of t/e o2erall functionalit( of t/e $($te* t/at i$ not t/ere i$ create&. T/e o2erall functionalit( of t/e entire $($te* *u$t be un&er$too& before *ore &etaile& anal($i$ can be carrie& out. ,e2er$e engineering acti2itie$ inclu&e6 ,e2er$e engineering to un&er$tan& .roce$$ing ,e2er$e engineering to un&er$tan& &ata F Internal &ata $tructure$ F 7ataba$e $tructure$ ,e2er$e engineering u$er interface$ 1rogra' 4e%tructuring 3rogra* i$ re$tructure& after t/e re2er$e engineering ./a$e. In t/i$ ca$e we *o&if( $ource co&e an& &ata in or&er to *a4e it a*enable to future c/ange$. T/i$ inclu&e$ co&e a$ well a$ &ata re$tructuring. Co&e re$tructuring re'uire$ re&e$ign wit/ $a*e function wit/ /ig/er 'ualit( t/an original .rogra* an& &ata re$tructuring in2ol2e$ re$tructuring t/e &ataba$e or t/e &ataba$e $c/e*a. It *a( al$o in2ol2e co&e re$tructuring.
140
VU
141
VU
Prototy#ing
Process #ecification
Process 4"aluation
9$ ob2iou$ fro* t/e &iagra*% it $tart$ wit/ t/e bu$ine$$ &efinition w/ere bu$ine$$ goal$ are i&entifie&. T/e 4e( &ri2er$ coul& be co$t re&uction% ti*e re&uction% 'ualit( i*.ro2e*ent% an& .er$onnel &e2elo.*ent an& e*.ower*ent. It *a( be &efine& at t/e bu$ine$$ le2el or for a $.ecific co*.onent of t/e bu$ine$$. T/e ne5t $te. i$ .roce$$ i&entification. 9t t/i$ ti*e .roce$$e$ t/at are critical to ac/ie2ing t/e goal$ are i&entifie& an& are ran4e& b( i*.ortance% an& nee& for c/ange. T/e $/ort li$te& .roce$$e$ are t/en e2aluate&. E5i$ting .roce$$ i$ anal(+e& an& *ea$ure& an& .roce$$ ta$4$ are i&entifie&. T/e co$t an& ti*e con$u*e& i$ *ea$ure& a$ well a$ t/e 'ualit( an& .erfor*ance .roble*$ are i&entifie&. T/en% .roce$$ $.ecification an& &e$ign i$ carrie& out. 1$e ca$e$ are .re.are& for eac/ .roce$$ to be re&e$igne& an& a new $et of ta$4$ are &e$igne& for t/e .roce$$e$ an& t/en t/e( are .rotot(.e&. 9 re&e$igne& bu$ine$$ .roce$$ *u$t be .rotot(.e& before it i$ full( integrate& into t/e bu$ine$$. )a$e& on t/e fee&bac4 t/e bu$ine$$ .roce$$ i$ refine&.
142
VU
143
VU
4efactoring<
!ere to Start=
T/e fir$t 'ue$tion t/at we /a2e to a$4 our$el2e$ i$6 /ow &o (ou i&entif( co&e t/at nee&$ to be refactore&L =owler et al /a$ &e2i$e& a /euri$tic ba$e& a..roac/ to t/i$ en& 4nown a$ D)a& S*ell$E in Co&e. T/e ./ilo$o./( i$ $i*.le6 &i# it stin's, change it() "ad S'ell% in Code T/e( /a2e i&entifie& *an( &ifferent t(.e$ of Dba& $*ell$E. T/e$e are briefl( &e$cribe& in t/e following .aragra./$6 7u.licate& Co&e F ba& becau$e if (ou *o&if( one in$tance of &u.licate& co&e but not t/e ot/er$% (ou H*a(J /a2e intro&uce& a bugR Long #et/o& F long *et/o&$ are *ore &ifficult to un&er$tan&C .erfor*ance concern$ wit/ re$.ect to lot$ of $/ort *et/o&$ are largel( ob$olete Large Cla$$ F Large cla$$e$ tr( to &o too *uc/% w/ic/ re&uce$ co/e$ion Long 3ara*eter Li$t F /ar& to un&er$tan&% can beco*e incon$i$tent 7i2ergent C/ange F 7eal$ wit/ co/e$ionC $(*.to*6 one t(.e of c/ange re'uire$ c/anging one $ub$et of *et/o&$C anot/er t(.e of c/ange re'uire$ c/anging anot/er $ub$et S/otgun Surger( F a c/ange re'uire$ lot$ of little c/ange$ in a lot of &ifferent cla$$e$ =eature En2( F 9 *et/o& re'uire$ lot$ of infor*ation fro* $o*e ot/er cla$$ H*o2e it clo$erRJ 7ata Clu*.$ F attribute$ t/at clu*. toget/er but are not .art of t/e $a*e cla$$ 3ri*iti2e Ab$e$$ion F c/aracteri+e& b( a reluctance to u$e cla$$e$ in$tea& of .ri*iti2e &ata t(.e$ Switc/ State*ent$ F Switc/ $tate*ent$ are often &u.licate& in co&eC t/e( can t(.icall( be re.lace& b( u$e of .ol(*or./i$* Hlet AA &o (our $election for (ouRJ 3arallel In/eritance >ierarc/ie$ F Si*ilar to S/otgun Surger(C eac/ ti*e I a&& a $ubcla$$ to one /ierarc/(% I nee& to &o it for all relate& /ierarc/ie$ La+( Cla$$ F 9 cla$$ t/at no longer D.a($ it$ wa(E. e.g. *a( be a cla$$ t/at wa$ &own$i+e& b( refactoring% or re.re$ente& .lanne& functionalit( t/at &i& not .an out S.eculati2e Generalit( F DA/ I t/in4 we nee& t/e abilit( to &o t/i$ 4in& of t/ing $o*e&a(E Te*.orar( =iel&
144
VU
9n attribute of an ob8ect i$ onl( $et in certain circu*$tance$C but an ob8ect $/oul& nee& all of it$ attribute$ #e$$age C/ain$ F a client a$4$ an ob8ect for anot/er ob8ect an& t/en a$4$ t/at ob8ect for anot/er ob8ect etc. )a& becau$e client &e.en&$ on t/e $tructure of t/e na2igation #i&&le #an F If a cla$$ i$ &elegating *ore t/an /alf of it$ re$.on$ibilitie$ to anot/er cla$$% &o (ou reall( nee& itL Ina..ro.riate Inti*ac( F 3air$ of cla$$e$ t/at 4now too *uc/ about eac/ ot/er:$ .ri2ate &etail$ 9lternati2e Cla$$e$ wit/ 7ifferent Interface$ F S(*.to*6 Two or *ore *et/o&$ &o t/e $a*e t/ing but /a2e &ifferent $ignature for w/at t/e( &o Inco*.lete Librar( Cla$$ F 9 fra*ewor4 cla$$ &oe$n:t &o e2er(t/ing (ou nee& 7ata Cla$$ F T/e$e are cla$$e$ t/at /a2e fiel&$% getting an& $etting *et/o&$ for t/e fiel&$% an& not/ing el$eC t/e( are &ata /ol&er$% but ob8ect$ $/oul& be about &ata 9N7 be/a2ior ,efu$e& )e'ue$t F 9 $ubcla$$ ignore$ *o$t of t/e functionalit( .ro2i&e& b( it$ $u.ercla$$ Co**ent$ HRJ F Co**ent$ are $o*eti*e$ u$e& to /i&e ba& co&e F Deco**ent$ often are u$e& a$ a &eo&orantE HRJ
"rea(ing a -et!od ;e /a2e alrea&( $een e5a*.le of &u.licate co&e. ;e now loo4 at anot/er $i*.le e5a*.le of long *et/o&. 9lt/oug/% in t/i$ ca$e% t/e co&e i$ not reall( long% it /owe2er &e*on$trate$ /ow longer $eg*ent$ of co&e can be bro4en into $*aller an& *ore *anageable H*a( be *ore reu$able a$ wellJ co&e $eg*ent$. T/e following co&e $eg*ent $ort$ an arra( of integer$ u$ing D$election $ortE algorit/*. for HiZ0C i ^ N-1C iPPJ c *in Z iC for H8 Z iC 8 ^ NC 8PPJ if Ha\8] ^ a\*in]J *in Z 8C te*. Z a\i]C a\i] Z a\*in]C a\*in] Z te*.C d
;e brea4 it into $*aller frag*ent$ b( *a4ing $*aller function$ out of &ifferent $te.$ in t/e algorit/* a$ follow$6
145
CS605 Software Engineering-II int *ini*u* Hint a\ ]% int fro*% int toJ c int *in Z fro*C for Hint i Z fro*C i ^Z toC iPPJ if Ha\i] ^ a\*in]J *in Z iC return *inC d 2oi& $wa. Hint f5% int f(J c int te*. Z 5C 5 Z (C ( Z te*.C d T/e $ort function now beco*e$ $i*.ler a$ $/own below. for HiZ0C i ^ N-1C iPPJ c *in Z *ini*u* Ha% i% N-1JC $wa.Ha\i]% a\*in]JC d
VU
It can be $een t/at it i$ now *uc/ ea$ier to un&er$tan& t/e co&e an& /ence i$ ea$ier to *aintain. 9t t/e $a*e ti*e we /a2e got two $e.arate reu$able function$ t/at can be u$e& el$ew/ere in t/e co&e. # %lig!tl2 'ore in,ol,ed e)a'*le 6It !a% 'o%tl2 been ada*ted fro' .owlerK% introduction to refactoring w!ic! i% freel2 a,ailable on t!e web7 Let u$ con$i&er a $i*.le .rogra* for a 2i&eo $tore. It /a$ t/ree cla$$e$6 #o2ie% ,ental% an& Cu$to*er. 3rogra* i$ tol& w/ic/ *o2ie$ a cu$to*er rente& an& for /ow long an& it t/en calculate$ t/e c/arge$ an& t/e =re'uent renter .oint$. Cu$to*er ob8ect can .rint a $tate*ent Hin 9SCIIJ. >ere i$ t/e co&e for t/e cla$$e$. 7o*ainAb8ect i$ a general cla$$ t/at &oe$ a few $tan&ar& t/ing$% $uc/ a$ /ol& a na*e. .ublic cla$$ 7o*ainAb8ect c .ublic 7o*ainAb8ect HString na*eJ c gna*e Z na*eC dC .ublic 7o*ainAb8ect HJ .ublic String na*e HJ return gna*eC dC cdC c
146
VU
.ublic String toStringHJ c return gna*eC dC .rotecte& String gna*e Z Yno na*eYC d #o2ie re.re$ent$ t/e notion of a fil*. 9 2i&eo $tore *ig/t /a2e $e2eral ta.e$ in $toc4 of t/e $a*e *o2ie .ublic cla$$ #o2ie e5ten&$ 7o*ainAb8ect c .ublic $tatic final int C>IL7,ENS Z 2C .ublic $tatic final int ,EG1L9, Z 0C .ublic $tatic final int NE;g,ELE9SE Z 1C .ri2ate int g.riceCo&eC .ublic #o2ieHString na*e% int .riceCo&eJ c gna*e Z na*eC g.riceCo&e Z .riceCo&eC d .ublic int .riceCo&eHJ c return g.riceCo&eC d .ublic 2oi& .er$i$tHJ c ,egi$trar.a&& HY#o2ie$Y% t/i$JC d .ublic $tatic #o2ie getHString na*eJ c return H#o2ieJ ,egi$trar.get HY#o2ie$Y% na*eJC d d T/e *o2ie u$e$ a cla$$ calle& a regi$trar Hnot $/ownJ a$ a cla$$ to /ol& in$tance$ of *o2ie. I al$o &o t/i$ wit/ ot/er cla$$e$. I u$e t/e *e$$age .er$i$t to tell an ob8ect to $a2e it$elf to t/e regi$trar. I can t/en retrie2e t/e ob8ect% ba$e& on it$ na*e% wit/ a getHStringJ *et/o&. T/e ta.e cla$$ re.re$ent$ a ./($ical ta.e. cla$$ Ta.e e5ten&$ 7o*ainAb8ect c .ublic #o2ie *o2ieHJ c return g*o2ieC d .ublic Ta.eHString $erialNu*ber% #o2ie *o2ieJ c
147
CS605 Software Engineering-II g$erialNu*ber Z $erialNu*berC g*o2ie Z *o2ieC d .ri2ate String g$erialNu*berC .ri2ate #o2ie g*o2ieC d T/e rental cla$$ re.re$ent$ a cu$to*er renting a *o2ie. cla$$ ,ental e5ten&$ 7o*ainAb8ect c .ublic int &a($,ente&HJ c return g&a($,ente&C d .ublic Ta.e ta.eHJ c return gta.eC d .ri2ate Ta.e gta.eC .ublic ,entalHTa.e ta.e% int &a($,ente&J c gta.e Z ta.eC g&a($,ente& Z &a($,ente&C d .ri2ate int g&a($,ente&C d
VU
T/e cu$to*er cla$$ re.re$ent$ t/e cu$to*er. So far all t/e cla$$e$ /a2e been &u*b enca.$ulate& &ata. Cu$to*er /ol&$ all t/e be/a2ior for .ro&ucing a $tate*ent in it$ $tate*entHJ *et/o&. cla$$ Cu$to*er e5ten&$ 7o*ainAb8ect c .ublic Cu$to*erHString na*eJ c gna*e Z na*eC d .ublic String $tate*entHJ c &ouble total9*ount Z 0C int fre'uent,enter3oint$ Z 0C Enu*eration rental$ Z grental$.ele*ent$HJC String re$ult Z Y,ental ,ecor& for Y P na*eHJ P YanYC w/ile Hrental$./a$#oreEle*ent$HJJ c &ouble t/i$9*ount Z 0C ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC OO&eter*ine a*ount$ for eac/ line $witc/ Heac/.ta.eHJ.*o2ieHJ..riceCo&eHJJ c ca$e #o2ie.,EG1L9,6 t/i$9*ount PZ 2C if Heac/.&a($,ente&HJ ` 2J t/i$9*ount PZ Heac/.&a($,ente&HJ - 2J T 1.5C brea4C
148
CS605 Software Engineering-II ca$e #o2ie.NE;g,ELE9SE6 t/i$9*ount PZ eac/.&a($,ente&HJ T 3C brea4C ca$e #o2ie.C>IL7,ENS6 t/i$9*ount PZ 1.5C if Heac/.&a($,ente&HJ ` 3J t/i$9*ount PZ Heac/.&a($,ente&HJ - 3J T 1.5C brea4C d total9*ount PZ t/i$9*ountC OO a&& fre'uent renter .oint$ fre'uent,enter3oint$ PPC OO a&& bonu$ for a two &a( new relea$e rental if HHeac/.ta.eHJ.*o2ieHJ..riceCo&eHJ ZZ #o2ie.NE;g,ELE9SEJ ff eac/.&a($,ente&HJ ` 1J fre'uent,enter3oint$ PPC
VU
OO$/ow figure$ for t/i$ rental re$ult PZ YatY P eac/.ta.eHJ.*o2ieHJ.na*eHJP YatY P String.2alueAfHt/i$9*ountJ P YanYC d OOa&& footer line$ re$ult PZ Y9*ount owe& i$ Y P String.2alueAfHtotal9*ountJ P YanYC re$ult PZ Y<ou earne& Y P String.2alueAfHfre'uent,enter3oint$J P Y fre'uent renter .oint$YC return re$ultC d .ublic 2oi& a&&,entalH,ental argJ c grental$.a&&Ele*entHargJC d .ublic $tatic Cu$to*er getHString na*eJ c return HCu$to*erJ ,egi$trar.getHYCu$to*er$Y% na*eJC d .ublic 2oi& .er$i$tHJ c ,egi$trar.a&&HYCu$to*er$Y% t/i$JC d .ri2ate 0ector grental$ Z new 0ectorHJC d ;/at are (our i*.re$$ion$ about t/e &e$ign of t/i$ .rogra*L I woul& &e$cribe a$ not well &e$igne&% an& certainl( not ob8ect-oriente&. =or a $i*.le .rogra* i$ t/i$% t/at &oe$ not reall( *atter. T/ereh$ not/ing wrong wit/ a 'uic4 an& &irt( simple .rogra*. )ut if we i*agine t/i$ a$ a frag*ent of a *ore co*.le5 $($te*% t/en I /a2e $o*e real .roble*$ wit/ t/i$ .rogra*. T/at long $tate*ent routine in t/e Cu$to*er &oe$ far too *uc/. #an( of t/e t/ing$ t/at it &oe$ $/oul& reall( be &one b( t/e ot/er cla$$e$.
149
VU
T/i$ i$ reall( broug/t out b( a new re'uire*ent% 8u$t in fro* t/e u$er$% t/e( want a $i*ilar $tate*ent in /t*l. 9$ (ou loo4 at t/e co&e (ou can $ee t/at it i$ i*.o$$ible to reu$e an( of t/e be/a2ior of t/e current $tate*entHJ *et/o& for an /t*lState*entHJ. <our onl( recour$e i$ to write a w/ole new *et/o& t/at &u.licate$ *uc/ of t/e be/a2ior of $tate*entHJ. Now of cour$e t/i$ i$ not too onerou$. <ou can 8u$t co.( t/e $tate*entHJ *et/o& an& *a4e w/ate2er c/ange$ (ou nee&. So t/e lac4 of &e$ign &oe$ not &o too *uc/ to /a*.er t/e writing of /t*lState*entHJ% Halt/oug/ it *ig/t be tric4( to figure out e5actl( w/ere to &o t/e c/ange$J. )ut w/at /a..en$ w/en t/e c/arging rule$ c/angeL <ou /a2e to fi5 bot/ $tate*entHJ an& /t*lState*entHJ% an& en$ure t/e fi5e$ are con$i$tent. T/e .roble* fro* cut an& .a$ting co&e co*e$ w/en (ou /a2e to c/ange it later. T/u$ if (ou are writing a .rogra* t/at (ou &onht e5.ect to c/ange% t/en cut an& .a$te i$ fine. If t/e .rogra* i$ long li2e& an& li4el( to c/ange% t/en cut an& .a$te i$ a *enace. )ut (ou $till /a2e to write t/e /t*lState*entHJ .rogra*. <ou *a( feel t/at (ou $/oul& not touc/ t/e e5i$ting $tate*entHJ *et/o&% after all it wor4$ fine. ,e*e*ber t/e ol& engineering a&age6 Yif it ainht bro4e% &onht fi5 itY. $tate*entHJ *a( not be bro4e% but it &oe$ /urt. It i$ *a4ing (our life *ore &ifficult to write t/e /t*lState*entHJ *et/o&. So t/i$ i$ w/ere refactoring co*e$ in. ;/en (ou fin& (ou /a2e to a&& a feature to a .rogra*% an& t/e .rogra*h$ co&e i$ not $tructure& in a con2enient wa( to a&& t/e featureC t/en fir$t refactor t/e .rogra* to *a4e it ea$( to a&& t/e feature% t/en a&& t/e feature. E)tracting t!e #'ount Calculation T/e ob2iou$ fir$t target of *( attention i$ t/e o2erl( long $tate*entHJ *et/o&. ;/en I loo4 at a long *et/o& li4e t/at% I a* loo4ing to ta4e a c/un4 of t/e co&e an extract a method fro* it. E5tracting a *et/o& i$ ta4ing t/e c/un4 of co&e an& *a4ing a *et/o& out of it. 9n ob2iou$ .iece /ere i$ t/e $witc/ $tate*ent Hw/ic/ IQ* /ig/lig/ting belowJ. .ublic String $tate*entHJ c &ouble total9*ount Z 0C int fre'uent,enter3oint$ Z 0C Enu*eration rental$ Z grental$.ele*ent$HJC String re$ult Z Y,ental ,ecor& for Y P na*eHJ P YanYC w/ile Hrental$./a$#oreEle*ent$HJJ c &ouble t/i$9*ount Z 0C ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC OO&eter*ine a*ount$ for eac/ line $witc/ Heac/.ta.eHJ.*o2ieHJ..riceCo&eHJJ c ca$e #o2ie.,EG1L9,6 t/i$9*ount PZ 2C if Heac/.&a($,ente&HJ ` 2J t/i$9*ount PZ Heac/.&a($,ente&HJ - 2J T 1.5C brea4C ca$e #o2ie.NE;g,ELE9SE6 t/i$9*ount PZ eac/.&a($,ente&HJ T 3C brea4C
150
CS605 Software Engineering-II ca$e #o2ie.C>IL7,ENS6 t/i$9*ount PZ 1.5C if Heac/.&a($,ente&HJ ` 3J t/i$9*ount PZ Heac/.&a($,ente&HJ - 3J T 1.5C brea4C d total9*ount PZ t/i$9*ountC OO a&& fre'uent renter .oint$ fre'uent,enter3oint$ PPC OO a&& bonu$ for a two &a( new relea$e rental if HHeac/.ta.eHJ.*o2ieHJ..riceCo&eHJ ZZ #o2ie.NE;g,ELE9SEJ ff eac/.&a($,ente&HJ ` 1J fre'uent,enter3oint$ PPC
VU
OO$/ow figure$ for t/i$ rental re$ult PZ YatY P eac/.ta.eHJ.*o2ieHJ.na*eHJP YatY P String.2alueAfHt/i$9*ountJ P YanYC d OOa&& footer line$ re$ult PZ Y9*ount owe& i$ Y P String.2alueAfHtotal9*ountJ P YanYC re$ult PZ Y<ou earne& Y P String.2alueAfHfre'uent,enter3oint$J P Y fre'uent renter .oint$YC return re$ultC d T/i$ loo4$ li4e it woul& *a4e a goo& c/un4 to e5tract into it$ own *et/o&. ;/en we e5tract a *et/o&% we nee& to loo4 in t/e frag*ent for an( 2ariable$ t/at are local in $co.e to t/e *et/o& we are loo4ing at% t/at local 2ariable$ an& .ara*eter$. T/i$ $eg*ent of co&e u$e$ two6 eac/ an& t/i$9*ount. Af t/e$e eac/ i$ not *o&ifie& b( t/e co&e but t/i$9*ount i$ *o&ifie&. 9n( non-*o&ifie& 2ariable we can .a$$ in a$ a .ara*eter. #o&ifie& 2ariable$ nee& *ore care. If t/ere i$ onl( one we can return it. T/e te*. i$ initiali+e& to 0 eac/ ti*e roun& t/e loo.% an& not altere& until t/e $witc/ get$ it$ /an&$ on it. So we can 8u$t a$$ign t/e re$ult. T/e e5traction loo4$ li4e t/i$. .ublic String $tate*entHJ c &ouble total9*ount Z 0C int fre'uent,enter3oint$ Z 0C Enu*eration rental$ Z grental$.ele*ent$HJC String re$ult Z Y,ental ,ecor& for Y P na*eHJ P YanYC w/ile Hrental$./a$#oreEle*ent$HJJ c &ouble t/i$9*ount Z 0C ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC OO&eter*ine a*ount$ for eac/ line t/i$9*ount Z a*ountAfHeac/JC total9*ount PZ t/i$9*ountC
151
CS605 Software Engineering-II OO a&& fre'uent renter .oint$ fre'uent,enter3oint$ PPC OO a&& bonu$ for a two &a( new relea$e rental if HHeac/.ta.eHJ.*o2ieHJ..riceCo&eHJ ZZ #o2ie.NE;g,ELE9SEJ ff eac/.&a($,ente&HJ ` 1J fre'uent,enter3oint$ PPC
VU
OO$/ow figure$ for t/i$ rental re$ult PZ YatY P eac/.ta.eHJ.*o2ieHJ.na*eHJP YatY P String.2alueAfHt/i$9*ountJ P YanYC d OOa&& footer line$ re$ult PZ Y9*ount owe& i$ Y P String.2alueAfHtotal9*ountJ P YanYC re$ult PZ Y<ou earne& Y P String.2alueAfHfre'uent,enter3oint$J P Y fre'uent renter .oint$YC return re$ultC d .ri2ate int a*ountAfH,ental eac/J c int t/i$9*ount Z 0C $witc/ Heac/.ta.eHJ.*o2ieHJ..riceCo&eHJJ c ca$e #o2ie.,EG1L9,6 t/i$9*ount PZ 2C if Heac/.&a($,ente&HJ ` 2J t/i$9*ount PZ Heac/.&a($,ente&HJ - 2J T 1.5C brea4C ca$e #o2ie.NE;g,ELE9SE6 t/i$9*ount PZ eac/.&a($,ente&HJ T 3C brea4C ca$e #o2ie.C>IL7,ENS6 t/i$9*ount PZ 1.5C if Heac/.&a($,ente&HJ ` 3J t/i$9*ount PZ Heac/.&a($,ente&HJ - 3J T 1.5C brea4C d return t/i$9*ountC d ;/en I &i& t/i$ t/e te$t$ blew u.. 9 cou.le of t/e te$t figure$ ga2e *e t/e wrong an$wer. I wa$ .u++le& for a few $econ&$ t/en reali+e& w/at I /a& &one. =ooli$/l( I /a& *a&e t/e return t(.e of a*ountAfHJ int in$tea& of &ouble. .ri2ate &ouble a*ountAfH,ental eac/J c &ouble t/i$9*ount Z 0C $witc/ Heac/.ta.eHJ.*o2ieHJ..riceCo&eHJJ c ca$e #o2ie.,EG1L9,6 t/i$9*ount PZ 2C if Heac/.&a($,ente&HJ ` 2J
152
CS605 Software Engineering-II t/i$9*ount PZ Heac/.&a($,ente&HJ - 2J T 1.5C brea4C ca$e #o2ie.NE;g,ELE9SE6 t/i$9*ount PZ eac/.&a($,ente&HJ T 3C brea4C ca$e #o2ie.C>IL7,ENS6 t/i$9*ount PZ 1.5C if Heac/.&a($,ente&HJ ` 3J t/i$9*ount PZ Heac/.&a($,ente&HJ - 3J T 1.5C brea4C d return t/i$9*ountC d
VU
Ith$ t/e 4in& of $ill( *i$ta4e t/at I often *a4e% an& it can be a .ain to trac4 &own a$ ?a2a con2ert$ int$ to &ouble$ wit/out co*.laining Hbut *erril( roun&ingJ. =ortunatel( it wa$ ea$( to fin& in t/i$ ca$e% becau$e t/e c/ange wa$ $o $*all. >ere i$ t/e e$$ence of t/e refactoring .roce$$ illu$trate& b( acci&ent. )ecau$e eac/ c/ange i$ $o $*all% an( error$ are 2er( ea$( to fin&. <ou &onQt $.en& long &ebugging% e2en if (ou are a$ carele$$ a$ I a*. T/i$ refactoring /a$ ta4en a large *et/o& an& bro4en it &own into two *uc/ *ore *anageable c/un4$. ;e can now con$i&er t/e c/un4$ a bit better. I &onQt li4e $o*e of t/e 2ariable$ na*e$ in a*ountAfHJ an& t/i$ i$ a goo& .lace to c/ange t/e*. .ri2ate &ouble a*ountAfH,ental a,entalJ c &ouble re$ult Z 0C $witc/ Ha,ental.ta.eHJ.*o2ieHJ..riceCo&eHJJ c ca$e #o2ie.,EG1L9,6 re$ult PZ 2C if Ha,ental.&a($,ente&HJ ` 2J re$ult PZ Ha,ental.&a($,ente&HJ - 2J T 1.5C brea4C ca$e #o2ie.NE;g,ELE9SE6 re$ult PZ a,ental.&a($,ente&HJ T 3C brea4C ca$e #o2ie.C>IL7,ENS6 re$ult PZ 1.5C if Ha,ental.&a($,ente&HJ ` 3J re$ult PZ Ha,ental.&a($,ente&HJ - 3J T 1.5C brea4C d return re$ultC d I$ t/at rena*ing wort/ t/e effortL 9b$olutel(. Goo& co&e $/oul& co**unicate w/at it i$ &oing clearl(% an& 2ariable na*e$ are 4e( to clear co&e. Ne2er be afrai& to c/ange t/e na*e$ to t/ing$ to i*.ro2e clarit(. ;it/ goo& fin& an& re.lace tool$% it i$ u$uall( not &ifficult. Strong t(.ing an& te$ting will /ig/lig/t an(t/ing (ou *i$$. ,e*e*ber an( fool
153
VU
can write co&e t/at a co*.uter can un&er$tan&% goo& .rogra**er$ write co&e t/at /u*an$ can un&er$tan&.
154
VU
OO&eter*ine a*ount$ for eac/ line t/i$9*ount Z eac/.c/argeHJC total9*ount PZ t/i$9*ountC OO a&& fre'uent renter .oint$ fre'uent,enter3oint$ PPC OO a&& bonu$ for a two &a( new relea$e rental if HHeac/.ta.eHJ.*o2ieHJ..riceCo&eHJ ZZ #o2ie.NE;g,ELE9SEJ ff eac/.&a($,ente&HJ ` 1J fre'uent,enter3oint$ PPC OO$/ow figure$ for t/i$ rental re$ult PZ YatY P eac/.ta.eHJ.*o2ieHJ.na*eHJP YatY P String.2alueAfHt/i$9*ountJ P YanYC d OOa&& footer line$ re$ult PZ Y9*ount owe& i$ Y P String.2alueAfHtotal9*ountJ P YanYC re$ult PZ Y<ou earne& Y P String.2alueAfHfre'uent,enter3oint$J P Y fre'uent renter .oint$YC return re$ultC d ;/en IQ2e *a&e t/e c/ange t/e ne5t t/ing i$ to re*o2e t/e ol& *et/o&. T/e co*.iler $/oul& t/en tell *e if I *i$$e& an(t/ing. T/ere i$ certainl( $o*e *ore I woul& li4e to &o to ,ental.c/argeHJ but I will lea2e it for t/e *o*ent an& return to Cu$to*er.$tate*entHJ. T/e ne5t t/ing t/at $tri4e$ *e i$ t/at t/i$9*ountHJ i$ now .rett( re&un&ant. It i$ $et to t/e re$ult of eac/.c/argeHJ an& not c/ange& afterwar&$. T/u$ I can eli*inate t/i$9*ount b( replacing a temp with a query. .ublic String $tate*entHJ c &ouble total9*ount Z 0C int fre'uent,enter3oint$ Z 0C Enu*eration rental$ Z grental$.ele*ent$HJC String re$ult Z Y,ental ,ecor& for Y P na*eHJ P YanYC w/ile Hrental$./a$#oreEle*ent$HJJ c ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC OO&eter*ine a*ount$ for eac/ line total9*ount PZ eac/.c/argeHJC OO a&& fre'uent renter .oint$ fre'uent,enter3oint$ PPC OO a&& bonu$ for a two &a( new relea$e rental if HHeac/.ta.eHJ.*o2ieHJ..riceCo&eHJ ZZ #o2ie.NE;g,ELE9SEJ ff eac/.&a($,ente&HJ ` 1J fre'uent,enter3oint$ PPC
155
VU
OO$/ow figure$ for t/i$ rental re$ult PZ YatY P eac/.ta.eHJ.*o2ieHJ.na*eHJP YatY P String.2alueAfHeac/.c/argeHJJ P YanYC d OOa&& footer line$ re$ult PZ Y9*ount owe& i$ Y P String.2alueAfHtotal9*ountJ P YanYC re$ult PZ Y<ou earne& Y P String.2alueAfHfre'uent,enter3oint$J P Y fre'uent renter .oint$YC return re$ultC d I li4e to get ri& of te*.orar( 2ariable$ li4e t/u$ a$ *uc/ a$ .o$$ible. Te*.$ are often a .roble* in t/at t/e( cau$e a lot of .ara*eter$ to get .a$$e& aroun& w/en t/e( &onQt nee& to. <ou can ea$il( lo$e trac4 of w/at t/e( are t/ere for. T/e( are .articularl( in$i&iou$ in long *et/o&$. Af cour$e t/ere i$ a $*all .erfor*ance .rice to .a(% /ere t/e c/arge i$ now calculate& twice. )ut it i$ ea$( to o.ti*i+e t/at in t/e rental cla$$% an& (ou can o.ti*i+e *uc/ *ore effecti2el( w/en t/e co&e i$ .ro.erl( refactore&. E)tracting .re&uent 4enter 1oint% T/e ne5t $te. i$ to &o a $i*ilar t/ing for t/e fre'uent renter .oint$. 9gain t/e rule$ 2ar( wit/ t/e ta.e% alt/oug/ t/ere i$ le$$ 2ariation t/an wit/ t/e c/arging. )ut it $ee*$ rea$onable to .ut t/e re$.on$ibilit( on t/e rental. =ir$t we nee& to e5tract a *et/o& fro* t/e fre'uent renter .oint$ .art of t/e co&e H/ig/lig/te& belowJ. .ublic String $tate*entHJ c &ouble total9*ount Z 0C int fre'uent,enter3oint$ Z 0C Enu*eration rental$ Z grental$.ele*ent$HJC String re$ult Z Y,ental ,ecor& for Y P na*eHJ P YanYC w/ile Hrental$./a$#oreEle*ent$HJJ c ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC OO&eter*ine a*ount$ for eac/ line total9*ount PZ eac/.c/argeHJC OO a&& fre'uent renter .oint$ fre'uent,enter3oint$ PPC OO a&& bonu$ for a two &a( new relea$e rental if HHeac/.ta.eHJ.*o2ieHJ..riceCo&eHJ ZZ #o2ie.NE;g,ELE9SEJ ff eac/.&a($,ente&HJ ` 1J fre'uent,enter3oint$ PPC OO$/ow figure$ for t/i$ rental re$ult PZ YatY P eac/.ta.eHJ.*o2ieHJ.na*eHJP YatY P String.2alueAfHeac/.c/argeHJJ P YanYC d
156
VU
OOa&& footer line$ re$ult PZ Y9*ount owe& i$ Y P String.2alueAfHtotal9*ountJ P YanYC re$ult PZ Y<ou earne& Y P String.2alueAfHfre'uent,enter3oint$J P Y fre'uent renter .oint$YC return re$ultC d 9gain we loo4 at t/e u$e of locall( $co.e& 2ariable$. 9gain it u$e$ eac/% w/ic/ can be .a$$e& in a$ a .ara*eter. T/e ot/er te*. u$e& i$ fre'uent,enter3oint$. In t/i$ ca$e fre'uent,enter3oint$ &oe$ /a2e a 2alue before/an&. T/e bo&( of t/e e5tracte& *et/o& &oe$nQt rea& t/e 2alue% /owe2er% $o we &onQt nee& to .a$$ it in a$ a .ara*eter a$ long a$ we u$e an a..en&ing a$$ign*ent. .ublic String $tate*entHJ c &ouble total9*ount Z 0C int fre'uent,enter3oint$ Z 0C Enu*eration rental$ Z grental$.ele*ent$HJC String re$ult Z Y,ental ,ecor& for Y P na*eHJ P YanYC w/ile Hrental$./a$#oreEle*ent$HJJ c ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC OO&eter*ine a*ount$ for eac/ line total9*ount PZ eac/.c/argeHJC OO a&& fre'uent renter .oint$ fre'uent,enter3oint$ PZ fre'uent,enter3ointAfHeac/JC OO$/ow figure$ for t/i$ rental re$ult PZ YatY P eac/.ta.eHJ.*o2ieHJ.na*eHJP YatY P String.2alueAfHeac/.c/argeHJJ P YanYC d OOa&& footer line$ re$ult PZ Y9*ount owe& i$ Y P String.2alueAfHtotal9*ountJ P YanYC re$ult PZ Y<ou earne& Y P String.2alueAfHfre'uent,enter3oint$J P Y fre'uent renter .oint$YC return re$ultC d int fre'uent,enter3ointAfH,ental eac/J c if HHeac/.ta.eHJ.*o2ieHJ..riceCo&eHJ ZZ #o2ie.NE;g,ELE9SEJ ff eac/.&a($,ente&HJ ` 1J return 2C el$e return 1C d I &i& t/e e5traction% co*.ile& an& te$te&% an& t/en &i& a *o2e. ;it/ refactoring $*all $te.$ are t/e be$t% t/at wa( le$$ ten&$ to go wrong.
157
CS605 Software Engineering-II .ublic String $tate*entHJ c &ouble total9*ount Z 0C int fre'uent,enter3oint$ Z 0C Enu*eration rental$ Z grental$.ele*ent$HJC String re$ult Z Y,ental ,ecor& for Y P na*eHJ P YanYC w/ile Hrental$./a$#oreEle*ent$HJJ c ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC OO&eter*ine a*ount$ for eac/ line total9*ount PZ eac/.c/argeHJC OO a&& fre'uent renter .oint$ fre'uent,enter3oint$ PZ eac/.fre'uent,enter3oint$HJC
VU
OO$/ow figure$ for t/i$ rental re$ult PZ YatY P eac/.ta.eHJ.*o2ieHJ.na*eHJP YatY P String.2alueAfHeac/.c/argeHJJ P YanYC d OOa&& footer line$ re$ult PZ Y9*ount owe& i$ Y P String.2alueAfHtotal9*ountJ P YanYC re$ult PZ Y<ou earne& Y P String.2alueAfHfre'uent,enter3oint$J P Y fre'uent renter .oint$YC return re$ultC d int fre'uent,enter3oint$HJ c if HHta.eHJ.*o2ieHJ..riceCo&eHJ ZZ #o2ie.NE;g,ELE9SEJ ff &a($,ente&HJ ` 1J return 2C el$e return 1C d 4e'o,ing Te'*% 9$ I $ugge$te& before% te*.orar( 2ariable$ can be a .roble*. T/e( are onl( u$eful wit/in t/eir own routine% an& t/u$ t/e( encourage long co*.le5 routine$. In t/i$ ca$e we /a2e two te*.orar( 2ariable$% bot/ of w/ic/ are being u$e& to get a total fro* t/e rental$ attac/e& to t/e cu$to*er. )ot/ t/e a$cii an& /t*l 2er$ion$ will re'uire t/e$e total$. I li4e to replace temps with queries. @uerie$ are acce$$ible to an( *et/o& in t/e cla$$% an& t/u$ encourage a cleaner &e$ign wit/out long co*.le5 *et/o&$. I began b( re.lacing total9*ount wit/ a c/argeHJ *et/o& on cu$to*er. .ublic String $tate*entHJ c &ouble total9*ount Z 0C int fre'uent,enter3oint$ Z 0C Enu*eration rental$ Z grental$.ele*ent$HJC String re$ult Z Y,ental ,ecor& for Y P na*eHJ P YanYC w/ile Hrental$./a$#oreEle*ent$HJJ c
158
CS605 Software Engineering-II ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC OO a&& fre'uent renter .oint$ fre'uent,enter3oint$ PZ eac/.fre'uent,enter3oint$HJC
VU
OO$/ow figure$ for t/i$ rental re$ult PZ YatY P eac/.ta.eHJ.*o2ieHJ.na*eHJP YatY P String.2alueAfHeac/.c/argeHJJ P YanYC d OOa&& footer line$ re$ult PZ Y9*ount owe& i$ Y P String.2alueAfHc/argeHJJ P YanYC re$ult PZ Y<ou earne& Y P String.2alueAfHfre'uent,enter3oint$J P Y fre'uent renter .oint$YC return re$ultC d .ri2ate &ouble c/argeHJc &ouble re$ult Z 0C Enu*eration rental$ Z grental$.ele*ent$HJC w/ile Hrental$./a$#oreEle*ent$HJJ c ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC re$ult PZ eac/.c/argeHJC d return re$ultC d 9fter co*.iling an& te$ting t/at refactoring% I t/en &i& t/e $a*e for fre'uent,enter3oint$. .ublic String $tate*entHJ c Enu*eration rental$ Z grental$.ele*ent$HJC String re$ult Z Y,ental ,ecor& for Y P na*eHJ P YanYC w/ile Hrental$./a$#oreEle*ent$HJJ c ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC OO$/ow figure$ for eac/ rental re$ult PZ YatY P eac/.ta.eHJ.*o2ieHJ.na*eHJP YatY P String.2alueAfHeac/.c/argeHJJ P YanYC d OOa&& footer line$ re$ult PZ Y9*ount owe& i$ Y P String.2alueAfHc/argeHJJ P YanYC re$ult PZ Y<ou earne& Y P String.2alueAfHfre'uent,enter3oint$HJJ P Y fre'uent renter .oint$YC return re$ultC d .ri2ate int fre'uent,enter3oint$HJ c int re$ult Z 0C Enu*eration rental$ Z grental$.ele*ent$HJC w/ile Hrental$./a$#oreEle*ent$HJJ c
159
CS605 Software Engineering-II ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC re$ult PZ eac/.fre'uent,enter3oint$HJC d return re$ultC d
VU
It i$ wort/ $to..ing an& t/in4ing a bit about t/i$ refactoring. #o$t refactoring re&uce t/e a*ount of co&e% but t/i$ one increa$e$ it. T/atQ$ becau$e ?a2a re'uire$ a lot of $tate*ent$ to $et u. a $u**ing loo.. E2en a $i*.le $u**ing loo. wit/ one line of co&e .er ele*ent nee&$ $i5 line$ of $u..ort aroun& it. Ith$ an i&io* t/at i$ ob2iou$ to an( .rogra**er but it i$ noi$e t/at /i&e$ w/at t/e intent of t/e loo. i$. 9$ ?a2a &e2elo.$ an& buil&$ u. it$ abilit( to /an&le bloc4 clo$ure$ in t/e $t(le of S*alltal4% I e5.ect t/at o2er/ea& to &ecrea$e% .robabl( to t/e $ingle line t/at $uc/ an e5.re$$ion woul& ta4e in S*alltal4. T/e ot/er concern wit/ t/i$ refactoring lie$ in .erfor*ance. T/e ol& co&e e5ecute& t/e w/ile loo. once% t/e new co&e e5ecute$ it t/ree ti*e$. If t/e w/ile loo. ta4e$ ti*e% t/i$ *ig/t $ignificantl( i*.air .erfor*ance. #an( .rogra**er$ woul& not &o t/i$ refactoring $i*.l( for t/i$ rea$on. )ut note t/e wor&$ YifY an& Y*ig/tY. ;/ile $o*e loo.$ &o cau$e .erfor*ance i$$ue$% *o$t &o not. So w/ile refactoring &onht worr( about t/i$. ;/en (ou o.ti*i+e (ou will /a2e to worr( about it% but (ou will t/en be in a *uc/ better .o$ition to &o $o*et/ing about it% an& (ou will /a2e *ore o.tion$ to o.ti*i+e effecti2el(. H=or a goo& &i$cu$$ion on w/( it i$ better to write clearl( fir$t an& t/en o.ti*i+e% $ee \#cConnell% Co&e Co*.lete]. T/e$e 'uerie$ are now a2ailable to an( co&e written in t/e cu$to*er cla$$. In&ee& t/e( can ea$il( be a&&e& to t/e interface of t/e cla$$ $/oul& ot/er .art$ of t/e $($te* nee& t/i$ infor*ation. ;it/out 'uerie$ li4e t/e$e% ot/er *et/o&$ nee& to &eal wit/ 4nowing about t/e rental$ an& buil&ing t/e loo.$. In a co*.le5 $($te* t/at will lea& to *uc/ *ore co&e to write an& *aintain. <ou can $ee t/e &ifference i**e&iatel( wit/ t/e /t*lState*entHJ. I a* now at t/e .oint w/ere I ta4e off *( refactoring /at an& .ut on *( a&&ing function /at. I can write /t*lState*entHJli4e t/i$ Han& a&& an a..ro.riate te$tJ. .ublic String /t*lState*entHJ c Enu*eration rental$ Z grental$.ele*ent$HJC String re$ult Z Y^>1`,ental$ for ^E#`Y P na*eHJ P Y^OE#`^O>1`^3`anYC w/ile Hrental$./a$#oreEle*ent$HJJ c ,ental eac/ Z H,entalJ rental$.ne5tEle*entHJC OO$/ow figure$ for eac/ rental re$ult PZ eac/.ta.eHJ.*o2ieHJ.na*eHJP Y6 Y P String.2alueAfHeac/.c/argeHJJ P Y^),`anYC d OOa&& footer line$ re$ult PZ Y^3`<ou owe ^E#`Y P String.2alueAfHc/argeHJJ P Y^OE#`^3`anYC re$ult PZ YAn t/i$ rental (ou earne& ^E#`Y P String.2alueAfHfre'uent,enter3oint$HJJ P Y^OE#` fre'uent renter .oint$^3`YC return re$ultC d
160
VU
T/ere i$ $till $o*e co&e co.ie& fro* t/e a$cii 2er$ion% but t/at i$ *ainl( &ue to $etting u. t/e loo.. =urt/er refactoring coul& clean t/at u. furt/er% e5tracting *et/o&$ for /ea&er% footer% an& &etail line are one route I coul& ta4e. )ut t/at i$nht w/ere I want to $.en& *( ti*e% I woul& li4e to *o2e onto t/e *et/o&$ Ih2e *o2e& onto rental. )ac4 on wit/ t/e refactoring /at. -o,ing t!e 4ental Calculation% to -o,ie <e$ ith$ t/at $witc/ $tate*ent t/at i$ bugging *e. It i$ a ba& i&ea to &o a $witc/ ba$e& on an attribute of anot/er ob8ect. If (ou *u$t u$e a $witc/ $tate*ent% it $/oul& be on (our own &ata% not on $o*eone el$eh$. T/i$ i*.lie$ t/at t/e c/arge $/oul& *o2e onto *o2ie Cla$$ *o2ie i &ouble c/argeHint &a($,ente&J c &ouble re$ult Z 0C $witc/ H.riceCo&eHJJ c ca$e ,EG1L9,6 re$ult PZ 2C if H&a($,ente& ` 2J re$ult PZ H&a($,ente& - 2J T 1.5C brea4C ca$e NE;g,ELE9SE6 re$ult PZ &a($,ente& T 3C brea4C ca$e C>IL7,ENS6 re$ult PZ 1.5C if H&a($,ente& ` 3J re$ult PZ H&a($,ente& - 3J T 1.5C brea4C d return re$ultC d =or t/i$ to wor4 I /a2e to .a$$ in t/e lengt/ of t/e rental% w/ic/ of cour$e i$ &ata &ue of t/e rental. T/e *et/o& effecti2el( u$e$ two .iece$ of &ata% t/e lengt/ of t/e rental an& t/e t(.e of t/e *o2ie. ;/( &o I .refer to .a$$ t/e lengt/ of rental rat/er t/an t/e *o2ieh$ t(.eL It$ becau$e t(.e infor*ation ten&$ to be *ore 2olatile. I can ea$il( i*agine new t(.e$ of 2i&eo$ a..earing. If I c/ange t/e *o2ieh$ t(.e I want t/e lea$t ri..le effect% $o I .refer to calculate t/e c/arge wit/in t/e *o2ie. I co*.ile& t/e *et/o& into *o2ie an& t/en a&8u$te& t/e c/arge *et/o& on rental to u$e t/e new *et/o&. Cla$$ rentali &ouble c/argeHJ c return gta.e.*o2ieHJ.c/argeHg&a($,ente&JC d
161
VU
So*e .eo.le woul& .refer to re*o2e t/at c/ain of call$ b( /a2ing a c/argeHintJ *e$$age on ta.e. T/i$ woul& lea& to Cla$$ rental &ouble c/argeHJ c return gta.e.c/argeHg&a($,ente&JC d Cla$$ ta.e &ouble c/argeHJ c return g*o2ie.c/argeHg&a($,ente&JC d <ou can *a4e t/at c/ange if (ou li4e% I &onht ten& to worr( about *e$$age c/ain$ .ro2i&ing t/at t/e( all lie in t/e $a*e .ac4age. If t/e( cro$$ .ac4age boun&arie$% t/en Ih* not $o /a..(% an& woul& a&& an in$ulating *et/o&. >a2ing &one t/i$ wit/ c/arge a*ount$% Ih* incline& to &o t/e $a*e wit/ fre'uent renter .oint$. T/e nee& i$ le$$ .re$$ing% but I t/in4 it i$ *ore con$i$tent to &o t/e* bot/ t/e $a*e wa(. 9n& again if t/e *o2ie cla$$ification$ c/ange it *a4e$ it ea$ier to u.&ate t/e co&e. Cla$$ rentali int fre'uent,enter3oint$HJ c return gta.e.*o2ieHJ.fre'uent,enter3oint$Hg&a($,ente&JC d cla$$ *o2iei int fre'uent,enter3oint$Hint &a($,ente&Jc if HH.riceCo&eHJ ZZ NE;g,ELE9SEJ ff &a($,ente& ` 1J return 2C el$e return 1C d ;it/ t/e$e two c/ange$ I can /i&e t/o$e con$tant$% w/ic/ i$ generall( a Goo& T/ing. E2en con$tant &ata $/oul& be .ri2ate. .ri2ate $tatic final int C>IL7,ENS Z 2C .ri2ate $tatic final int ,EG1L9, Z 0C .ri2ate $tatic final int NE;g,ELE9SE Z 1C To reall( &o t/i$% /owe2er% I nee& to c/ange a cou.le of ot/er .art$ of t/e cla$$. I nee& to c/ange /ow we create a *o2ie. I u$e& to create a *o2ie wit/ a *e$$age li4e new #o2ie HY,anY% #o2ie.,EG1L9,JC an& t/e con$tructor cla$$ #o2iei .ri2ate #o2ieHString na*e% int .riceCo&eJ c gna*e Z na*eC - Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
162
CS605 Software Engineering-II g.riceCo&e Z .riceCo&eC d To 4ee. t/i$ t(.e co&e /i&&en I nee& $o*e creation *et/o&$. .ublic $tatic #o2ie newNew,elea$eHString na*eJc return new #o2ie Hna*e% NE;g,ELE9SEJC d .ublic $tatic #o2ie new,egularHString na*eJc return new #o2ie Hna*e% ,EG1L9,JC d .ublic $tatic #o2ie newC/il&ren$HString na*eJ c return new #o2ie Hna*e% C>IL7,ENSJC d Now I create a new *o2ie wit/ #o2ie.new,egularHY#ont( 3(t/on an& t/e >ol( GrailYJC #o2ie$ can c/ange t/eir cla$$ification. I c/ange a *o2ieh$ cla$$ification wit/ a#o2ie.$et3riceCo&eH#o2ie.,EG1L9,JC I will nee& to a&& a bunc/ of *et/o&$ to /an&le t/e c/ange$ of cla$$ification. .ublic 2oi& be,egularHJ c g.riceCo&e Z ,EG1L9,C d .ublic 2oi& beNew,elea$eHJ c g.riceCo&e Z NE;g,ELE9SEC d .ublic 2oi& beC/il&ren$HJ c g.riceCo&e Z C>IL7,ENSC d
VU
Ith$ a bit of effort to $et u. t/e$e *et/o&$% but t/e( are a *uc/ *ore e5.licit interface t/en t/e t(.e co&e$. ?u$t loo4ing at t/e na*e of t/e *et/o& tell$ (ou w/at 4in& of *o2ie (ou are getting. T/i$ *a4e$ t/e co&e *ore un&er$tan&able. T/e tra&e off i$ t/at eac/ ti*e I a&& a .rice co&e I /a2e to a&& a creation an& u.&ate *et/o&. If I /a& lot$ of .rice co&e$ t/i$ woul& /urt H$o I woul&nht &o itJ. If I /a2e a few% /owe2er% t/en ith$ 'uite rea$onable. #t la%tL in!eritance So we /a2e $e2eral t(.e$ of *o2ie% w/ic/ /a2e &ifferent wa($ of an$wering t/e $a*e 'ue$tion. T/i$ $oun&$ li4e a 8ob for $ubcla$$e$. ;e coul& /a2e t/ree $ubcla$$e$ of *o2ie% eac/ of w/ic/ can /a2e it$ own 2er$ion of c/arge.
163
VU
T/i$ woul& allow *e to re.lace t/e $witc/ $tate*ent b( u$ing .ol(*or./i$*. Sa&l( it /a$ one $lig/t flaw6 it &oe$nht wor4. 9 *o2e can c/ange it$ cla$$ification &uring it$ lifeti*e. 9n ob8ect cannot c/ange it$ cla$$ &uring it$ lifeti*e. T/ere i$ a $olution /owe2er% t/e state pattern \Gang of =our]. ;it/ t/e $tate .attern t/e cla$$e$ loo4 li4e t/i$.
)( a&&ing t/e in&irection we can &o t/e $ubcla$$ing fro* t/e .rice co&e ob8ect% c/anging t/e .rice w/ene2er we nee& to. ;it/ a co*.le5 cla$$ (ou /a2e to *o2e &ata an& *et/o&$ aroun& in $*all .iece$ to a2oi& error$% it $ee*$ $low but it i$ t/e 'uic4e$t becau$e (ou a2oi& &ebugging. =or t/i$ ca$e I coul& .robabl( *o2e t/e &ata an& *et/o&$ in one go a$ t/e w/ole t/ing i$ not too co*.licate&. >owe2er Ihll &o it t/e bit b( bit wa(% $o (ou can $ee /ow it goe$. ?u$t re*e*ber to &o it one $*all bit at a ti*e if (ou &o t/i$ to a co*.licate& cla$$. T/e fir$t $te. i$ to create t/e new cla$$e$. T/en I nee& to $ort out /ow t/e( are *anage&. 9$ t/e &iagra* $/ow$ t/e( are all $ingleton$. It $ee*$ $en$ible to get /ol& of t/e* 2ia t/e $u.ercla$$ wit/ a *et/o& li4e 3rice.regularHJ. I can &o t/i$ b( getting t/e $u.ercla$$ to *anage t/e in$tance$ of t/e $ubcla$$e$. ab$tract cla$$ 3rice c $tatic 3rice regularHJ c return gregularC d $tatic 3rice c/il&ren$HJ c return gc/il&ren$C d $tatic 3rice new,elea$eHJ c return gnew,elea$eC d .ri2ate $tatic 3rice gc/il&ren$ Z new C/il&ren$3riceHJC .ri2ate $tatic 3rice gnew,elea$e Z new New,elea$e3riceHJC .ri2ate $tatic 3rice gregular Z new ,egular3riceHJC d Now I can begin to *o2e t/e &ata o2er. T/e fir$t .iece of &ata to *o2e o2er i$ t/e .rice co&e. Af cour$e Ih* not actuall( going to u$e t/e .rice co&e wit/in t/e 3rice ob8ect% but I will gi2e it t/e illu$ion of &oing $o. T/at wa( t/e ol& *et/o&$ will $till wor4. T/e( 4e( i$ to *o&if( t/o$e *et/o&$ t/at acce$$ an& u.&ate t/e .rice co&e 2alue wit/in #o2ie. #( fir$t $te. i$ to self#encapsulate the type code% en$uring t/at all u$e$ of t/e t(.e co&e go t/oug/ getting an& $etting *et/o&$. Since *o$t of t/e co&e ca*e fro* ot/er cla$$e$% *o$t *et/o&$ alrea&( u$e t/e getting *et/o&. >owe2er t/e con$tructor$ &o acce$$ t/e .rice co&e% I can u$e t/e $etting *et/o&$ in$tea&. .ublic $tatic #o2ie newNew,elea$eHString na*eJc - Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
164
CS605 Software Engineering-II #o2ie re$ult Z new #o2ie Hna*eJC re$ult.beNew,elea$eHJC return re$ultC d .ublic $tatic #o2ie new,egularHString na*eJc #o2ie re$ult Z new #o2ie Hna*eJC re$ult.be,egularHJC return re$ultC d .ublic $tatic #o2ie newC/il&ren$HString na*eJ c #o2ie re$ult Z new #o2ie Hna*eJC re$ult.beC/il&ren$HJC return re$ultC d .ri2ate #o2ieHString na*eJ c gna*e Z na*eC d
VU
9fter co*.iling an& te$ting I now c/ange getting an& $etting *et/o&$ to u$e t/e new cla$$. .ublic 2oi& be,egularHJ c g.rice Z 3rice.regularHJC d .ublic 2oi& beNew,elea$eHJ c g.rice Z 3rice.new,elea$eHJC d .ublic 2oi& beC/il&ren$HJ c g.rice Z 3rice.c/il&ren$HJC d .ublic int .riceCo&eHJ c return g.rice..riceCo&eHJC d 9n& .ro2i&e t/e .riceCo&e *et/o&$ on 3rice an& it$ $ubcla$$e$. Cla$$ 3ricei ab$tract int .riceCo&eHJC Cla$$ ,egular3ricei int .riceCo&eHJc return #o2ie.,EG1L9,C d To &o t/i$ I nee& to *a4e t/e con$tant$ non-.ri2ate again. T/i$ i$ fine% I &onht *in& t/e* /a2ing a little fa*e before t/e( bite t/e &u$t.
165
VU
I can now co*.ile an& te$t an& t/e *ore co*.le5 *et/o&$ &onht reali+e t/e worl& /a$ c/ange&. 9fter *o2ing t/e &ata I can now $tart *o2ing *et/o&$. #( .ri*e target i$ t/e c/argeHJ *et/o&. It i$ $i*.le to *o2e. Cla$$ #o2iei &ouble c/argeHint &a($,ente&J c return g.rice.c/argeH&a($,ente&JC d Cla$$ 3ricei &ouble c/argeHint &a($,ente&J c &ouble re$ult Z 0C $witc/ H.riceCo&eHJJ c ca$e #o2ie.,EG1L9,6 re$ult PZ 2C if H&a($,ente& ` 2J re$ult PZ H&a($,ente& - 2J T 1.5C brea4C ca$e #o2ie.NE;g,ELE9SE6 re$ult PZ &a($,ente& T 3C brea4C ca$e #o2ie.C>IL7,ENS6 re$ult PZ 1.5C if H&a($,ente& ` 3J re$ult PZ H&a($,ente& - 3J T 1.5C brea4C d return re$ultC d Ance it i$ *o2e& I can $tart replacing the case statement with inheritance. I &o t/i$ b( ta4ing one leg of t/e ca$e $tate*ent at a ti*e% an& creating an o2erri&ing *et/o&. I $tart wit/ ,egular3rice. Cla$$ ,egular3ricei &ouble c/argeHint &a($,ente&Jc &ouble re$ult Z 2C if H&a($,ente& ` 2J re$ult PZ H&a($,ente& - 2J T 1.5C return re$ultC d T/i$ will o2erri&e t/e .arent ca$e $tate*ent% w/ic/ I 8u$t lea2e a$ it i$. I co*.ile an& te$t for t/i$ ca$e% t/en ta4e t/e ne5t leg% co*.ile an& te$ti. HTo *a4e $ure Ih* e5ecuting t/e $ubcla$$ co&e% I li4e to t/row in a &eliberate bug an& run it to en$ure t/e te$t$ blow u.. Not t/at Ih* .aranoi& or an(t/ing.J
166
CS605 Software Engineering-II Cla$$ C/il&ren$3rice &ouble c/argeHint &a($,ente&Jc &ouble re$ult Z 1.5C if H&a($,ente& ` 3J re$ult PZ H&a($,ente& - 3J T 1.5C return re$ultC d Cla$$ New,elea$e3ricei &ouble c/argeHint &a($,ente&Jc return &a($,ente& T 3C d
VU
;/en Ih2e &one t/at wit/ all t/e leg$% I &eclare t/e 3rice.c/argeHJ *et/o& ab$tract. Cla$$ 3ricei ab$tract &ouble c/argeHint &a($,ente&JC I can now &o t/e $a*e .roce&ure wit/ fre'uent,enter3oint$HJ. =ir$t I *o2e t/e *et/o& o2er to 3rice. Cla$$ #o2iei int fre'uent,enter3oint$Hint &a($,ente&Jc return g.rice.fre'uent,enter3oint$H&a($,ente&JC d Cla$$ 3ricei int fre'uent,enter3oint$Hint &a($,ente&Jc if HH.riceCo&eHJ ZZ #o2ie.NE;g,ELE9SEJ ff &a($,ente& ` 1J return 2C el$e return 1C d In t/i$ ca$e% /owe2er I wonht *a4e t/e $u.ercla$$ *et/o& ab$tract. In$tea& I will create an o2erri&ing *et/o& for new relea$e$% an& lea2e a &efine& *et/o& Ha$ t/e &efaultJ on t/e $u.ercla$$. Cla$$ New,elea$e3rice int fre'uent,enter3oint$Hint &a($,ente&Jc return H&a($,ente& ` 1J L 26 1C d Cla$$ 3ricei int fre'uent,enter3oint$Hint &a($,ente&Jc return 1C d Now I /a2e re*o2e& all t/e *et/o&$ t/at nee&e& a .rice co&e. So I can get ri& of t/e .rice co&e *et/o&$ an& &ata on bot/ #o2ie an& 3rice.
167
VU
3utting in t/e $tate .attern wa$ 'uite an effort% wa$ it wort/ itL T/e gain i$ now t/at $/oul& I c/ange an( of .riceh$ be/a2ior% a&& new .rice$% or a&& e5tra .rice &e.en&ent be/a2iorC it will be *uc/ ea$ier to c/ange. T/e re$t of t/e a..lication &oe$ not 4now about t/e u$e of t/e $tate .attern. =or t/e tin( a*ount of be/a2ior I currentl( /a2e it i$ not a big &eal. )ut in a *ore co*.le5 $($te* wit/ a &o+en or $o .rice &e.en&ent *et/o&$ t/i$ woul& *a4e a big &ifference. 9ll t/e$e c/ange$ were $*all $te.$% it $ee*$ $low to write it li4e t/i$% but not once &i& I /a2e to o.en t/e &ebugger. So t/e .roce$$ actuall( flowe& 'uite 'uic4l(.
168
VU
Since t/e$e *o&el$ /a2e &ifferent $tructure an& a..lication &o*ain$% an organi+ation coul& .otentiall( u$e *an( of t/e$e *o&el$ for t/eir &ifferent acti2itie$% at ti*e$ it coul& beco*e .roble*atic for t/e*. C##I Integrate$ $($te*$ an& $oftware &i$ci.line$ into $ingle .roce$$ i*.ro2e*ent fra*ewor4 an& .ro2i&e$ a fra*ewor4 for intro&ucing new &i$ci.line$ a$ nee&$ ari$e. It can now be a..lie& to 8u$t t/e $oftware engineering .ro8ect$ in an organi+ation or for t/e entire $.ectru* of acti2itie$ outline& abo2e. C--I 4e*re%entation% 9 re.re$entation allow$ an organi+ation to .ur$ue &ifferent i*.ro2e*ent ob8ecti2e$. T/ere are two t(.e$ of re.re$entation$ in t/e C##I *o&el$6 $tage& an& continuou$. T/e organi+ation an& .re$entation of t/e &ata are &ifferent in eac/ re.re$entation. >owe2er% t/e content i$ t/e $a*e. Staged 4e*re%entation Stage& re.re$entation i$ cla$$ical re.re$entation we /a2e alrea&( $een .re2iou$l(. It6 3ro2i&e$ a .ro2en $e'uence of i*.ro2e*ent$% eac/ $er2ing a$ a foun&ation for t/e ne5t. 3er*it$ co*.ari$on$ acro$$ an& a*ong organi+ation$ b( t/e u$e of *aturit( le2el$. - Co.( ,ig/t 0irtual 1ni2er$it( of 3a4i$tan
169
VU
3ro2i&e$ an ea$( *igration fro* t/e S;-C## to C##I. 3ro2i&e$ a $ingle rating t/at $u**ari+e$ a..rai$al re$ult$ an& allow$ co*.ari$on$ a*ong organi+ation$ T/i$ re.re$entation in&icate$ *aturit( of an organi+ation:$ $tan&ar& .roce$$ -- to an$wer% D;/at i$ a goo& or&er for a..roac/ing i*.ro2e*ent acro$$ t/e organi+ationLE <ou *a( recall t/at a *aturit( le2el i$ a well-&efine& e2olutionar( .lateau of .roce$$ i*.ro2e*ent. T/ere are fi2e *aturit( le2el$ an& eac/ le2el i$ a la(er in t/e foun&ation for continuou$ .roce$$ i*.ro2e*ent u$ing a .ro2en $e'uence of i*.ro2e*ent$% beginning wit/ ba$ic *anage*ent .ractice$ an& .rogre$$ing t/roug/ a .re&efine& an& .ro2en .at/ of $ucce$$i2e le2el$. Eac/ *aturit( le2el .ro2i&e$ a nece$$ar( foun&ation for effecti2e i*.le*entation of .roce$$e$ at t/e ne5t le2el. >ig/er le2el .roce$$e$ /a2e le$$ c/ance of $ucce$$ wit/out t/e &i$ci.line .ro2i&e& b( lower le2el$. T/e effect of inno2ation can be ob$cure& in a noi$( .roce$$. >ig/er *aturit( le2el .roce$$e$ *a( be .erfor*e& b( organi+ation$ at lower *aturit( le2el$% wit/ t/e ri$4 of not being con$i$tentl( a..lie& in a cri$i$. Continuou% 4e*re%entation Continuou$ re.re$entation allow$ (ou to $elect t/e or&er of i*.ro2e*ent t/at be$t *eet$ (our organi+ation:$ bu$ine$$ ob8ecti2e$ an& *itigate$ (our organi+ation:$ area$ of ri$4. It enable$ co*.ari$on$ acro$$ an& a*ong organi+ation$ on a .roce$$-area-b(-.roce$$-area ba$i$ an& .ro2i&e$ an ea$( *igration fro* EI9 !31 Han& ot/er *o&el$ wit/ a continuou$ re.re$entationJ to C##I. 9$ o..o$e& to t/e $tage& re.re$entation% it in&icate$ i*.ro2e*ent wit/in a $ingle .roce$$ area -- to an$wer% D;/at i$ a goo& or&er for a..roac/ing i*.ro2e*ent of t/i$ .roce$$ areaLE Ca*abilit2 Le,el% 9 ca.abilit( le2el i$ a well-&efine& e2olutionar( .lateau &e$cribing t/e organi+ation:$ ca.abilit( relati2e to a .roce$$ area. T/ere are $i5 ca.abilit( le2el$. =or ca.abilit( le2el$ 1-5% t/ere i$ an a$$ociate& generic goal. Eac/ le2el i$ a la(er in t/e foun&ation for continuou$ .roce$$ i*.ro2e*ent. T/u$% ca.abilit( le2el$ are cu*ulati2e% i.e.% a /ig/er ca.abilit( le2el inclu&e$ t/e attribute$ of t/e lower le2el$. T/e fi2e Hactuall( $i5J ca.abilit( le2el$ H$tarting fro* 0J are enu*erate& below in t/e re2er$e or&er% 5 being t/e /ig/e$t an& 0 being t/e lowe$t. 5 4 3 2 1 0 A.ti*i+ing @uantitati2el( #anage& 7efine& #anage& 3erfor*e& Inco*.lete
170
VU
T/e .roce$$ area ca.abilit( of an i*.le*ente& .roce$$ can be re.re$ente& b( a bar a$ $/own below.
Capabilit! Level
3 2 1 $
T2is point represents a 2ig2er level of 8maturit!9 t2an t2is point in a specific process area
7rocess "rea n
7rocess
4elating 1roce%% #rea Ca*abilit2 and /rgani8ational -aturit2 Argani+ational *aturit( i$ t/e focu$ of t/e $tage& re.re$entation% w/erea$ .roce$$ area ca.abilit( i$ t/e focu$ of t/e continuou$ re.re$entation. Argani+ational *aturit( an& .roce$$ area ca.abilit( are $i*ilar conce.t$. T/e &ifference between t/e* i$ t/at organi+ational *aturit( .ertain$ to a $et of .roce$$ area$ acro$$ an organi+ation% w/ile .roce$$ area ca.abilit( &eal$ wit/ a $et of .roce$$e$ relating to a $ingle .roce$$ area or $.ecific .ractice. Co'*ari%on of 4e*re%entation% Stage& 3roce$$ i*.ro2e*ent i$ *ea$ure& u$ing *aturit( le2el$. #aturit( le2el i$ t/e &egree of .roce$$ i*.ro2e*ent acro$$ a .re&efine& $et of .roce$$ area$. Argani+ational *aturit( .ertain$ to t/e D*aturit(E of a $et of .roce$$e$ acro$$ an organi+ation
Continuou$ 3roce$$ i*.ro2e*ent i$ *ea$ure& u$ing ca.abilit( le2el$. Ca.abilit( le2el i$ t/e ac/ie2e*ent of .roce$$ i*.ro2e*ent wit/in an in&i2i&ual .roce$$ area. 3roce$$ area ca.abilit( .ertain$ to t/e D*aturit(E of a .articular .roce$$ acro$$ an organi+ation.
171
VU
Stage& .ro2i&e$ a roa&*a. for i*.le*enting grou.$ of .roce$$ area$ an& $e'uencing of i*.le*entation. It /a$ a fa*iliar $tructure for t/o$e tran$itioning fro* t/e Software C##. Continuou$ .ro2i&e$ *a5i*u* fle5ibilit( for focu$ing on $.ecific .roce$$ area$ accor&ing to bu$ine$$ goal$ an& ob8ecti2e$ an& /a$ a fa*iliar $tructure for t/o$e tran$itioning fro* EI9 !31. 9$ t/e $tage& re.re$entation re'uire$ all I39$ to be a&&re$$e& at a .articular le2el before a co*.an( can *o2e to t/e ne5t *aturit( le2el% it *a( not be ea$( for $*all co*.anie$ to i*.le*ent t/i$ *o&el. T/ere *a( be a nu*ber of acti2itie$ t/at *a( not be rele2ant to t/eir t(.e of wor4 but t/e( woul& $till /a2e to &o t/e* in or&er to be at a certain le2el. An t/e ot/er /an&% organi+ation can focu$ on t/eir own area$ of e5.erti$e an& *a( be able to ac/ie2e /ig/ ca.abilit( le2el$ in $o*e area$ wit/out bot/ering about t/e re$t. T/i$ i$ a great a&2antage for $*all organi+ation an& /ence t/i$ *o&el i$ belie2e& to be *ore $uitable for $*all 3a4i$tani organi+ation$ t/an t/e $tage& one.
172
VU
173
VU
iJ 3roce$$e$ an& t/eir out.ut$ coul& be 2i$ible to *anage*ent at &efine& .oint$% but re$ult$ *a( not alwa($ be con$i$tent. =or e5a*.le% for .ro8ectO.rogra* *anage*ent .roce$$e$% e2en t/oug/ H$a(J $o*e ba$ic .roce$$e$ are e$tabli$/e& to trac4 co$t% $c/e&ule% an& functionalit(% an& if a &egree of .roce$$ &i$ci.line i$ in .lace to re.eat earlier $ucce$$e$ on .ro8ect$ wit/ $i*ilar a..lication$ an& $co.e% t/ere coul& $till be a $ignificant ri$4 of e5cee&ing co$t an& ti*e e$ti*ate$. Le,el 3 - +efined It i$ c/aracteri$tic of .roce$$e$ at t/i$ le2el t/at t/ere are $et$ of &efine& an& &ocu*ente& $tan&ar& .roce$$e$ e$tabli$/e& an& $ub8ect to $o*e &egree of i*.ro2e*ent o2er ti*e. T/e$e $tan&ar& .roce$$e$ are in .lace Hi.e.% t/e( are t/e 9S-IS .roce$$e$J an& u$e& to e$tabli$/ con$i$tenc( of .roce$$ .erfor*ance acro$$ t/e organi+ation. /rgani8ational i'*lication% HaJ 3roce$$ *anage*ent $tart$ to occur u$ing &efine& &ocu*ente& .roce$$e$% wit/ *an&ator( .roce$$ ob8ecti2e$% an& en$ure$ t/at t/e$e ob8ecti2e$ are a..ro.riatel( a&&re$$e&. Le,el 5 - -anaged It i$ c/aracteri$tic of .roce$$e$ at t/i$ le2el t/at% u$ing .roce$$ *etric$% *anage*ent can effecti2el( control t/e 9S-IS .roce$$ He.g.% for $oftware &e2elo.*ent J. In .articular% *anage*ent can i&entif( wa($ to a&8u$t an& a&a.t t/e .roce$$ to .articular .ro8ect$ wit/out *ea$urable lo$$e$ of 'ualit( or &e2iation$ fro* $.ecification$. 3roce$$ Ca.abilit( i$ e$tabli$/e& fro* t/i$ le2el. /rgani8ational i'*lication% aJ @uantitati2e 'ualit( goal$ ten& to be $et for .roce$$ out.ut - e.g.% $oftware or $oftware *aintenance. bJ 1$ing 'uantitati2eO$tati$tical tec/ni'ue$% .roce$$ .erfor*ance i$ *ea$ure& an& *onitore& an& generall( .re&ictable an& controllable al$o. Le,el 5 - /*ti'i8ing It i$ a c/aracteri$tic of .roce$$e$ at t/i$ le2el t/at t/e focu$ i$ on continuall( i*.ro2ing .roce$$ .erfor*ance t/roug/ bot/ incre*ental an& inno2ati2e tec/nological c/ange$Oi*.ro2e*ent$. /rgani8ational i'*lication% HaJ @uantitati2e .roce$$-i*.ro2e*ent ob8ecti2e$ for t/e organi+ation are e$tabli$/e&% continuall( re2i$e& to reflect c/anging bu$ine$$ ob8ecti2e$% an& u$e& a$ criteria in *anaging .roce$$ i*.ro2e*ent. T/u$% .roce$$ i*.ro2e*ent$ to a&&re$$ co**on cau$e$ of .roce$$ 2ariation an& *ea$urabl( i*.ro2e t/e organi+ation:$ .roce$$e$ are i&entifie&% e2aluate&% an& &e.lo(e&.
174
VU
HbJ T/e effect$ of &e.lo(e& .roce$$ i*.ro2e*ent$ are *ea$ure& an& e2aluate& again$t t/e 'uantitati2e .roce$$-i*.ro2e*ent ob8ecti2e$. HcJ )ot/ t/e &efine& .roce$$e$ an& t/e organi+ation:$ $et of $tan&ar& .roce$$e$ are target$ for *ea$urable i*.ro2e*ent acti2itie$. H&J 9 critical &i$tinction between *aturit( le2el 4 an& *aturit( le2el 5 i$ t/e t(.e of .roce$$ 2ariation a&&re$$e&. 9t *aturit( le2el 4% .roce$$e$ are concerne& wit/ a&&re$$ing $tati$tical special causes of .roce$$ 2ariation an& .ro2i&ing $tati$tical .re&ictabilit( of t/e re$ult$% an& t/oug/ .roce$$e$ *a( .ro&uce .re&ictable re$ult$% t/e re$ult$ *a( be in$ufficient to ac/ie2e t/e e$tabli$/e& ob8ecti2e$. 9t *aturit( le2el 5% .roce$$e$ are concerne& wit/ a&&re$$ing $tati$tical common causes of .roce$$ 2ariation an& c/anging t/e .roce$$ Hfor e5a*.le% $/ifting t/e *ean of t/e .roce$$ .erfor*anceJ to i*.ro2e .roce$$ .erfor*ance. T/i$ woul& be &one at t/e $a*e ti*e a$ *aintaining t/e li4eli/oo& of ac/ie2ing t/e e$tabli$/e& 'uantitati2e .roce$$-i*.ro2e*ent ob8ecti2e$. E)ten%ion% So*e 2er$ion$ of C##I fro* SEI in&icate a Yle2el 0Y% c/aracteri+e& a$ YInco*.leteY. So*e .un&it$ lea2e t/i$ le2el out a$ re&un&ant or uni*.ortant% but 3re$$*an an& ot/er$ *a4e note of it. Co'*ari%on of C--I 4e*re%entation% Staged Continuou% ;/at i$ a C##I *o&el re.re$entationL T/e an$wer re'uire$ an e5.lanation of t/e $tructure of C##I *o&el$. T/e ba$ic buil&ing bloc4$ in e2er( C##I *o&el are calle& Y.roce$$ area$.Y 9 .roce$$ area &oe$ not &e$cribe how an effecti2e .roce$$ i$ e5ecute& He.g.% entrance an& e5it criteria% role$ of .artici.ant$% re$ource$J. In$tea&% a .roce$$ area &e$cribe$ what t/o$e u$ing an effecti2e .roce$$ &o H.ractice$J an& why t/e( &o t/o$e t/ing$ Hgoal$J. Selecting a 4e*re%entation ;/en *a4ing t/e &eci$ion about w/ic/ arc/itectural re.re$entation to u$e for .roce$$ i*.ro2e*ent% co*.arati2e a&2antage$ of eac/ a..roac/ a$ re.re$ente& in t/e gi2en Table. Continuou% 4e*re%entation Staged 4e*re%entation
Grant$ e5.licit free&o* to $elect t/e or&er Enable$ organi+ation$ to /a2e a .re&efine& of i*.ro2e*ent t/at be$t *eet$ t/e an& .ro2en .at/. organi+ationQ$ bu$ine$$ ob8ecti2e$. )uil&$ on a relati2el( long /i$tor( of u$e. Enable$ increa$e& 2i$ibilit( into t/e ca.abilit( ac/ie2e& wit/in eac/ in&i2i&ual Ca$e $tu&ie$ an& &ata e5i$t t/at $/ow return .roce$$ area. on in2e$t*ent. Su..ort$ a focu$ on ri$4$ $.ecific to 3er*it$ co*.ari$on$ acro$$ an& a*ong
175
VU
in&i2i&ual .roce$$ area$. 9ffor&$ a *ore &irect co*.ari$on of .roce$$ i*.ro2e*ent to ISA 15504 becau$e t/e organi+ation of .roce$$ area$ i$ &eri2e& fro* 15504.
organi+ation$. Intro&uce$ a $e'uence of i*.ro2e*ent$% beginning wit/ ba$ic *anage*ent .ractice$ an& .rogre$$ing t/roug/ $ucce$$i2e le2el$% eac/ $er2ing a$ a foun&ation for t/e ne5t.
9llow$ t/e generic .ractice$ fro* /ig/er Su**ari+e$ .roce$$-i*.ro2e*ent re$ult$ in ca.abilit( le2el$ to be *ore e2enl( an& a $i*.le for*Na $ingle *aturit(-le2el co*.letel( a..lie& to all of t/e .roce$$ nu*ber. area$.
1ro9ect -anage'ent Concern% 3ro8ect *anage*ent i$ t/e &i$ci.line of .lanning% organi+ing an& *anaging re$ource$ to bring about t/e $ucce$$ful co*.letion of $.ecific .ro8ect goal$ an& ob8ecti2e$. 9 .ro8ect i$ a finite en&ea2or H/a2ing $.ecific $tart an& co*.letion &ate$J un&erta4en to create a uni'ue .ro&uct or $er2ice w/ic/ bring$ about beneficial c/ange or a&&e& 2alue. T/i$ finite c/aracteri$tic of .ro8ect$ $tan&$ in $/ar. contra$t to .roce$$e$% or o.eration$% w/ic/ are .er*anent or $e*i-.er*anent functional wor4 to re.etiti2el( .ro&uce t/e $a*e .ro&uct or $er2ice. In .ractice% t/e *anage*ent of t/e$e two $($te*$ i$ often foun& to be 'uite &ifferent% an& a$ $uc/ re'uire$ t/e &e2elo.*ent of &i$tinct tec/nical $4ill$ an& t/e a&o.tion of $e.arate *anage*ent. T/ere are $e2eral a..roac/e$ t/at can be ta4en to *anaging .ro8ect acti2itie$ inclu&ing agile% interacti2e% incre*ental% an& ./a$e& a..roac/e$. ,egar&le$$ of t/e a..roac/ e*.lo(e&% careful con$i&eration nee&$ to be gi2en to clarif( $urroun&ing .ro8ect ob8ecti2e$% goal$% an& i*.ortantl(% t/e role$ an& re$.on$ibilitie$ of all .artici.ant$ an& $ta4e/ol&er$.
176
VU
3ro8ect initiation $tageC 3ro8ect .lanning or &e$ign $tageC 3ro8ect e5ecution or .ro&uction $tageC 3ro8ect *onitoring an& controlling $($te*$C 3ro8ect co*.letion $tage.
Not all t/e .ro8ect$ will 2i$it e2er( $tage a$ .ro8ect$ can be ter*inate& before t/e( reac/ co*.letion. So*e .ro8ect$ .robabl( &onQt /a2e t/e .lanning an&Oor t/e *onitoring. So*e .ro8ect$ will go t/roug/ $te.$ 2% 3 an& 4 *ulti.le ti*e$. #an( in&u$trie$ utili+e 2ariation$ on t/e$e $tage$. =or e5a*.le% in bric4$ an& *ortar arc/itectural &e$ign% .ro8ect$ t(.icall( .rogre$$ t/roug/ $tage$ li4e 3re-3lanning% Conce.tual 7e$ign% Sc/e*atic 7e$ign% 7e$ign 7e2elo.*ent% Con$truction 7rawing$ Hor Contract 7ocu*ent$J% an& Con$truction 9&*ini$tration. In $oftware &e2elo.*ent% t/i$ a..roac/ i$ often 4nown a$ Ywaterfall &e2elo.*entY% i.e.% one $erie$ of ta$4$ after anot/er in linear $e'uence. In $oftware &e2elo.*ent *an( organi+ation$ /a2e a&a.te& t/e ,ational 1nifie& 3roce$$ H,13J to fit t/i$ *et/o&olog(% alt/oug/ ,13 &oe$ not re'uire or e5.licitl( reco**en& t/i$ .ractice. ;aterfall &e2elo.*ent can wor4 for $*all tig/tl( &efine& .ro8ect$% but for larger .ro8ect$ of un&efine& or un4nowable $co.e% it i$ le$$ $uite&. T/e Cone of 1ncertaint( e5.lain$ $o*e of t/i$ a$ t/e .lanning *a&e on t/e initial ./a$e of t/e .ro8ect $uffer$ fro* a /ig/ &egree of uncertaint(. T/i$ beco*e$ $.eciall( true a$ $oftware &e2elo.*ent i$ often t/e reali+ation of a new or no2el .ro&uct% t/i$ *et/o& /a$ been wi&el( acce.te& a$ ineffecti2e for $oftware .ro8ect$ w/ere re'uire*ent$ are largel( un4nowable u. front an& $u$ce.tible to c/ange. ;/ile t/e na*e$ *a( &iffer fro* in&u$tr( to in&u$tr(% t/e actual $tage$ t(.icall( follow co**on $te.$ to .roble* $ol2ing N Y&efining t/e .roble*% weig/ing o.tion$% c/oo$ing a .at/% i*.le*entation an& e2aluation.Y Software ;ualit2 #%%urance Software 'ualit( a$$urance HS@9J con$i$t$ of a *ean$ of *onitoring t/e $oftware engineering .roce$$e$ an& *et/o&$ u$e& to en$ure 'ualit(. T/e *et/o&$ b( w/ic/ t/i$ i$ acco*.li$/e& are *an( an& 2arie&% an& *a( inclu&e en$uring confor*ance to one or *ore $tan&ar&$% $uc/ a$ ISA "000 or C##I. T/i$ &efinition e*./a$i+e$ u.on t/ree i*.ortant .oint$6 $ $ $ Software re'uire*ent$ are t/e foun&ation fro* w/ic/ 'ualit( i$ *ea$ure&. Lac4 of confor*ance i$ lac4 of 'ualit( S.ecifie& $tan&ar&$ &efine a $et of &e2elo.*ent criteria t/at gui&e t/e *anner in w/ic/ $oftware i$ engineere&. If t/e criteria are not followe&% lac4 of 'ualit( will al*o$t $urel( re$ult. 9 $et of i*.licit re'uire*ent$ often goe$ un*entione& Hea$e of u$e% goo& *aintainabilit( etc.J
9not/er 2er( i*.ortant 'ue$tion i$6 7o (ou nee& to worr( about it after t/e co&e /a$ been generate&L In fact% S@9 i$ an u*brella acti2it( t/at i$ a..lie& t/roug/out t/e $oftware .roce$$.
177
VU
Goal of 'ualit( a$$urance i$ to .ro2i&e t/e *anage*ent wit/ t/e nece$$ar( &ata to be infor*e& about .ro&uct 'ualit(. It con$i$t$ of au&iting an& re.orting function$ of *anage*ent. If &ata .ro2i&e& t/roug/ @9 i&entifie$ .roble*$% t/e *anage*ent &e.lo($ t/e nece$$ar( re$ource$ to fi5 it an& /ence ac/ie2e$ &e$ire& 'ualit( control. Co%t of &ualit2 9 2er( $ignificant 'ue$tion i$6 &oe$ 'ualit( a$$urance a&& an( 2alue. T/at i$% i$ wort/ $.en&ing a lot of *one( in 'ualit( a$$urance .ractice$L In or&er to un&er$tan& t/e i*.act of 'ualit( a$$urance .ractice$% we /a2e to un&er$tan& t/e co$t of 'ualit( Hor lac4 t/ereofJ in a $($te*. @ualit( /a$ a &irect an& in&irect co$t in t/e for* of co$t of .re2ention% a..rai$al% an& failure. If we tr( to .re2ent .roble*$% ob2iou$l( we will /a2e to incur co$t. T/i$ co$t inclu&e$6 $ @ualit( .lanning $ =or*al tec/nical re2iew$ $ Te$t e'ui.*ent $ Training ;e will &i$cu$$ t/e$e in *ore &etail in t/e later $ection$. T/e co$t of a..rai$al inclu&e$ acti2itie$ to gain in$ig/t into t/e .ro&uct con&ition. It in2ol2e$ in-.roce$$ an& inter-.roce$$ in$.ection an& te$ting. 9n& finall(% failure co$t. =ailure co$t /a$ two co*.onent$6 internal failure co$t an& e5ternal failure co$t. Internal failure co$t re'uire$ rewor4% re.air% an& failure *o&e anal($i$. An t/e ot/er /an&% e5ternal failure co$t in2ol2e$ co$t for co*.laint re$olution% .ro&uct return an& re.lace*ent% /el.-line $u..ort% warrant( wor4% an& law $uit$. S;# #cti,itie% T/ere are two &ifferent grou.$ in2ol2e& in S@9 relate& acti2itie$6 $ $ Software engineer$ w/o &o t/e tec/nical wor4 S@9 grou. w/o i$ re$.on$ible for @9 .lanning% o2er$ig/t% recor& 4ee.ing% anal($i$% an& re.orting Software engineer$ a&&re$$ 'ualit( b( a..l(ing $oli& tec/nical *et/o&$ an& *ea$ure$% con&ucting for*al an& tec/nical re2iew$% an& .erfor*ing well .lanne& $oftware te$ting. T/e S@9 grou. a$$i$t$ t/e $oftware tea* in ac/ie2ing a /ig/ 'ualit( .ro&uct. S;# Frou* #cti,itie% 9n S@9 .lan i$ &e2elo.e& for t/e .ro8ect &uring .ro8ect .lanning an& i$ re2iewe& b( all $ta4e /ol&er$. T/e .lan inclu&e$ t/e i&entification of6 $ $ $ $ $ E2aluation$ to be .erfor*e& 9u&it$ an& re2iewe& to be .erfor*e& Stan&ar&$ t/at are a..licable to t/e .ro8ect 3roce&ure$ for error re.orting an& trac4ing 7ocu*ent$ to be .ro&uce& b( t/e S@9 grou.
178
CS605 Software Engineering-II $ 9*ount of fee&bac4 .ro2i&e& to t/e $oftware .ro8ect tea*
VU
T/e grou. .artici.ate$ in t/e &e2elo.*ent of t/e .ro8ect:$ $oftware .roce$$ &e$cri.tion. T/e $oftware tea* $elect$ t/e .roce$$ an& S@9 grou. re2iew$ t/e .roce$$ &e$cri.tion for co*.liance wit/ t/e organi+ational .olicie$% internal $oftware $tan&ar&$% e5ternall( i*.o$e& $tan&ar&$% an& ot/er .art$ of t/e $oftware .ro8ect .lan. ;ualit2 Control T/e ne5t 'ue$tion t/at we nee& to a$4 i$% once we /a2e &efine& /ow to a$$e$$ 'ualit(% /ow are we going to *a4e $ure t/at our .roce$$e$ &eli2er t/e .ro&uct wit/ t/e &e$ire& 'ualit(. T/at i$% /ow are we going to control t/e 'ualit( of t/e .ro&uctL T/e ba$ic .rinci.le of 'ualit( control i$ to control t/e 2ariation a$ 2ariation control i$ t/e /eart of 'ualit( control. It inclu&e$ re$ource an& ti*e e$ti*ation% te$t co2erage% 2ariation in nu*ber of bug$% an& 2ariation in $u..ort. =ro* one .ro8ect to anot/er we want to *ini*i+e t/e .re&icte& re$ource$ nee&e& to co*.lete a .ro8ect an& calen&ar ti*e. T/i$ in2ol2e$ a $erie$ of in$.ection% re2iew$% an& te$t$ an& inclu&e$ fee&bac4 loo.. So 'ualit( control i$ a co*bination of *ea$ure*ent an& fee&bac4 an& co*bination of auto*ate& tool$ an& *anual interaction.
T!e End
179