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

Do block until ready for cs_property flush #170

Merged
merged 1 commit into from
Dec 2, 2015
Merged

Do block until ready for cs_property flush #170

merged 1 commit into from
Dec 2, 2015

Conversation

bogdando
Copy link
Contributor

@bogdando bogdando commented Nov 2, 2015

No description provided.

@roidelapluie
Copy link
Member

we should really check only ONCE for all the flushes .... not one time per type

@bogdando
Copy link
Contributor Author

bogdando commented Nov 3, 2015

@roidelapluie makes sense, thank you

@roidelapluie
Copy link
Member

But how could we implement that? cc @ffrank @igalic

@igalic
Copy link
Contributor

igalic commented Nov 7, 2015

@roidelapluie from my limited knowledge, it's practically impossible…
@ffrank should know more (i.e.: why ;)

but the opsview t&p's suffer from a similar issue, making them restart opsview/nagios for every added configuration item…

@ffrank
Copy link
Contributor

ffrank commented Nov 11, 2015

This issue is rooted pretty deeply iirc, and we're indeed not the only ones facing it.

I don't think that there is currently a life-cycle hook with a semantics of "do this once all resources of type/with provider X are finished" or even "do this after all resources are synchronized". But this is the kind of situation where we would really like to have that.

I'll do some digging when I get a chance. Would anyone ping me again? I just burned the github notification ;-)

@roidelapluie
Copy link
Member

Ping @ffrank

@ffrank
Copy link
Contributor

ffrank commented Nov 17, 2015

Thanks @roidelapluie. And guess what, I just found a thing: post_resource_eval could be just adequate.

It is called by the transaction code, so this documentation is not necessarily outdated. I suggest giving that hook a shot.

It's a public API, but please note that as of Puppet 4.3, there does not seem to be a core provider that actually uses it. A quick walk through the git history does not indicate that anything ever did. YMMV ;-)

@bogdando
Copy link
Contributor Author

Folks, I lost a track of this discussion. What about the suggested change? The block until ready actually is not a resource consuming operation, AFAICT. And it "grants" your changes a safe commit window to make it into the CIB. Thus, it is better to have it than not

@ffrank
Copy link
Contributor

ffrank commented Nov 27, 2015

I guess we could merge this and open an issue in order to move the flush functionality to the provider hook instead, later.

In light of this, I also figure we could even neglect test code. Thoughts @igalic, @roidelapluie?

@roidelapluie
Copy link
Member

👍

@ffrank
Copy link
Contributor

ffrank commented Dec 2, 2015

Tracking this in #173 and merging this.

Thanks for the contribution @bogdando !

ffrank added a commit that referenced this pull request Dec 2, 2015
Do block until ready for cs_property flush
@ffrank ffrank merged commit 44b4ef2 into voxpupuli:master Dec 2, 2015
@igalic
Copy link
Contributor

igalic commented Dec 2, 2015

\o/

@roidelapluie roidelapluie modified the milestone: 1.0.0 Mar 14, 2016
@bogdando bogdando deleted the fix_flush branch March 14, 2016 14:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants