Cache the result of Diff.evolution() for repeated calls.

Review Request #11250 — Created Oct. 26, 2020 and submitted

Information

Django Evolution
master

Reviewers

Diff.evolution() is a fairly expensive operation that can get called
multiple times. It performs a diff of two signatures, generating a list
of mutations to transform one into the other.

This change caches the result of that so multiple calls won't require
the work to be repeated. After the initial generation, any future calls
are effectively free.

Unit tests pass.

Manually verified that repeated calls were getting the correct results
and not triggering a rebuild.

Summary ID
Cache the result of Diff.evolution() for repeated calls.
`Diff.evolution()` is a fairly expensive operation that can get called multiple times. It performs a diff of two signatures, generating a list of mutations to transform one into the other. This change caches the result of that so multiple calls won't require the work to be repeated. After the initial generation, any future calls are effectively free.
e4afefef4c02fadce3d39aaadd055261be867720
david
  1. Ship It!
  2. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to master (8d60c8f)
Loading...