Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update ancestry to latest 3.0.x #18164

Merged
merged 1 commit into from
Nov 6, 2018
Merged

Conversation

kbrock
Copy link
Member

@kbrock kbrock commented Nov 5, 2018

Point ancestry to the latest version

This fixes an issue in our patch that prevented us from upgrading to the latest version of ancestry.

A number of rails 5.1 and 5.2 bugs have been (and are being) fixed.
This isolates us from running into problems that have already been fixed.

This version of ancestry is backwards compatible to rails 4.x

I deleted parse_ancestry_column as the stock version uses less memory and a tad faster.

ips

label 3.0.5 ancestry_patch
obj.ancestor_ids 212,396.9 i/s 141,636.4 i/s - 1.50x
root.ancestor_ids 333,376.6 i/s 319,555.8 i/s

memsize

label 3.0.5 ancestry_patch
obj.ancestor_ids 480.0 bytes 480.0 bytes
root.ancestor_ids 120.0 bytes 160.0 bytes - 1.33x

objects

label 3.0.5 ancestry_patch
obj.ancestor_ids 8.0 objs 8.0 objs
root.ancestor_ids 3.0 objs 4.0 objs - 1.33x

@miq-bot
Copy link
Member

miq-bot commented Nov 5, 2018

Checked commit kbrock@d2641c9 with ruby 2.3.3, rubocop 0.52.1, haml-lint 0.20.0, and yamllint 1.10.0
2 files checked, 0 offenses detected
Everything looks fine. 🍪


# TODO: delete
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be deprecated instead?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks - done

@@ -62,7 +63,8 @@ def depth

STRING_BASED_KEYS = %i[string uuid text].freeze
def cast_primary_key(key)
if STRING_BASED_KEYS.include?(primary_key_type)
# self.class.primary_key_is_an_integer? ? key.to_i : key
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's this comment for?

@jrafanie jrafanie self-assigned this Nov 6, 2018
@jrafanie jrafanie added this to the Sprint 99 Ending Nov 19, 2018 milestone Nov 6, 2018
Copy link
Member

@jrafanie jrafanie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@jrafanie jrafanie merged commit d5fc0a9 into ManageIQ:master Nov 6, 2018
@kbrock kbrock deleted the new_ancestry branch November 6, 2018 18:58
@kbrock
Copy link
Member Author

kbrock commented Nov 6, 2018

@bdunne thanks for keeping me honest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants