Loading ...
Sorry, an error occurred while loading the content.

Re: [XP] YAGNI and iterative form of development

Expand Messages
  • Ron Jeffries
    ... Not exactly prototyping, but experiments. Mostly I recommend starting with the real program. And thinking. And doing experiments to eliminate risk. So if
    Message 1 of 3 , Jul 1, 2003
    • 0 Attachment
      On Tuesday, July 1, 2003, at 2:30:40 AM, Vijay Krishnan wrote:

      > I have a small problem regarding YAGNI and iterative form of development.
      > We are in a project , that has the following user stories in terms of modules
      > X1
      > X2
      > X3
      > X4

      > Now X1<X2<X3<X4 in terms of complexity of logic.
      > Also X3, X4 are built upon the work on X1 and X2.

      > Now XP demands that we try to understand about the system by writing some
      > code and prototyping

      Not exactly prototyping, but experiments. Mostly I recommend starting with
      the real program.

      And thinking. And doing experiments to eliminate risk. So if we see a risk
      that later stories will cause trouble ... we experiment. Thus we find out
      whether our planned design will hold up.

      > But sometimes due to deadline pressures, the prototype never reaches to
      > the logical conclusion. As such implementation starts off with X1.... and
      > so on..

      I would not begin with a prototype, but with X1, and would evolve the
      design to always be good. Refactoring. This step we dare not miss, or your
      fears may well be realized.

      > consider u reach X3 stage and realise that even thought u have factored
      > the code for X1, X2... X3 situation makes u realise that there is a flaw
      > in the design itself.

      If I foresaw this risk, I would do an experiment earlier to guide my design
      evolution. Of course, if we do not foresee the risk, nothing we do can
      really help us ... but keeping the design highly modular is a good strategy
      against problems we do not foresee.

      > Now you are back to square 1 ( + 1 slightly better, as we atleast know
      > what is reqd till X3) So wouldnt YAGNI approach postponing things result
      > in such a dilemma

      YAGNI alone would. YAGNI plus thinking plus refactoring will not.

      > could you please let me know , how exactly XP and yagni would work in
      > such a situation? Can YAGNI be applied for design as well ?

      My practice: Always think about design. Never put any design element into
      the current code unless that element is called for by the current code.
      Refactor always to as nearly perfect for the existing situation as
      possible.

      Ron Jeffries
      www.XProgramming.com
      Curiosity is more powerful than skepticism.
    • Brian Christopher Robinson
      ... This is where you refactor. Try the refactoring YahooGroup is you re having trouble with that. You can also try the VirtualPair YahooGroup for general
      Message 2 of 3 , Jul 1, 2003
      • 0 Attachment
        On Tue, 1 Jul 2003, Vijay Krishnan wrote:

        > consider u reach X3 stage and realise that even thought u have factored the code for X1, X2...
        > X3 situation makes u realise that there is a flaw in the design itself.

        This is where you refactor. Try the refactoring YahooGroup is you're
        having trouble with that. You can also try the VirtualPair YahooGroup
        for general questions about design.
      Your message has been successfully submitted and would be delivered to recipients shortly.