/srv/irclogs.ubuntu.com/2011/06/07/#ubuntu-ensemble.txt

niemeyerToday was more difficult than usual.. it's funny how things aggregate around a similar time frame every once in a while00:21
_mup_ensemble/expose-provision-service-hierarchy r265 committed by jim.baker@canonical.com03:30
_mup_Merged upstream expose-watch-exposed-flag03:30
=== jml` is now known as jml
kim0I'm pretty sure ensemble-log and set -eux are not logging for me (by default?) in the install hook13:31
TREllis2013:40
TREllisbah13:40
kim0a ha .. I think I stumbled over a serious bug13:53
kim0Here are the steps to reproduce:13:53
kim0- deploy a formula with an error in its install hook13:53
kim0- state becomes, install_error13:54
kim0- launch debug-hooks 13:54
kim0- launch resolved -r <SU>13:54
kim0- Broken hook is debugged under tmux13:54
kim0- Now "status" mentions state is "installed" not "started"!13:55
kim0Now I get the following traceback http://paste.ubuntu.com/620867/13:55
kim0and issuing add-relation .. doesn't really help move it from state installed13:56
kim0niemeyer: hazmat ^13:56
kim0It seems the state-machine is stuck13:57
niemeyerkim0: Yo14:01
kim0hey :)14:01
niemeyerkim0: Intresting14:02
kim0indeed14:02
kim0any manual way to move it into started ? 14:02
kim0so I can continue writing the tutorial :)14:02
niemeyerkim0: Yeah, it looks like a real bug indeed14:02
kim0cool .. guess I'll just recreate a fresh env14:02
kim0One note 14:03
niemeyerkim0: Let's wait for hazmat.. he's coded that recently, and will likely be able to spot/fix what's up in no time14:03
kim0awesome14:03
kim0I also think the current functionality of fixing a broken hook is seriously lacking14:03
kim0- fix remotely .. retry14:04
kim0- copy to local machine14:04
kim0- upgrade14:04
kim0I wish debug-hooks would just be connected to local hooks dir some how14:05
niemeyerkim0: Hmm.. that's a bit strange.. why?14:06
niemeyerkim0: Oh, for copying?14:06
niemeyerkim0: Remote => local?14:06
kim0and then upgrading 14:06
niemeyerOk, interesting14:06
niemeyerahasenack, sidnei, zaid_h, wrtp: Hi all!15:48
sidneiheya niemeyer15:49
zaid_ho/15:49
wrtphi niemeyer15:52
rockstarIs ensemble going to be put up on pypi?15:53
niemeyerrockstar: Hmm16:00
niemeyerrockstar: I hadn't thought of that16:01
niemeyerrockstar: I guess it's doable, but I'm not sure about what's the real benefit when compared to having the PPA up16:01
niemeyerrockstar: What's your thinking?16:01
rockstarniemeyer, well, you want people other than Ubuntu folk using Ensemble, right?16:02
rockstarIt's kind of odd to say "you can use whatever language you want to write Ensemble formulas as long as you use our OS"  :)16:03
niemeyerrockstar: That sounds good for sure, but our current focus is on Ubuntu obviously16:03
rockstarniemeyer, yeah, for deployment, it's a no-brainer.16:03
niemeyerrockstar: Ah, I see what you mean16:03
rockstarBut for the ensemble controller, it'd be nice to use what you want.16:03
niemeyerrockstar: Yeah, that sounds nice indeed16:03
rockstarThe reason I ask is that I have people at the local LUG asking if I could give a demo at next month's meeting, so I wanted to know about usage.16:04
niemeyerrockstar: Cool16:04
rockstarniemeyer, I'd be happy to submit patches for any bugs I find on other OSes.16:04
niemeyerrockstar: It shouldn't be hard, actually16:04
niemeyerrockstar: Ensemble is really just a Python library at this point, with a tiny executable wrapper16:05
rockstarniemeyer, it seems relatively ready for pypi, that's why I asked.16:05
niemeyerrockstar: The dependencies are likely the boring part, though16:05
rockstarIt didn't seem like a technical barrier, so I wondered if there were principle issues.16:05
niemeyerrockstar: I mean, I'm not sure python-zookeeper exists there, for instance16:05
rockstarniemeyer, there's txzookeeper16:05
rockstarI don't know if that's the same thing.16:05
niemeyerrockstar: Yeah, but that's an easier one16:05
niemeyerrockstar: That's a Python-only wrapper for Twisted16:06
niemeyerrockstar: It still needs python-zookeeper on the backend16:06
rockstarAh.16:06
rockstarI know txAWS is.16:06
niemeyerrockstar: That's helpful already, and it's "the real thing"16:08
jimbaker`rockstar, fwiw, i used to run the entire test suite on mac os - there was only one minor bug, around a small diff in how temp files are named16:23
jimbaker`i didn't really look into it, but i  believe it was purely a problem in the test16:24
kim0hazmat: Hi .. are you there 16:27
* niemeyer heads to lunch16:28
kim0hazmat: just pinging you to check the bug I had reported earlier today, ping me if you have any questions16:28
hazmatkim0, yeah16:43
* hazmat pokes16:43
kim0cool 16:43
=== deryck is now known as deryck[lunch]
_mup_ensemble/resolved-install-should-start r240 committed by kapil.thangavelu@canonical.com17:05
_mup_on retry install (with or without hooks) use a success transition id to automatically transition to started.17:05
hazmatkim0, is there a bug reported for the issue you mentioned earlier?17:07
_mup_Bug #794129 was filed: install hook error, does not transition to start after resolved <Ensemble:New> < https://launchpad.net/bugs/794129 >17:09
hazmatthere is now ;-)17:10
kim0hazmat: cool :) yeah I hadnt opened one17:12
hazmatkim0, cool, the fix is in the review queue now17:12
kim0hazmat: oh that fast! awesome :)17:12
hazmatkim0, TDD ftw17:13
kim0niemeyer: Just linked a rewrite of the formula writer's tutorial to bug 78825517:14
_mup_Bug #788255: Ensemble needs a tutorial for writing a formula <Ensemble:In Progress by kim0> < https://launchpad.net/bugs/788255 >17:14
kim0would be great if you could review it soonish, since I think I'll need to refer to it soon in a blog post17:14
kim0thanks a lot17:14
* hazmat admires steve job's reality distortion field17:26
hazmatthe truth is in the cloud.. the cloud, it just works..17:27
* niemeyer waves17:32
niemeyerhazmat: Yeah :-)17:32
niemeyerCloud just got 30% more hyped17:33
SpamapSSo.. plugins.. agents..17:33
hazmatSpamapS, plugins.. cli or agent?17:34
SpamapSI've been thinking about how mcollective works.17:34
SpamapSAnd how easy that would be to add to ensemble.17:34
hazmatSpamapS, agent side plugins then17:34
SpamapSyes17:34
SpamapSensemble agent-plugin --service=wki-db --plugin=mysql-cmd "FLUSH LOGS"17:35
hazmatSpamapS, that would be nice, but we'd have to some dynamic dispatch to allow ready overriding of behavior for fully pluggable.. else we can manage them as some sort of collection of objects with lifecycle, which work if their mostly independent from existing functionality and using a watch based protocol17:36
SpamapSI mean, we have an agent, with an event driven comm channel to it. We should be able to use it to run stuff. :)17:36
SpamapShazmat: again, eep op glorp glok.. I am sorry that I don't understand the internals of ensemble better by now. How you do it is very interesting to me, but even more is, how feasible is it?17:37
hazmatSpamapS, its quite feasible.. we have most of the building blocks available, we could isolate the plugins to separate processes if we want.17:38
SpamapSWe could just say nah we're not going to do that, but then we need to help people setup mcollective or parallel-ssh or something to do these things.17:38
niemeyerSpamapS: We have to look at a few different use cases to see what would be the right thing to do17:39
niemeyerSpamapS: Flushing logs, for instance, sounds like something we'd want in the agent itself default17:39
niemeyers/default/by default/17:39
hazmatniemeyer, then it would need to be formula driven.. the agent is agnostic17:39
niemeyerhazmat: Log management sounds like a pretty general problem17:40
hazmatoh.. i guess a generic log flush is feasible17:40
SpamapSniemeyer: flushing the mysql logs?17:40
hazmatniemeyer, indeed, definitely also puts us pretty close into policy land in the agents17:41
niemeyerSpamapS: Flushing the X logs17:41
niemeyerSpamapS: Where X is whatever is running in the machine17:41
hazmatwhere do the logs go, what log values do we relay. do we have an alert/event engine feeding on the logs.. etc17:41
SpamapSWe can't possibly know everything that every formula will want to expose to users on an arbitrary basis. In cassandra, there's DB compaction, log flushing, offlining for upgrades..17:41
SpamapSI do like the idea of being able to provide arbitrary hooks in formulas17:42
niemeyerSpamapS: DB compaction is formula business.. log flushing is a generic problem we can tackle on the agent.. offlining for upgrade is formula business to17:42
niemeyers/to/too17:42
SpamapSniemeyer: DB compaction happens when the admin wants to do it for Cassandra... 17:42
SpamapShow would formulas do that now?17:43
niemeyerSpamapS: Sounds like a setting17:43
hazmatSpamapS, cron job from setting17:43
SpamapSno no no no cron!17:43
niemeyerSpamapS: ensemble set run-compaction=true17:43
hazmat:-)17:43
SpamapSniemeyer: THAT I like17:43
hazmatyeah.. cassandra has lots of knobs that it wants to expose the admin, that need to be turned in the right order17:43
SpamapShazmat: while standing on the right foot17:44
hazmatniemeyer, with the flag being cleared post  compaction?17:44
SpamapSCassandra and Jenkins are both going to need a lot of the same knobs for the JVM .. I've been wondering about shared code.17:44
niemeyerhazmat: Yeah, possibly17:45
SpamapSUltimately I'd want feedback from that setting.17:45
SpamapSnot necessarily from the 'set' command, but somehow I need to be able to know that it ran and failed/succeeded17:45
hazmatSpamapS, i think we need some notion of hook inheritance.. it more tightly couples the formula namespace and inter formula deps.. but i dislike pushing down every hook into all formulas17:45
niemeyerhazmat: It sounds like we can introduce a specific type of setting for that kind of flag 17:45
niemeyerSpamapS: Agreed17:45
niemeyerSpamapS: What kind of feedback?17:45
hazmatniemeyer, perhaps.. alternatively we have some sort of service agent (not unit) that can operate on a wholistic service view17:46
niemeyerhazmat:  Agreed, except s/sinheritance/composition/17:46
hazmatie. do round robin upgrades, rolling upgrades, clear the compact flag after its done on all units17:46
niemeyerhazmat: Hooks are scripts, it's trivial to bundle a package with things for well known activities17:46
hazmatniemeyer, indeed, it is composition17:46
SpamapSYeah I was thinking that a simple ensemble-formula-helpers package would do nicely17:47
SpamapSthink debhelper. :)17:47
niemeyerhazmat: Rather than clearing the flag, it feels like it should be a timestamp based setting17:47
hazmatits convience and reuse, one hook copy to edit, vs. 30 if your upgrading/changing a  behavior17:48
niemeyerhazmat: Something resembling this: ensemble set ... compact=now17:48
hazmatniemeyer, sounds good re set17:48
niemeyerhazmat: So each unit can observe the setting, and tell if it should compact or not17:48
niemeyerhazmat: No races, etc17:48
niemeyerno need to reset too17:49
SpamapSlike just have the formula's setting hook call /usr/share/ensemble/helpers/hooks/jvm_settings .. 17:49
hazmatniemeyer, if we don't reset to reflect current state, then we have a temporal disconnect for a unit coming back online or new unit.. that wouldn't nesc. need compaction17:50
niemeyerSpamapS: Yeah!  Man, it's neat that this would just work..17:50
niemeyerSpamapS: I mean, in the sense that the helper will have the environment17:50
SpamapSyep17:50
niemeyerhazmat: sorry, I actually meant compact=`date`17:50
SpamapSkeeping it simple and clear means more people will make use of them17:51
niemeyerhazmat: Not with that syntax, of course, but that's the idea17:51
hazmatniemeyer, cool, but even then you need coordination by something external to the units17:51
niemeyerhazmat: Hm?17:51
hazmatyou don't want to compact on your cassandra cluster in parallel17:51
hazmatyou do it piecemeal because your putting an additional load on your data store17:51
niemeyerhazmat: That's up to the formula to coordinate internally.. that's the kind of thing we have peer relations for17:51
hazmatthey can either coordinate or be coordinate by an external actor17:51
SpamapSas long as hooks can change the settings they've been given, that should be fine17:52
hazmatniemeyer, true17:52
niemeyerhazmat: We can help, of course, but as far as the "how do I tell things should happen", the setting system should be a good start17:52
_mup_ensemble/expose-provision-service-hierarchy r266 committed by jim.baker@canonical.com17:53
_mup_Need more robust ending assertions that don't eventually fail with pending deferreds, but non edge case code now works properly with new stateful semantics for watch_exposed_flag17:53
niemeyerSpamapS: It doesn't have to change the _settings_, I think we shouldn't allow it to, but there are ways it can store and relay information (peer relations, etc)17:54
SpamapSOne thing that mcollective has that this wouldn't give me, that sysadmins *love* is that the output of the agents can be structured and piped so admins can do their grep/sed/awk magic with the data returned.17:54
niemeyerSpamapS: The idea so far is to reserve the settings framework for human interaction17:54
SpamapSniemeyer: the run-compaction=1 thing would then run compaction on adding unit though, would it not?17:58
niemeyerSpamapS: Yeah, we should add an easier way as discussed with hazmat above.. we could have something equivalent to run-compaction=`date` 17:59
niemeyerSpamapS: So units can compare the timestamp17:59
niemeyerSpamapS: and tell if they're supposed to compact or not17:59
SpamapSsounds like we need a "message to the unit" interface not a "set a setting" interface17:59
niemeyerSpamapS: This also solves a number of other issues.. e.g. which units have already compacted?  What if I ask to compact again?  etc17:59
niemeyerSpamapS: "set a setting" is effectively a "message to the unit" interface18:00
niemeyerSpamapS: With the advantage that messages are not lost18:00
niemeyerSpamapS: Nor duplicated, etc18:00
SpamapSthat can make it more complex too since sometimes you mean "send it to the service" and sometimes you mean "send it to the units that exist now"18:01
niemeyerSpamapS: "the service" in this sense is an abstract concept18:01
niemeyerSpamapS: Communication will always take place with the underlying units18:01
niemeyerSpamapS: I get your point, though, I think.. one has to understand how it works18:02
niemeyerSpamapS: That said, this would likely be true either way..18:02
niemeyerSpamapS: E.g. how to tell all units they have to compact, but they should do so one at a time, etc18:03
niemeyerSpamapS: Whatever system we invent for facilitating this will still need some understanding of the issue at hand by the formula author18:03
SpamapSdefinitely.. I'm sure it will remain as simple as the other bits of the formula too. :)18:04
niemeyerSpamapS: Yeah, hopefully we'll evolve to that :)18:08
=== deryck[lunch] is now known as deryck
niemeyerWe have a _gigantic_ review queue on Ensemble..18:24
niemeyerThat's _awesome_.. :-)18:24
niemeyerJust finishing some Go packaging work to upgrade to the latest weekly, and will do a full round.18:24
_mup_ensemble/trunk-merge r223 committed by kapil.thangavelu@canonical.com18:42
_mup_merge trunk18:42
_mup_ensemble/auto-dependency-spec r224 committed by kapil.thangavelu@canonical.com18:45
_mup_merge auto dep resolution spec18:45
_mup_ensemble/trunk r241 committed by kapil.thangavelu@canonical.com18:53
_mup_merge auto-dependency-resolution prototype [r=niemeyer][f=777816]18:53
_mup_An auto resolution algorithm implementation for deployment of18:53
_mup_dependent formulas and relations with constraints satisified from both18:53
_mup_repository and environment.18:53
_mup_ensemble/trunk r242 committed by kapil.thangavelu@canonical.com18:57
_mup_merge ensemble-deploy-auto-resolve prototype [r=niemeyer][f=788735]18:57
_mup_Integration of auto dependency resolution of formulas and relations 18:57
_mup_into the deploy cli.18:57
_mup_ensemble/trunk r243 committed by kapil.thangavelu@canonical.com18:59
_mup_remove auto dependency resolution functionality, pending repository work, left in history for future ref.18:59
_mup_ensemble/expose-provision-service-hierarchy r267 committed by jim.baker@canonical.com19:03
_mup_Ensure test_watche_services does not tear down until exposed service watches have been observed to raise StopWatcher19:03
hazmatniemeyer, bcsaller, jimbaker` standup?19:08
niemeyerDo we need one today?19:08
jimbaker`hazmat, sure19:08
niemeyerI'm a bit behind myself, and feel slow in the last couple of days19:08
hazmatniemeyer, i'm good without19:08
jimbaker`no need on my part - i'm just reworking the timing issues introduced by the new stateful api for watch_exposed_flag19:09
hazmatjimbaker`, bcsaller any blockers or other stuff you guys want to talk about today?19:09
niemeyerIf there are no important topics to sync upon/figure out, I'd prefer to keep hacking/reviewing/etc19:09
jimbaker`was slow going this morning, but now i'm making good progress19:09
jimbaker`in fact, excellent progress, so would like to focus on it19:09
hazmatyeah.. me too19:09
bcsalleryeah, I just need to finish what I'm working on19:09
hazmatall right.. tomorrow then19:09
niemeyerSuper19:10
_mup_ensemble/expose-provision-service-hierarchy r268 committed by jim.baker@canonical.com19:17
_mup_Looping on all tests except test_watch_service_changes_removed_services, which needs to take in account new semantics19:17
_mup_ensemble/expose-provision-service-hierarchy r269 committed by jim.baker@canonical.com19:24
_mup_Fixed last test for new semantics19:24
_mup_ensemble/security-specification r240 committed by kapil.thangavelu@canonical.com20:21
_mup_security overview and todo spec draft20:21
niemeyerOkay.. packages out of the way.. will step out for a moment and come back to that review queue20:22
niemeyerhazmat: What was the outcome of our debate about the db-relation-joined issue on mysql again?20:57
niemeyerhazmat: The one re. the fact it wasn't updating on re-joins20:57
hazmatniemeyer, that the formula hook should check if credentials are already set on its relation, and if not it should create them, even if the db exists20:58
niemeyerhazmat: Ah, with the relation id thing, ok20:59
niemeyerhazmat: Thanks20:59
hazmatniemeyer, np20:59
_mup_ensemble/trunk r244 committed by gustavo@niemeyer.net21:10
_mup_Merged fix-mysql-example-formula-publish-details-precreated-databases branch21:10
_mup_[a=kim0][r=niemeyer]21:10
_mup_This enables reusing the same example mysql formula multiple times21:10
_mup_when deployed.21:10
_mup_The proper way to fix this is actually to use a database named after the21:10
_mup_relation id, and then create a new database on every new relation id we21:10
_mup_get.  The problem is that we currently don't offer such a relation id for21:10
_mup_the hooks, so this will do for now.21:10
SpamapSre the formulas re-creating credentials.. the principia mysql formula touches a flag file when the relation is broken, and revokes the credentials at that time. When the flag is present, or database is missing, it creates new credentials.21:59
SpamapSIt has an additional check if its a slave since the db will be present but the credentials will be wrong in the db and need updating.21:59
_mup_ensemble/trunk r245 committed by gustavo@niemeyer.net22:34
_mup_Merged micro-is-sluggish branch [r=hazmat]22:34
_mup_This changes the default instance type on EC2 to m1.small.22:34
_mup_ensemble/expose-provision-service-hierarchy r271 committed by jim.baker@canonical.com22:46
_mup_Additional cleanup re removing unnecessary observers22:46
_mup_ensemble/trunk r246 committed by gustavo@niemeyer.net22:50
_mup_Merge write-formula-tutorial branch [a=kim0] [r=niemeyer]22:50
_mup_Yes, a formula writing tutorial!22:50
kim0_mup_: are you being sarcastic :D22:53
niemeyerkim0: Not at all.. :-)22:54
niemeyerkim0: Something important we were lacking22:55
kim0hehe  cool then :)22:55
_mup_ensemble/config-set r240 committed by bcsaller@gmail.com23:37
_mup_merge trunk23:37

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!