/srv/irclogs.ubuntu.com/2011/05/30/#ubuntu-ensemble.txt

kim0Morning everyone08:58
SpamapShrm.. laying around w/ ensemble.. it seems like hooks on two machines in a service are being triggered for eachothers' events14:19
SpamapSs/laying/playing/ :p14:19
niemeyerGood morning!14:24
SpamapSniemeyer: hello there, I have a very interesting situation that I'm trying to debug..14:25
niemeyerSpamapS: Cool, let's see14:25
SpamapSwhich may be interrupted by my 20 month old wakign up :-P14:25
SpamapSniemeyer: basically, I am seeing the data from demo-wiki/2's relationship when I run 'relation-get' on demo-wiki/114:26
niemeyerSpamapS: Hmm14:27
SpamapSniemeyer: its as if the modified state is getting propagated to all service units14:27
SpamapSniemeyer: I think I have a reproducible test case14:27
niemeyerSpamapS: Ah, that's awesome14:27
SpamapSbtw, debug-hooks is *amazing*14:28
niemeyerSpamapS: Is there a chance I could get access to the environment's zk machine?14:29
niemeyerSpamapS: Just to have a look at the state14:29
niemeyerSpamapS: It's nice isn't it14:29
niemeyerSpamapS: Feels like gdb for formulas :)14:29
SpamapStotally14:30
SpamapSniemeyer: I think this is easily reproducible w/ the example formulas14:30
SpamapStrying that right now14:30
niemeyerCool14:30
niemeyerLet me know the steps and I'll run through it14:30
SpamapSahh ok so its not exposed by the example formulas because the example mysql formula sends the same user/pass to all service units in the relation14:38
SpamapSok so here's where I may just not understand relation-set and relation-get ...14:40
SpamapSI thought that relation-set and relation-get were each reading/writing into an area unique to the two service units...14:41
SpamapSso if   mysql/0 relation-set's with ENSEMBLE_REMOTE_UNIT=wordpress/1 .. thats a set of data unique to wordpress/1 and mysql/0's relationship14:42
SpamapSniemeyer: ^^ is my assumption false?14:43
SpamapSits been a while since I read the spec14:43
niemeyerSpamapS: It's no14:44
niemeyert14:44
SpamapSso that confuses me then as to how the example mysql formula can work.. as it exits if the database exists14:45
SpamapSwithout ever having done a relation-set14:45
niemeyerSpamapS: If you don't provide additional arguments, and do a relation-set with a=b, that's specific to the involved units only14:45
SpamapSniemeyer: ok, so the steps to reproduce what I'm seeing as wrong behavior are as follows:14:48
SpamapSbzr branch lp:principia-tools && cd principia-tools && scripts/getall && tests/mediawiki.sh14:49
SpamapSniemeyer: this assumes a bootstrapped environment14:49
SpamapSniemeyer: the failure is that both demo-wiki's will receive eachothers' usernames in db-relation-changed at some point14:50
SpamapScausing them to fail14:50
SpamapSnote that this wil spawn about 7 machines. ;)14:50
SpamapSyou can probably reduce it down by removing the memcached stuff14:50
niemeyerSpamapS: No worries.. I'll go through it in a moment14:51
niemeyerSpamapS: Nah, it'll be nice to see it churning ;)14:51
SpamapSniemeyer: much appreciated. I'll be in and out today, as its a U.S. holiday, but this one has been *killing me* this weekend. ;)14:51
SpamapSso I'll check in as much as possible14:51
niemeyerSpamapS: Ouch, sorry to hear it.. we'll get whatever is happening fixed14:51
SpamapSI'm kind of hoping whats broken is my assumptions.14:52
SpamapSI'm afraid I've churned a bit on it so the formulas are kind of ugly at the moment. :-P14:52
niemeyerSpamapS: Your basic assumption is sane/right, at least14:58
SpamapSon a side note... I wonder if we should make an environment config option to keep from putting all the aws machines' host keys in .ssh/known_hosts ... 15:27
SpamapSI've spun up and down enough nodes, I get conflicts about 1 in 2015:27
kim0Any way to remove "Front Page" from first line of https://ensemble.ubuntu.com/FrontPage :)15:43
koolhead17replace it with startpage15:48
koolhead17:)15:48
koolhead17hey hazmat niemeyer obino15:48
niemeyerSpamapS: Yeah, feels like we should do something on that area indeed 15:50
SpamapSniemeyer: so if I were following the example formulas that exist now, I would believe that one relation-set feeds all units in a service.15:50
niemeyerkoolhead17: Hey there!15:50
niemeyerSpamapS: Why?15:51
SpamapSniemeyer: because db-relation-changed in the mysql formula only ever runs relation-set once per service15:51
SpamapSniemeyer: once the database has been created and relation-set has been run, it just silently exits15:51
SpamapSer.. db-relation-joined actually15:51
SpamapSniemeyer: and in fact, this works beautifully, properly feeding that data to all units of wordpress when related15:52
niemeyerSpamapS: I'm not sure I understand what you're saying15:54
niemeyerSpamapS: Looking at db-relation-joined, why would it run only once per service?15:54
niemeyerSpamapS: Oh, hmm, I think I see what you mean15:55
niemeyerSpamapS: Feels like there's something catchy there indeed15:56
niemeyerSpamapS: The database doesn't have to be created, but the relation settings should be piped through15:57
SpamapSniemeyer: its as if relation-set is a broadcast channel16:00
niemeyerSpamapS: Yeah, this is certainly bogus16:00
SpamapSit didn't break until I added ip restrictions to the grants in the principia mysql formula16:01
niemeyerSpamapS: It must be something minor, though.. I'm sure the concept was well understood the whole time16:01
niemeyerSpamapS: We even have a parameter on relation-set when one wants to change info on a separate relation unit, for instance16:01
SpamapSright16:02
SpamapSin fact, I wonder if I explicitly state the remote unit if this goes away16:02
niemeyerSpamapS: No, the default remote unit is the one you expect16:03
niemeyerSpamapS: E.g. db-relation-joined will set the default remote unit to the joining unit16:03
SpamapSactually, relation-set doesn't take a unit16:06
SpamapSnot from the cli options at least16:07
kim0hmm so after the principia changes, what should I branch to work on a new formula16:08
niemeyerSpamapS: Aw.. man, I think I'm doing a big confusion..16:09
niemeyerSpamapS: I'm mixing relation-get and relation-set16:09
niemeyerSpamapS: relation-get is the one that will look at the remote unit's data16:10
niemeyerSpamapS: relation-set is always local16:10
niemeyerSpamapS: So it changes the settings of "self", if you see what I mean16:11
niemeyerSpamapS: and the other units will be notified of the change16:12
niemeyerSpamapS: So it's working as intended, but not as I pointed out earlier16:12
niemeyerSpamapS: You can think of it the following way: every unit in a relation has bucket with their own settings.16:14
niemeyerSpamapS: relation-set always changes the local bucket16:14
niemeyerSpamapS: relation-get can retrieve settings from the bucket of any other unit within this relation, and defaults to the remote unit the event is running for16:14
niemeyerSpamapS: The documentation and examples may be helpful: https://ensemble.ubuntu.com/docs/formula.html#hook-tools16:16
SpamapSso I can't give each remote unit its own unique configuration? :(16:18
SpamapSbummer I was kind of excited to be able to restrict each username/password to each unit16:19
SpamapSbut it makes perfect sense, and is easy to correct16:19
SpamapSthe key "aha" btw, is "relation-set is always local"16:20
SpamapSniemeyer: well it takes away a tiny thing I was trying to do, but it simpliefies the formulas, so my :( is turned around to :)16:21
niemeyerSpamapS: Knowing that design, you actually can if you really want to16:22
SpamapSThe idea was simply that the units could be isolated from one another for greater security16:23
niemeyerSpamapS: Ah, I see16:23
SpamapSbut, there are other ways to achieve that16:23
niemeyerSpamapS: Right.. we have to consider further the security details intra-relations16:23
SpamapSit was, I was thinking, a target of opportunity.. not something I see as key to formulas working16:23
SpamapSI think given that the service units will be largely identical, its ok to treat them all as equals and just isolate the service from other services, not the units from eachother16:24
niemeyerSpamapS: Right, this is likely the initial direction we'll go into16:25
niemeyerSpamapS: In some cases it may actually be important to know details from other relations as well16:25
niemeyerSorry16:25
niemeyerSpamapS: I mean from other units16:25
niemeyerSpamapS: But, if we really want to, the current design doesn't make it impossible to do the isolation you mention16:25
niemeyerSpamapS: Internally, that is16:25
SpamapSsure, right now though, being able to assume that there is only one bucket per relation-set, allows me to delete a lot of code :)16:26
niemeyerSpamapS: The conventions we build on it might make it hard, though.  IOW, people may well start depending on the fact they can see other unit's settings in useful cases.16:26
niemeyerSpamapS: Sweet, that sounds like a good feature then ;)16:26
* SpamapS <heart> /^-/ in diffs16:27
niemeyer+116:28
* niemeyer lunch!16:35
SpamapSahh yes, deleting code to make things work is always refreshing16:52
SpamapSkim0: nice job on the ensemble text. :)16:55
kim0SpamapS: oh cool ! 16:55
kim0SpamapS: thanks .. I could really use some tweak ups from a native speaker16:55
kim0SpamapS: is there a short couple of commands to branch principia and work on a new formula16:58
kim0if it's longish .. It's not urgent16:59
* kim0 is taking a first shot at writing a new formula17:00
SpamapSkim0: I haven't gone through it with a fine toothed comb, but the bullt points portray what I think we all want to portray17:13
* kim0 nods .. cool17:14
kim0n00b question, when I do ensemble add-relation mywiki mymemcached, assuming both mywiki and mymemcached have TWO service units deployed .. does Ensemble hook them up one memcache per mywiki, like I think it should ?17:16
SpamapSerr17:21
SpamapSkim0: mywiki's units will all be related to mymemcached's units17:21
* niemeyer waves17:49
niemeyerkim0: The documentation feels like going in a good direction, but I'm not sure the front page should hold that description17:56
kim0o/17:56
kim0shoot17:56
kim0what's your thinking17:56
niemeyerkim0: The feeling I have when opening the page is that I have to read a lot to grasp what Ensemble is17:57
niemeyerkim0: In a sense, it feels like the first two or three questions in the FAQ would be a good introduction: https://ensemble.ubuntu.com/docs/faq.html17:58
kim0there's a short version and a long one especially for that 17:58
kim0hmm17:58
kim0perhaps there should be some graphic separating the two17:58
niemeyerOr, actually, the whole FAQ is probably the front page :-)17:58
niemeyerOr rather a seed fo rit17:58
niemeyerfor it17:58
kim0niemeyer: I think the text looks a bit too much, just because it's a lot of text17:59
SpamapSniemeyer: ok the test I gave you before passes now.. :) thanks for clarifying, time to BBQ!17:59
* SpamapS disappears17:59
kim0probably adding a nice graphic make it easier on the eye 17:59
niemeyerSpamapS: Sweet, have fun there17:59
kim0but I don't think we should remove much of it .. 18:00
niemeyerkim0: Well, it feels like a lot of text because it is a lot of text.. :-)18:00
kim0I could just leave titles for bullets, and link the denser text in another page of course18:01
niemeyerkim0: We can certainly keep some of it18:01
kim0like the 5 bullets, would just be 5 lines18:01
kim0with the longer version linked to18:01
niemeyerkim0: I actually like the points below18:01
kim0niemeyer: so what part should not be there ?18:02
niemeyerkim0: Perhaps the at-a-glance idea is that needs some love18:02
niemeyerkim0: Reading this, for instance:18:02
niemeyer"""18:02
niemeyerEnsemble is a novel cloud orchestration framework. It lets you deploy, manage and scale software services on the cloud and soon physical servers. Ensemble uses "formulas" to capture the intelligence of managing deployments. If you want a piece of software on the cloud, "there's a formula for that!" The Ensemble community is working towards that goal!18:02
niemeyer"""18:02
niemeyerkim0: It feels very hyped, but without any hints at all regarding what it *actually* does18:02
niemeyerkim0: I can replace Ensemble by any other configuration management product name, and it remains true18:03
kim0but that's what marketing is all about eh :)18:03
niemeyerkim0: I'm not a marketing guy18:03
niemeyer:)18:03
kim0mmm18:03
niemeyerkim0: I think we should take pieces of the FAQ and insert above as an introduction18:04
kim0niemeyer: well .. that paragraph will be replaced with whatever Gerry and everyone agrees on18:04
kim0to be the standard intro paragraph to Ensemble18:04
kim0this is just a placeholder18:04
niemeyerkim0: Absolutely, but it's live right now, and I'd like to have something nice there18:04
niemeyerkim0: What do you think of having our FAQ entries as an introduction, and maintaining the large paragraph there as a more in-depth look?18:05
niemeyers/large paragraph/large section/18:05
kim0generall it's absolutely fine :)18:06
kim0ok maybe it's indeed too hype packed18:06
kim0k, I'll edit it18:07
niemeyerkim0: Thanks a lot18:07
kim0rock n roll18:08
* niemeyer plays with packages19:28
niemeyer... and everything seems to work.. sweet!19:28
niemeyerkim0: When are you planning to run the refactoring?20:25
niemeyerkim0: In the front page, that is20:26
niemeyerkim0: I want to put some basic information up regarding the packages20:26
kim0I'm held up in real life for a couple of hours20:26
kim0if you'd like to change something go ahead ..20:26
kim0I may not be able to change it before the morning20:27
kim0niemeyer: is that ok ?20:27
niemeyerkim0: Cool, no worries20:28
kim0okie great20:28
niemeyerkim0: Tweaked20:45
niemeyerkim0: Please let me know what you think20:45
kim0great .. thank you20:45

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