📺 Develpreneur YouTube Episode

Video + transcript

Creating Software Patterns and Anti-Patterns Part 1

2022-06-14 Youtube

Detailed Notes

We have had many discussions about software patterns and anti-patterns over the years.  However, we have not talked about creating software patterns.  That is an important topic because they have to come from somewhere, and the list will grow.  This session from our mentor classes shows how to build on and document your experience.

Creating Software Patterns Has Many Steps There is a difference between learning any topic when compared to teaching it.  Likewise, solving a problem once is only a piece of repeating or automating that process.  Patterns and Anti-patterns follow those same progressions.  We do things for a while, observe them, clean them, and communicate our findings.  All of that takes time and is an excellent way to become a better developer.

The Mentor-Mastermind Group This series comes from our mentoring/mastermind classes.  These classes are virtual meetings that focus on how to improve our technical skills and build our businesses.  The goals of each member vary.  However, this diversity makes for great discussions and educational value every time we meet.  We hope you enjoy viewing this series as much as we enjoy creating it.  As always, this may not be all new to you, but we hope it helps you be a better developer.  Drop us a line to find out when the next one is so you can join our group.

Other series you might consider:

Creating a Product Catalog Software Design Patterns Anti-patterns and How Not To Build Software

Transcript Text
[Music]
so this presentation
comes out of
the past few years we've numerous times
talked about patterns we've talked about
any patterns we've talked about software
patterns and project planning patterns
and
how they apply to
agile and and just so many places
and all of these have been
uh basically sourced from other people
yeah it's it's either in books or out on
the web or something like that
and what i wanted to do is is spend a
little time
in this presentation talking about how
do you maybe build out your own patterns
and annie patterns
and and how do you
how do you make something and say hey
yeah this is a pattern as opposed to
maybe just a habit or something like
that
so
i'm gonna in doing so i'm gonna talk
just sort of revisit what's a pattern
what are annie patterns
how do you lean on your experience to
build these out
touch on the rule of three
or a version of the rule of three
and then
how do you refine sort of your rough
draft of what a pattern or any pattern
is and then
you know the the point of it sort of is
how do you share your knowledge
so software patterns in particular now
there's numerous
patterns that are out there
uh in the it world but originally the
idea was
came from software patterns they're
highlighted and described in
basically the early 90s there's a book
called design pattern software design
patterns
it's often referred to as the gang of
four book because it's
uh
four authors that at the time it was and
they've all got you know nice long names
it's not like you know smith jones brown
bob or something like that it's longer
names
and
rather than have that big long list of
names they just a lot of people just
call it gang of four or even gof
um
it's just one of those things because
hey we're you know we're i.t people we
shorten stuff up
a pattern a software pattern is just it
really it comes out it's a common
solution to a problem it's where you see
this problem over and over again
it's a pattern that says here is a way
to solve this problem and it's usually
comes out of multiple attempts to solve
that problem
uh usually you know successful attempts
and what are the commonalities because
every time we solve a problem there may
be
some
slightly different facets to it
sums are some are
very very similar
if you think for example like a login
for an application
the idea of solving the problem of
how do i get a user into a system how do
i give them some ability to log in how
to have them uh what do i need to do to
allow them to
administer that you know like change
password forgot password
um
maybe enforcing some sort of password
strength or security
those things may vary a little bit
uh particularly like it maybe it's uh
maybe you're implementing in a different
language maybe the interface is a little
different maybe the back end is a little
different but overall
uh one patterns are not gonna they're
not
tied to a technology
they're sort of like a level above that
uh but then two it's it's one of those
if you can get 80 or 90 there with a
a pattern with a process or a series of
steps then that just that just
jumpstarts you forward to get you to the
stuff that are
the more unique problems you need to
solve
so that's the key is software patterns
help us quickly build new solutions
based on past work either of ourselves
or others and this is going to be higher
quality because we're reusing
the
the lessons learned in the past all of
the concepts
and the the stumbles and the gotchas
have been sort of baked into the pattern
so that we're much more likely to have
something that's going to be successful
at least the the pattern part of it i
mean we can always screw it up but
it is something that we
um we're gonna be less likely to because
the the thing you know it's one of those
things like knowledge gaps and not
knowing what you don't know becomes less
of an issue because other people have
gone through this or we're reviewing
what we saw in the past and using that
to inform us for solving this particular
problem
any patterns
followed after the idea of patterns is
as
people do
people started looking at it saying well
you know there's a lot of things that
a lot of problems that we solve and we
see how
we should address this problem
but then they sort of went to the flip
side and said well what about all of the
situations where we say here's a problem
and these are the ways you definitely do
not want to
do it or here are the things you
definitely do not want to get yourself
into
the probably the most classic
anti-pattern ever would be like painting
yourself into a corner
and so
those things exist all over the place as
do the patterns
and it made sense to say well let's
start
talking about any patterns much as we do
patterns
and sort of use them as cautionary tales
maybe or warning signs that you want to
avoid when you're building out a
solution or designing a solution
and really what it is is any pattern is
a a common typical stumbling block that
either
reduces quality
increases your chance of failure or
maybe guarantees failure uh in some
cases but it's not necessarily just in
failed projects it may be things that
occur in a successful project that in
that you really just don't want to go
through either it adds them the cost of
maintainability reduces performance
reduces scalability
uh it's really just
any patterns really come down to it
they're not focusing so much on failures
as much as
uh
you almost want to call like worst
practices if you hear about things that
are best practices if you do these
things you're more likely to have a you
know a better more valuable solution
adding patterns are the opposite these
are the things that if you do these it's
it's going to really challenge your
ability to
produce the best solution
so it's really looking at just let's
let's find a way to
sort of categorize document pass
mistakes
and
provide a way that people can avoid
making those mistakes
and in doing so hopefully improve the
velocity and quality of
development efforts
and the key to office is
this our next little step here is we're
going to lean on our experience
because
there are a few teachers that are better
than experience
it allows us to do things like
avoid potholes you know those those
bumps in the road
those challenges we run into that take
take up a lot of our time
or cause us a lot of frustration where
in retrospect we look back and say you
know i could have avoided that
like a a classic example would be
if you don't back a machine up and your
machine dies and you spend
who knows how much time trying to
recover what you lost
you know that's something going forward
you can say hey i need good backups i
need regular backups of my sheen so i
don't lose stuff
but we also can get our experience we
can find some algorithms we can find
as we solve a problem over and over
again we can take those
specific solutions and turn them into
general solutions
it's something that we can do to
speed ourselves forward because then we
can basically reuse that solution now
it's it's
if we've made a general case
for it
um along the same ways is while we can
find common solutions or general
solutions we also are going to find
among those general or common mistakes
a good example in coding is not
capturing um exceptions it's not
handling exceptions properly
and especially in certain languages and
frameworks and formats and
areas that we you know just environments
we can get into where we can use some
sort of
error handling and exception handling
it's not uncommon for us to just you
know sort of go through and code the
happy path and not really think about
those other things
well we can avoid doing so we can look
back and say yeah
i had this thing and it gave me just
ridiculous headaches and if i had just
properly
tracked logged you know whatever output
mistakes or exceptions errors or
exceptions then it would have been a lot
faster to handle
experience also can teach us shortcuts
we can look at stuff and say wow i went
through all of this extra work
but really i could have skipped three of
those steps because they ended up being
not very helpful
or
those things that i took steps
solving that problem that were really
kind of like research is i had to look
into some options you know like maybe i
was faced with three different options i
ended up having to explore all three
but now i know which one of those three
options makes sense so i can take a
shortcut i don't have to explore all
three of those in the future
in a similar sense
experience is going to teach us common
paths they're going to be
problems that we solve sometimes they're
going to be very different from past
problems and you feel like you've been
here before you maybe get sort of like
that sense of deja vu
and you're going to realize that oh this
is
something i've had to do before it may
have been a completely different problem
i was solving but the
this step or these series of steps
um i've seen them before and so i have a
better idea now of how to go forward
because they're it feels familiar
it would be like traveling from one city
to another
and there's maybe 10 different ways but
sometimes you're on
uh you know sections of road or sections
of the journey that you've been on
before so you're like oh okay
i know this so i know that you know
there's a gas station up ahead or a
restaurant or whatever
uh likewise is
experience that helps us along with
potholes is avoiding the
the treacherous past we'll call them you
know the cases where
yeah we can do that but it's it's
risky or time consuming or costly or
whatever it happens to be
so we can
uh we can also just keep our heads up
sometimes
you know if you've i'd be like climbing
a mountain
if you've scaled the side of a cliff
and you know done free climbing or one
of those kinds of things and i haven't
but i'm going to assume
that
there are
things that you learn going from one to
another about just how the handholds are
how far you can step how far you can
swing what can hold your weight and what
can't
all those kinds of things that
experience teach us it's basically that
hey if
if i do
this if i take this
path then here's some things i'm going
to need to do to be
you know to be safe or to increase my
chance of success
so we get a lot out of experience
and now
although this is through this one out
there with the rule of three
this is not the three laws of robotics
which is a very different rule of three
uh rule of three in general actually
there's
many ways that it shows up
um we're going to talk about a specific
one that we're going to call sort of a
rule of three
there are other ones related to sales
and marketing and things like that
but in this case
we're going to talk about
doing something three times
because
there's something sort of magical about
that uh and maybe not magical it just
it's
um
if you think of doing something like in
a sweeping motion you know like
if you
i don't know like take a broom and sweep
it across the floor the first time you
sweep it across you'll get you know
whatever it is 60 70 of the dust and if
you do it again you'll probably take
some more dust if you do it again you'll
take some more but now you're you're
down to probably very minimal amount of
dust
same kind of thing with doing almost any
task
and in solving problems typically what
we do
is the first time we
solve a problem is we're really solving
more or less for a specific case we may
see
opportunities where this can be used
generally
but we're
we're still solving for
that specific case
the second time we see it now we've got
two
things to compare the pro you know the
first attempt and the second attempt and
that's going to help us to generalize
the solution it's going to say hey now
we've seen it a second time
let's take this solution and make it
more general case
and then by the time we get to the third
time now
we should be able to see far more
for lack of better term patterns in the
problem
and how we're going to solve it
we've generalized it and now we've even
sort of tested that generalization
because we we did it for the you know we
did the specific for the first time we
created a general solution the second
time and now by the time we see it the
third time we're going to try to use
that general solution and try to apply
it to the third
and there may be some you know some some
refinements and and stuff that come in
when we do it that third time but now
by the time we've gone through three
times
we've essentially tested the solution
three different ways
um we've seen yeah we
we may not have seen outliers but we've
probably seen
a good portion of what this problem's
typically going to look like
so by the time we get through three we
we should be pretty
confident what we've got is a good
general case solution that doesn't mean
that there won't be you know there
aren't bugs that there aren't issues
but
do we get that third time
typically it's going to get us you know
really close to where we need to be
you're not going to see you're going to
see maybe a lot of we'll see a lot of
changes
the second time through
because now you're you know you're
really highlighting what's the same and
what's the difference you're going to
see a few changes probably the third
time you do it but then as you go to the
fourth and the fifth and the sixth you
know it'll be maybe changes here and
there but
it's definitely going to be less should
be unless you're doing it wrong
less each
iteration
and
eventually you're going to get into
cases where you're you're also going to
be able to determine that oh well this
you know this should change but it's a
it's really it's an outlier this is not
part of the
really that true general cases or
general solution
so thinking about that
with the idea of patterns in any
patterns
is really it comes down to
it's it's simpler than probably it
sounds
is it we're going to see problems and
we're going to see the same problem over
and over again
so when we want to sit down and say what
would be
a pattern or when we want to start
building out our
patterns and anti-patterns
and a reason for this is
both personal so that we can become
better developers and also for our
organization because there will be
organizational
patterns
for example if you think about financial
organizations or health care
organizations or
organizations that deal with government
there are problems that they see that
other industries other organizations may
not
and then even a specific company
a specific
business
will see things that maybe other uh
their competitors maybe don't
and so there's going to be sort of like
levels of specificity of patterns and
any patterns
and so as we're
doing our work and
building you know with the idea of
becoming a better developer and trying
to
think about what are some
uh some of our own patterns and
anti-patterns
first thing we want to do is look for
common
uh functionality or steps
when we're going from problem to problem
uh application application page to page
whatever it is
where are there
things that we're having to think
through that are repeated you know where
is it a repetition of
either functionality or
requirements
problem definitions
and even across solutions
because there may be things that it
doesn't really pop up in the problem but
if you look at the solution you realize
that oh
we had all these different problems that
we saw but what by the time we got to
the end
here are the things that we
had sort of drop out on the back end you
know that were part of the solution that
are very similar
and maybe this is now a pattern we need
to
front load so we don't try to solve it
while we're
you know doing our application a good
example would be
uh data audit
record type information
so if you're
doing some sort of application that
needs some
an audit trail such as what was changed
who changed it when was it changed then
you'll find especially if you do this
across a bunch of different applications
you'll see that it really doesn't
matter too much what the application is
there's the same couple of steps that
you're going to do over and over again
and it there is a pattern for that
and so it's something that you may say
okay
this is a pattern that we can we can use
as we go through
um all the other you know future
applications and somebody answers a
question that
as a positive that says do we need some
sort of audit history or audit trail
and there's also gonna be any patterns
there's gonna be things you're gonna
look at through that and you're gonna
say oh my gosh this is
this was not the way to do it this did
not scale or
whatever it was
and so you're going to see those
anti-patterns as well
you're going to see
particularly when you look in the world
of agile
if you look at retrospectives that could
be a great opportunity for any patterns
because you may see things that are in
the actually both patterns and
anti-patterns because you may see things
that recur in the
what we did right or what we
want to do
categories
would be more your patterns and then the
things that let's not do that again or
we need to do less of that would be you
know maybe point to some anti-patterns
you
Transcript Segments
0.43

[Music]

28

so this presentation

30.8

comes out of

32.8

the past few years we've numerous times

34.96

talked about patterns we've talked about

36.48

any patterns we've talked about software

39.04

patterns and project planning patterns

41.12

and

42.16

how they apply to

44.48

agile and and just so many places

47.44

and all of these have been

50.079

uh basically sourced from other people

52.16

yeah it's it's either in books or out on

54.399

the web or something like that

56.16

and what i wanted to do is is spend a

58.16

little time

59.199

in this presentation talking about how

60.719

do you maybe build out your own patterns

64

and annie patterns

65.519

and and how do you

67.28

how do you make something and say hey

68.56

yeah this is a pattern as opposed to

71.28

maybe just a habit or something like

72.72

that

75.6

so

76.56

i'm gonna in doing so i'm gonna talk

78.4

just sort of revisit what's a pattern

80.159

what are annie patterns

82.96

how do you lean on your experience to

85.36

build these out

88.08

touch on the rule of three

90.88

or a version of the rule of three

93.2

and then

94.24

how do you refine sort of your rough

95.84

draft of what a pattern or any pattern

97.84

is and then

99.28

you know the the point of it sort of is

101.04

how do you share your knowledge

104.159

so software patterns in particular now

106.32

there's numerous

108.32

patterns that are out there

110.96

uh in the it world but originally the

114.159

idea was

115.439

came from software patterns they're

117.36

highlighted and described in

120.159

basically the early 90s there's a book

122.159

called design pattern software design

123.92

patterns

124.96

it's often referred to as the gang of

127.119

four book because it's

129.36

uh

130.479

four authors that at the time it was and

133.28

they've all got you know nice long names

134.959

it's not like you know smith jones brown

137.12

bob or something like that it's longer

138.64

names

140.16

and

141.04

rather than have that big long list of

144.16

names they just a lot of people just

146.319

call it gang of four or even gof

149.12

um

150.08

it's just one of those things because

151.36

hey we're you know we're i.t people we

153.519

shorten stuff up

155.36

a pattern a software pattern is just it

157.28

really it comes out it's a common

158.48

solution to a problem it's where you see

160.64

this problem over and over again

162.879

it's a pattern that says here is a way

164.959

to solve this problem and it's usually

167.44

comes out of multiple attempts to solve

170.08

that problem

171.36

uh usually you know successful attempts

174.319

and what are the commonalities because

177.76

every time we solve a problem there may

179.92

be

180.64

some

182

slightly different facets to it

186.08

sums are some are

187.599

very very similar

189.28

if you think for example like a login

191.84

for an application

193.76

the idea of solving the problem of

196.72

how do i get a user into a system how do

199.92

i give them some ability to log in how

202.319

to have them uh what do i need to do to

204.159

allow them to

205.44

administer that you know like change

207.04

password forgot password

209.36

um

210.319

maybe enforcing some sort of password

212.4

strength or security

214.799

those things may vary a little bit

217.519

uh particularly like it maybe it's uh

220.159

maybe you're implementing in a different

221.519

language maybe the interface is a little

223.36

different maybe the back end is a little

225.2

different but overall

227.36

uh one patterns are not gonna they're

229.519

not

230.4

tied to a technology

232.4

they're sort of like a level above that

234.72

uh but then two it's it's one of those

236.72

if you can get 80 or 90 there with a

240.64

a pattern with a process or a series of

242.879

steps then that just that just

244.799

jumpstarts you forward to get you to the

247.28

stuff that are

248.64

the more unique problems you need to

250.319

solve

251.84

so that's the key is software patterns

253.84

help us quickly build new solutions

256.32

based on past work either of ourselves

258.239

or others and this is going to be higher

260.239

quality because we're reusing

262.56

the

263.52

the lessons learned in the past all of

265.84

the concepts

267.36

and the the stumbles and the gotchas

270.8

have been sort of baked into the pattern

