软件方法就是用来编写计算机程序的一套规则和惯例。
重量级方法具有很多规则、惯例、和文档。
正确地遵循它们需要训练及时间。
轻量级方法仅具有很少的一些规则和惯例,或者说,这些规则和惯例遵守起来很容易。
在20世纪的60年代后期以及70年代早期,计算机程序员随意使用他们能够使用的任何方式来写软件是件非常常见的事情。
很多程序员竞相写出复杂得对于任何人来说都无法理解的软件。
如果有一个程序,它没有任何的bug,在那时可称得上是个奇迹。
大家都认为让计算机有用武之地是个有价值的追求,不能说不象老早的西部冒险之旅。
EdsgerDijkstra于1968年给CACM(应该是CommunicationoftheAssociationforComputingMachinery:计算机器协会通信)写了一封题为“GOTO语句其实有害”的信。
自此,软件工程的主要概念开始成型。
那时大家认为更全面、更严谨的方法可以帮助我们创建品质可靠、成本可准确估计的软件。
无法无天、牛仔式的编码者们被悬崖勒马。
20世纪80年代正是计算机程序员们的好时光。
我们有了一些规则和惯例。从质量上讲,我们这时写的软件远远优于仅仅是写于几年前的软件。
似乎可以认为:如果能够建立足够多的规则,可适用于所有能够碰到的问题,我们就能够写出完美的软件,并且还能按时完工。
于是乎就有了越来越多的、适用于所有潜在问题的规则和惯例,
现已进入了21世纪,我们发现,这些规则遵守起来非常困难,其过程很复杂,也没有得以透彻地理解;使用各种抽象符号写就的、海一样的文献犹如脱缰的野马纷至沓来。
大家热火朝天,都想提出更全面、更好的方法,跟California(加利福尼亚,加州)淘金热似的真有一比;每个到了西部的人却都很失望。
我们写出了能够帮助我们写软件的软件。
但是,这很快就乱了套,各种重磅炸弹似的CASE工具迎面而来。
这些工具原本是用来帮助我们遵守规则的,可它们用起来很是困难,简直都没法用。
要按时完工,计算机程序员发现他们必须抄近路,忽略一些重要的惯例。
实际上没有一个人真的遵守那些曾经用来自缚的重量级方法。
牛仔又回来了,我们回到了俄克拉荷马州(译者注:俄克拉荷马州是偶对OK的猜测,因为偶了解到俄克拉荷马州曾经是往美国西部输出劳工的一个大州,但可能有误,呵呵)的畜栏之中。
当程序员忽略了他们的方法中的规则时,他们(实际上是)本能地脱离重量级方法,回到了早期较为简单的、轻量级方法时代,很少的规则便够了。
可我们并不想忘记我们已经学到的东西。
我们可以把(能够)帮助我们写出高质量软件的规则保留下来,而摒弃哪些阻碍我们前进的哪些规则。
我们可以对那些复杂得难以遵循的规则进行简化。
我们也不想回到早期根本没有任何规则可言的牛仔式编码时代。
而是让我们止于足够能使我们的软件可靠、适度定价的规则吧。
我们接受软件行政长官而不要牛仔式的编码者;我们作为团队工作在一起,反应敏捷,仅仅用那些轻量级的、简练的和有效的规则和惯例把我们武装起来。
极度编程(XP)就是若干这种新式的、轻量级的方法之中的一种。
XP具有若干规则和适当数量的惯例,且所有这些遵守起来都很容易。
XP是一种干净简洁的环境,它形成于对到底是哪些东西能够加速软件开发,以及哪些东西却起着减速作用的观察。
它是一种使程序员能够自由发挥其创造力和生产力,却同时有保持组织性和凝聚力的环境。
Asoftwaremethodologyisthesetofrulesandpracticesusedtocreatecomputerprograms.
Aheavyweightmethodologyhasmanyrules,practices,anddocuments.
Itrequiresdisciplineandtimetofollowcorrectly.
Alightweightmethodologyhasonlyafewrulesandpracticesoroneswhichareeasytofollow.
Inthelate1960sandearly1970sitwascommonpracticeforcomputerprogrammerstocreatesoftwareanywaytheycould.
Manyprogrammersexcelledatcreatingsoftwaretoocomplexforanyonetounderstand.
Atthattimeitwasamiracleifaprogramranwithoutanybugs.
Makingcomputersusefulwasconsideredaworthyquestandnotunlikeanadventureintotheoldwest.
In1968EdsgerDijkstrawrotealettertoCACMentitledGOTOStatementConsideredHarmful.
Thecentralideasofsoftwareengineeringwerebeingborn.
Atthattimewebelievedthatbigger,moredisciplinedmethodologieswouldhelpuscreatesoftwarewithconsistentqualityandpredictablecosts.
Thelawlesscowboycoderswerebeingreinedin.
The1980sweregoodtimesforcomputerprogrammers.
Wehadafewrulesandpracticestocreatesoftwarethatwasfarsuperiorinqualitytowhatwewerecreatingonlyafewyearsearlier.
Itseemedlikeifwecouldjustcreateenoughrulestocovertheproblemsweencounterwecouldcreateperfectsoftwareandbeontime.
Weaddedmoreandmorerulesandpracticestocoverallthepotentialproblems.
Nowinthe21stcenturywefindtheserulesarehardtofollow,proceduresarecomplexandnotwellunderstoodandtheamountofdocumentationwritteninsomeabstractnotationiswayoutofcontrol.
TryingtocomeupwithabiggerandbettermethodologywaslikeaCaliforniagoldrush;everyoneheadedwestonlytobedisappointed.
Wecreatedsoftwaretohelpuscreatesoftware.
ButthisquicklygotoutofcontrolanddreadnoughtCASEtoolswereborn.
Thesetools,originallycreatedtohelpusfollowtherules,aretoohardtousethemselves.
Computerprogrammersfinditnecessarytocutcornersandskipimportantpracticestostayonschedule.
Nooneisactuallyfollowingtheheavymethodologieswehavehandcuffedourselveswith.
ThecowboyshavereturnedandwefindourselvesbackattheOKCorral.
Whenprogrammersignoretherulesoftheirmethodologytheyareinstinctivelymovingawayfromheavyweightmethodologiesandbacktowardanearlier,simplertimeoflightweightmethodologieswhenafewruleswereenough.
Butwedon'twanttoforgetwhatwehavelearned.
Wecanchoosetokeeptherulesthathelpuscreatequalitysoftwareandthrowawaythosethathinderourprogress.
Wecansimplifythoserulesthatseemtoocomplextofollowcorrectly.
Wedon'twanttoreturntotheearlydaysofcowboycodingwhentherewerenorulesatall.
Butinsteadlet'sstopatjustenoughrulestokeepoursoftwarereliableandreasonablypriced.
Insteadofcowboycoderswehavesoftwaresheriffs;workingtogetherasateam,quickonthedraw,armedwithafewrulesandpracticesthatarelight,concise,andeffective.
ExtremeProgramming(XP)isoneofseveralnewlightweightmethodologies.
XPhasafewrulesandamodestnumberofpractices,allofwhichareeasytofollow.
XPisacleanandconciseenvironmentdevelopedbyobservingwhatmakessoftwaredevelopmentgofasterandwhatmakesitmoveslower.
Itisanenvironmentinwhichprogrammersfeelfreetobecreativeandproductivebutremainorganizedandfocused.
位网民共同编写而成。共计