New lookup plugin: merged_dicts #11153

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
4 participants
@telbizov

telbizov commented Jun 3, 2015

Input: a list of dictionaries (order is important)
Output: a single dictionary with all the keys from the source
dictionaries and values from the last dictionary in the input list which
contained the given key

Rumen Telbizov
New lookup plugin: merged_dicts
Input:  a list of dictionaries (order is important)
Output: a single dictionary with all the keys from the source
dictionaries and values from the last dictionary in the input list which
contained the given key
@telbizov

This comment has been minimized.

Show comment
Hide comment
@telbizov

telbizov Jun 3, 2015

A rewrite of the previously closed #11137. This is my first pull request for ansible so please test thoroughly and comment.

telbizov commented Jun 3, 2015

A rewrite of the previously closed #11137. This is my first pull request for ansible so please test thoroughly and comment.

@telbizov

This comment has been minimized.

Show comment
Hide comment
@telbizov

telbizov Jun 8, 2015

@bcoca now that the feature_pull_request has been added does that mean that it will be merged or there's a process that it needs to go through ?

telbizov commented Jun 8, 2015

@bcoca now that the feature_pull_request has been added does that mean that it will be merged or there's a process that it needs to go through ?

@bcoca

This comment has been minimized.

Show comment
Hide comment
@bcoca

bcoca Jun 8, 2015

Member

just need to review and test on our side, sorry for the delays but we are going through a very large backlog

Member

bcoca commented Jun 8, 2015

just need to review and test on our side, sorry for the delays but we are going through a very large backlog

@telbizov

This comment has been minimized.

Show comment
Hide comment
@telbizov

telbizov Jun 8, 2015

No worries. I understand. Thank you for the update.

telbizov commented Jun 8, 2015

No worries. I understand. Thank you for the update.

@telbizov

This comment has been minimized.

Show comment
Hide comment
@telbizov

telbizov Jun 19, 2015

@bcoca any chance you've had a moment to look at merging this?

@bcoca any chance you've had a moment to look at merging this?

@bcoca

This comment has been minimized.

Show comment
Hide comment
@bcoca

bcoca Jun 19, 2015

Member

it is on my list, also to compare to another request that adds dict support to union/difference/intersection that might overlap with this

Member

bcoca commented Jun 19, 2015

it is on my list, also to compare to another request that adds dict support to union/difference/intersection that might overlap with this

@telbizov

This comment has been minimized.

Show comment
Hide comment
@telbizov

telbizov Jul 7, 2015

Hey @bcoca,

I was wondering if there's any development on this pull request. It has been more than a month. Any ETA?

Thank you,
Rumen Telbizov

telbizov commented Jul 7, 2015

Hey @bcoca,

I was wondering if there's any development on this pull request. It has been more than a month. Any ETA?

Thank you,
Rumen Telbizov

@bcoca

This comment has been minimized.

Show comment
Hide comment
@bcoca

bcoca Jul 7, 2015

Member

sorry, have not had time to come back, its on my short list, but we do have a big backlog we are running through.

Member

bcoca commented Jul 7, 2015

sorry, have not had time to come back, its on my short list, but we do have a big backlog we are running through.

@telbizov

This comment has been minimized.

Show comment
Hide comment
@telbizov

telbizov Jul 7, 2015

Thanks for the reply @bcoca. Since adding my own lookup plugin in ansible 1.9 is broken and doesn't work I can't use this functionality even if I wanted to add my own plugin bundled withing a role. I understand that the bug will be fixed in ansible 2.0 and then I wouldn't need this merged that urgently.

Two questions are on my mind and I'd appreciate if you can comment:

  • What would be a rough ETA on ansible 2.0 release?
  • If you merge this pull request before 2.0 release would the plugin be available in ansible 1.9 as well?

Thank you in advance @bcoca.

Regards,
Rumen Telbizov

telbizov commented Jul 7, 2015

Thanks for the reply @bcoca. Since adding my own lookup plugin in ansible 1.9 is broken and doesn't work I can't use this functionality even if I wanted to add my own plugin bundled withing a role. I understand that the bug will be fixed in ansible 2.0 and then I wouldn't need this merged that urgently.

Two questions are on my mind and I'd appreciate if you can comment:

  • What would be a rough ETA on ansible 2.0 release?
  • If you merge this pull request before 2.0 release would the plugin be available in ansible 1.9 as well?

Thank you in advance @bcoca.

Regards,
Rumen Telbizov

@bcoca

This comment has been minimized.

Show comment
Hide comment
@bcoca

bcoca Jul 7, 2015

Member

new features are only added to new releases, not backported, so the plugin is not planned for 1.9 because of this.

2.0 is expected at end of the month or possibly August, depends on critical bugs more than anything else.

Member

bcoca commented Jul 7, 2015

new features are only added to new releases, not backported, so the plugin is not planned for 1.9 because of this.

2.0 is expected at end of the month or possibly August, depends on critical bugs more than anything else.

@telbizov

This comment has been minimized.

Show comment
Hide comment
@telbizov

telbizov Jul 7, 2015

Thank you for the update.

telbizov commented Jul 7, 2015

Thank you for the update.

@amenonsen

This comment has been minimized.

Show comment
Hide comment
@amenonsen

amenonsen Jul 29, 2015

Contributor

Note that this is related to, but not the same as, the functionality proposed in #7872. I'm not sure I like the idea of this being implemented as a lookup plugin, though. Seems more natural to have a filter that allows you to merge, and then lookup as normal.

Contributor

amenonsen commented Jul 29, 2015

Note that this is related to, but not the same as, the functionality proposed in #7872. I'm not sure I like the idea of this being implemented as a lookup plugin, though. Seems more natural to have a filter that allows you to merge, and then lookup as normal.

amenonsen added a commit to amenonsen/ansible that referenced this pull request Aug 27, 2015

Add a combine filter with documentation
This is based on some code from (closed) PR #7872, but reworked based on
suggestions by @abadger and the other core team members.

Closes #7872 by @darkk (hash_merge/hash_replace filters)
Closes #11153 by @telbizov (merged_dicts lookup plugin)

@abadger abadger closed this in #12078 Aug 27, 2015

@ansibot ansibot added feature and removed feature_pull_request labels Mar 4, 2018

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