274.16

so that we're much more likely to have

275.68

something that's going to be successful

277.28

at least the the pattern part of it i

280.08

mean we can always screw it up but

283.28

it is something that we

285.28

um we're gonna be less likely to because

288.479

the the thing you know it's one of those

290.24

things like knowledge gaps and not

292.479

knowing what you don't know becomes less

294.56

of an issue because other people have

296.08

gone through this or we're reviewing

298.16

what we saw in the past and using that

300.88

to inform us for solving this particular

303.36

problem

305.84

any patterns

307.44

followed after the idea of patterns is

310.8

as

311.6

people do

312.639

people started looking at it saying well

314

you know there's a lot of things that

317.039

a lot of problems that we solve and we

318.72

see how

320.16

we should address this problem

322.88

but then they sort of went to the flip

324.88

side and said well what about all of the

326.32

situations where we say here's a problem

328.72

and these are the ways you definitely do

330.639

not want to

332.479

do it or here are the things you

334.16

definitely do not want to get yourself

335.759

into

336.96

the probably the most classic

338.4

anti-pattern ever would be like painting

340.16

yourself into a corner

342.639

and so

344.32

those things exist all over the place as

346.72

do the patterns

348.24

and it made sense to say well let's

349.919

start

350.8

talking about any patterns much as we do

353.68

patterns

355.039

and sort of use them as cautionary tales

357.759

maybe or warning signs that you want to

359.68

avoid when you're building out a

362

solution or designing a solution

364.479

and really what it is is any pattern is

366.16

a a common typical stumbling block that

370.08

either

371.759

reduces quality

373.52

increases your chance of failure or

376.08

maybe guarantees failure uh in some

378.84

cases but it's not necessarily just in

381.52

failed projects it may be things that

383.84

occur in a successful project that in

386.639

that you really just don't want to go

388.08

through either it adds them the cost of

390.639

maintainability reduces performance

393.36

reduces scalability

395.919

uh it's really just

398.4

any patterns really come down to it

399.68

they're not focusing so much on failures

402.16

as much as

404

uh

404.88

you almost want to call like worst

406.319

practices if you hear about things that

407.919

are best practices if you do these

409.36

things you're more likely to have a you

410.96

know a better more valuable solution

413.52

adding patterns are the opposite these

415.12

are the things that if you do these it's

417.36

it's going to really challenge your

418.96

ability to

420.319

produce the best solution

422.96

so it's really looking at just let's

424.56

let's find a way to

426.319

sort of categorize document pass

428.72

mistakes

430

and

430.8

provide a way that people can avoid

433.039

making those mistakes

434.72

and in doing so hopefully improve the

436.319

velocity and quality of

438.319

development efforts

442.96

and the key to office is

444.8

this our next little step here is we're

446.319

going to lean on our experience

449.199

because

450.88

there are a few teachers that are better

452.56

than experience

454.319

it allows us to do things like

456.56

avoid potholes you know those those

458.56

bumps in the road

460

those challenges we run into that take

463.12

take up a lot of our time

464.879

or cause us a lot of frustration where

467.44

in retrospect we look back and say you

469.12

know i could have avoided that

472.24

like a a classic example would be

475.36

if you don't back a machine up and your

477.28

machine dies and you spend

479.759

who knows how much time trying to

481.039

recover what you lost

483.28

you know that's something going forward

484.56

you can say hey i need good backups i

486.639

need regular backups of my sheen so i

488.4

don't lose stuff

490.639

but we also can get our experience we

493.039

can find some algorithms we can find

495.68

as we solve a problem over and over

497.759

again we can take those

500.24

specific solutions and turn them into

503.759

general solutions

505.759

it's something that we can do to

508.879

speed ourselves forward because then we

511.84

can basically reuse that solution now

514.479

it's it's

515.519

if we've made a general case

517.44

for it

519.039

um along the same ways is while we can

521.36

find common solutions or general

523.519

solutions we also are going to find

525.76

among those general or common mistakes

529.12

a good example in coding is not

533.04

capturing um exceptions it's not

535.519

handling exceptions properly

537.44

and especially in certain languages and

539.92

frameworks and formats and

543.04

areas that we you know just environments

544.64

we can get into where we can use some

547.2

sort of

548.8

error handling and exception handling

552.08

it's not uncommon for us to just you

554.16

know sort of go through and code the

555.279

happy path and not really think about

558.08

those other things

559.839

well we can avoid doing so we can look

562.16

back and say yeah

564.32

i had this thing and it gave me just

566.8

ridiculous headaches and if i had just

569.2

properly

570.48

tracked logged you know whatever output

573.279

mistakes or exceptions errors or

575.519

exceptions then it would have been a lot

577.04

faster to handle

579.2

experience also can teach us shortcuts

581.519

we can look at stuff and say wow i went

583.36

through all of this extra work

585.44

but really i could have skipped three of

587.2

those steps because they ended up being

588.72

not very helpful

590.48

or

591.839

those things that i took steps

594.56

solving that problem that were really

597.76

kind of like research is i had to look

599.839

into some options you know like maybe i

602.56

was faced with three different options i

604.32

ended up having to explore all three

606.48

but now i know which one of those three

608.56

options makes sense so i can take a

610.72

shortcut i don't have to explore all

612.24

three of those in the future

614.72

in a similar sense

617.04

experience is going to teach us common

618.399

paths they're going to be

620.8

problems that we solve sometimes they're

622.48

going to be very different from past

624

problems and you feel like you've been

626.24

here before you maybe get sort of like

628

that sense of deja vu

630

and you're going to realize that oh this

632.079

is

634.079

something i've had to do before it may

635.92

have been a completely different problem

637.76

i was solving but the

640

this step or these series of steps

642.8

um i've seen them before and so i have a

645.04

better idea now of how to go forward

647.279

because they're it feels familiar

650.24

it would be like traveling from one city

652.399

to another

654.24

and there's maybe 10 different ways but

655.92

sometimes you're on

657.279

uh you know sections of road or sections

660.48

of the journey that you've been on

661.68

before so you're like oh okay

663.44

i know this so i know that you know

665.04

there's a gas station up ahead or a

666.399

restaurant or whatever

668.56

uh likewise is

671.04

experience that helps us along with

672.959

potholes is avoiding the

675.04

the treacherous past we'll call them you

676.8

know the cases where

678.88

yeah we can do that but it's it's

681.92

risky or time consuming or costly or

685.04

whatever it happens to be

687.76

so we can

689.279

uh we can also just keep our heads up

691.36

sometimes

692.56

you know if you've i'd be like climbing

694.399

a mountain

695.36

if you've scaled the side of a cliff

698.48

and you know done free climbing or one

700.48

of those kinds of things and i haven't

702

but i'm going to assume

703.44

that

704.56

there are

706.16

things that you learn going from one to

708

another about just how the handholds are

710.959

how far you can step how far you can

712.8

swing what can hold your weight and what

714.639

can't

716.079

all those kinds of things that

718.16

experience teach us it's basically that

720.16

hey if

721.44

if i do

722.88

this if i take this

724.8

path then here's some things i'm going

726.56

to need to do to be

728.88

you know to be safe or to increase my

731.12

chance of success

735.2

so we get a lot out of experience

738.88

and now

739.839

although this is through this one out

741.6

there with the rule of three

743.6

this is not the three laws of robotics

745.44

which is a very different rule of three

747.839

uh rule of three in general actually

749.76

there's

750.8

many ways that it shows up

754.32

um we're going to talk about a specific

756.32

one that we're going to call sort of a

757.92

rule of three

759.36

there are other ones related to sales

760.959

and marketing and things like that

762.8

but in this case

764.399

we're going to talk about

766.639

doing something three times

769.04

because

770.16

there's something sort of magical about

772.399

that uh and maybe not magical it just

775.279

it's

776.399

um

777.76

if you think of doing something like in

779.6

a sweeping motion you know like

781.76

if you

782.8

i don't know like take a broom and sweep

784.72

it across the floor the first time you

786.56

sweep it across you'll get you know

788.24

whatever it is 60 70 of the dust and if

790.8

you do it again you'll probably take

792

some more dust if you do it again you'll

793.519

take some more but now you're you're

795.2

down to probably very minimal amount of

796.88

dust

798.32

same kind of thing with doing almost any

801.36

task

802.88

and in solving problems typically what

805.12

we do

806.079

is the first time we

808.079

solve a problem is we're really solving

810.16

more or less for a specific case we may

812.639

see

813.519

opportunities where this can be used

815.2

generally

816.24

but we're

817.2

we're still solving for

819.12

that specific case

821.199

the second time we see it now we've got

824.24

two

825.279

things to compare the pro you know the

827.12

first attempt and the second attempt and

829.199

that's going to help us to generalize

830.8

the solution it's going to say hey now

832.32

we've seen it a second time

834.16

let's take this solution and make it

836.16

more general case

838.24

and then by the time we get to the third

839.68

time now

841.279

we should be able to see far more

844.24

for lack of better term patterns in the

846.32

problem

847.36

and how we're going to solve it

849.44

we've generalized it and now we've even

851.6

sort of tested that generalization

853.44

because we we did it for the you know we

855.839

did the specific for the first time we

857.839

created a general solution the second

859.6

time and now by the time we see it the

861.92

third time we're going to try to use

863.12

that general solution and try to apply

865.36

it to the third

866.72

and there may be some you know some some

868.72

refinements and and stuff that come in

871.04

when we do it that third time but now

873.92

by the time we've gone through three

874.959

times

876.48

we've essentially tested the solution

878.56

three different ways

880.16

um we've seen yeah we

882.88

we may not have seen outliers but we've

885.04

probably seen

886.8

a good portion of what this problem's

889.279

typically going to look like

890.8

so by the time we get through three we

892.399

we should be pretty

894.16

confident what we've got is a good

895.92

general case solution that doesn't mean

897.68

that there won't be you know there

898.8

aren't bugs that there aren't issues

901.12

but

902.24

do we get that third time

904.32

typically it's going to get us you know

905.92

really close to where we need to be

907.519

you're not going to see you're going to

908.639

see maybe a lot of we'll see a lot of

910.639

changes

911.76

the second time through

913.44

because now you're you know you're

914.8

really highlighting what's the same and

916.079

what's the difference you're going to

917.36

see a few changes probably the third

919.12

time you do it but then as you go to the

920.48

fourth and the fifth and the sixth you

921.92

know it'll be maybe changes here and

923.519

there but

924.56

it's definitely going to be less should

926.88

be unless you're doing it wrong

928.72

less each

929.92

iteration

931.279

and

933.199

eventually you're going to get into

934.24

cases where you're you're also going to

935.519

be able to determine that oh well this

