【英语翻译Considerthecaseofamail-orderfirmshowninFigure5.16.Ontheleftside,customerSanchezsentapaymentonhisaccount.Atthesametimetheclerkbeginstoprocessthepayment,Sanchezcallsasecondclerkandplacesaneworder.Thef】
英语翻译
Considerthecaseofamail-orderfirmshowninFigure5.16.Ontheleftside,customerSanchezsentapaymentonhisaccount.Atthesametimetheclerkbeginstoprocessthepayment,Sanchezcallsasecondclerkandplacesaneworder.Thefigureshowswhathappensifbothtransacionscontinueandinterferewitheachother.Whatshouldthefinalbalancebe?Doesthecomputerhavethecorrectnumber?Tosolvethisproblem,theapplicationprogrammustknowthatseveralpeoplemighttrytoaccessthesamepieceofdataatthesametime.Thesoftwarelocksoutallusersexceptone.Whenthefirstprocessisfinished,theotheruserscantrytogainaccessagain.Tokeepdataaccurate,applicationsusedbymanypeopleatthesametimemustbewrittentohandletheseconcurrencyproblems.Earlypersonalcomputersweredesignedforonlyoneuser,somuchofthesoftwaredidnotpreventconcurrencyproblems.Softwaredesignedforcomputernetworksgenerallyhandlesthisissue.Whenyouusethissoftware,youwilloccasionallyreceiveamessagethatsaysapieceofdatayoudesireiscurrentlybeingusedbyanotherperson.Ifyougetthismessage,simplywaitforafewminutesandtryagain.Whenthefirstpersonisfinished,youshouldbeabletoproceed.