-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move name collision logic to the model
This change moves and formalizes the name collision logic from the factory to the resource model. The following has changed: * Documentation now better matches the factory output. * Collision renaming order is formalized in one place * Order: reserved names (meta), load action, identifiers, actions, subresources, references, collections, and then attributes. * Renaming resource model attributes/methods now happens at model loading time rather than class creation time. The way this works is by creating a mapping of (type, name) tuples to the renamed value, if it exists. Typically this mapping will be very sparse and it's fast to create / access. In practice we currently only have one or two names that collide across all the resource models. Tests have been updated, some of which needed to define proper Botocore shapes as the code now looks more closely at those at model load time.
- Loading branch information
1 parent
5cd57ce
commit 1e05404
Showing
5 changed files
with
200 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.