937.04

you know this should change but it's a

938.48

it's really it's an outlier this is not

940.32

part of the

941.68

really that true general cases or

944.079

general solution

948.72

so thinking about that

952.399

with the idea of patterns in any

953.839

patterns

955.6

is really it comes down to

957.839

it's it's simpler than probably it

959.44

sounds

961.04

is it we're going to see problems and

962.959

we're going to see the same problem over

964.88

and over again

967.04

so when we want to sit down and say what

969.199

would be

970.56

a pattern or when we want to start

972.56

building out our

974.88

patterns and anti-patterns

977.12

and a reason for this is

979.519

both personal so that we can become

981.36

better developers and also for our

983.36

organization because there will be

985.199

organizational

986.8

patterns

988.079

for example if you think about financial

990.399

organizations or health care

992.079

organizations or

993.6

organizations that deal with government

996.32

there are problems that they see that

998.72

other industries other organizations may

1000.639

not

1002

and then even a specific company

1004.48

a specific

1006

business

1007.44

will see things that maybe other uh

1009.92

their competitors maybe don't

1012.639

and so there's going to be sort of like

1014.56

levels of specificity of patterns and

1017.68

any patterns

1019.68

and so as we're

1021.12

doing our work and

1023.04

building you know with the idea of

1024.88

becoming a better developer and trying

1026.799

to

1027.679

think about what are some

1030.319

uh some of our own patterns and

1032.64

anti-patterns

1034.48

first thing we want to do is look for

1036.4

common

1037.439

uh functionality or steps

1041.039

when we're going from problem to problem

1043.039

uh application application page to page

1045.36

whatever it is

1046.88

where are there

1048.88

things that we're having to think

1050.16

through that are repeated you know where

1053.28

is it a repetition of

1055.679

either functionality or

1058.799

requirements

1061.039

problem definitions

1062.96

and even across solutions

1065.44

because there may be things that it

1066.88

doesn't really pop up in the problem but

1069.52

if you look at the solution you realize

1071.2

that oh

1072.24

we had all these different problems that

1073.76

we saw but what by the time we got to

1075.679

the end

1076.799

here are the things that we

1078.559

had sort of drop out on the back end you

1080.32

know that were part of the solution that

1082.16

are very similar

1083.6

and maybe this is now a pattern we need

1085.919

to

1086.799

front load so we don't try to solve it

1089.52

while we're

1090.72

you know doing our application a good

1092.72

example would be

1094.88

uh data audit

1096.88

record type information

1098.88

so if you're

1100

doing some sort of application that

1101.44

needs some

1102.559

an audit trail such as what was changed

1105.2

who changed it when was it changed then

1108.88

you'll find especially if you do this

1110.4

across a bunch of different applications

1112.88

you'll see that it really doesn't

1115.039

matter too much what the application is

1117.44

there's the same couple of steps that

1119.28

you're going to do over and over again

1121.6

and it there is a pattern for that

1125.6

and so it's something that you may say

1127.039

okay

1128.24

this is a pattern that we can we can use

1131.2

as we go through

1132.88

um all the other you know future

1134.48

applications and somebody answers a

1136.4

question that

1137.52

as a positive that says do we need some

1139.84

sort of audit history or audit trail

1142.16

and there's also gonna be any patterns

1143.52

there's gonna be things you're gonna

1144.32

look at through that and you're gonna

1145.28

say oh my gosh this is

1147.039

this was not the way to do it this did

1149.28

not scale or

1151.12

whatever it was

1152.559

and so you're going to see those

1153.52

anti-patterns as well

1155.84

you're going to see

1157.12

particularly when you look in the world

1158.96

of agile

1160.799

if you look at retrospectives that could

1162.96

be a great opportunity for any patterns

1165.44

because you may see things that are in

1167.6

the actually both patterns and

1168.96

anti-patterns because you may see things

1170.88

that recur in the

1173.28

what we did right or what we

1176.08

want to do

1177.52

categories

1178.799

would be more your patterns and then the

1180.559

things that let's not do that again or

1183.28

we need to do less of that would be you

1185.6

know maybe point to some anti-patterns

1204.24

you