/srv/irclogs.ubuntu.com/2012/06/25/#juju-dev.txt

fwereadeheya TheMue09:07
TheMuefwereade: Hi09:24
TheMuefwereade: Phew, it's raining cats and dogs here.09:24
fwereadeTheMue, it's pretty hot here09:25
fwereadeTheMue, we're just approaching the too-damn-hot point of the year09:25
fwereadeTheMue, give me a few days and I'll be begging for a decent rainstorm :)09:25
* TheMue dcc's fwereade some rain.09:26
fwereadeTheMue, :)09:26
fwereadeTheMue, so how's it going? I hope the format 2 stuff isn't too much of a hassle -- I feel like I maybe should have done it myself, but I got caught up in the relations and I felt it was getting pretty important09:27
TheMuefwereade: I'll do firewall first, then format 2.09:29
fwereadeTheMue, ah, excellent09:29
fwereadeTheMue, are we going with the security groups style or are we doing it properly this time?09:30
TheMuefwereade: I'm talking about todays firewall.py in state. security and auth will be handled later.09:31
fwereadeTheMue, ah cool09:31
TheMuefwereade: firewall is used by the PA.09:31
TheMuefwereade: So I'm moving it out of state to cmd.09:32
* fwereade suddenly gets suspicious09:32
* fwereade goes to read code a mo09:32
fwereadeTheMue, doesn't implementing that presuppose the security groups approach?09:33
TheMuefwereade: As far as I've seen yet not.09:33
TheMuefwereade: But I've just started.09:34
fwereadeTheMue, it seems to me that if the PA is going to use it, then we're assuming that the PA will remain responsible for opening/closing ports09:34
fwereadeTheMue, a proper solution using firewalls on the units surely shouldn't involve the PA at all?09:35
TheMuefwereade: Sorry, don't know.09:36
fwereadeTheMue, blast, wish niemeyer was on09:36
TheMuefwereade: So how would your solution look like?09:37
fwereadeTheMue, unit agent messing with iptables, rather than PA messing with the provider09:38
fwereadeTheMue, we've certainly talked about our use of security groups being a serious problem, and about the need for a cross-provider firewall solution09:38
TheMuefwereade: Pls go on ...09:39
fwereadeTheMue, but it would not necessarily be *irrational* for us to go with the tried, tested, known-working-at-small-scale solution (given the time constraints that are starting to wear at me slightly)09:40
fwereadeTheMue, the problems with security groups are (1) aws is really not designed to handle what we're doing with them and (2) the solution only works for aws09:41
fwereadeTheMue, (2) is not important wrt our critical short-term goals09:41
fwereadeTheMue, but disregarding (1) feels like the sort of decision that we should get some sort of consensus on before writing code that presupposes it09:42
fwereadeTheMue, s/presupposes it/presupposes that approach/09:42
TheMuefwereade: That are worries, ok, but how would a proper solution look like?09:43
fwereadeTheMue, I'm afraid I don't have a clear idea of the *precise* problem with our use of security groups... just that we're not meant to use any, and an apocryphal amazon engineer was said to look somewhat horrified by the prospect :)09:44
fwereadeTheMue, I think it comes down to the *unit* agents watching the ports that should be open in their container and taking charge of it themselves09:44
fwereadeTheMue, we'd still need *some* security groups, but probably just 2: one for PA machines and one for everything else09:45
fwereadeTheMue, make sense?09:45
TheMuefwereade: Yep, so far understandable.09:46
=== wrtp is now known as rogpeppe
TheMuerogpeppe: Hey, you are not here. ;)09:46
rogpeppeTheMue: that's right. i'm an invisible ghost.09:46
rogpeppeTheMue: i've been given special dispensation :-)09:47
TheMuerogpeppe: Ah, ok, then it's ok.09:47
fwereadeTheMue, that's pretty much it...09:47
fwereaderogpeppe, heyhey09:47
rogpeppefwereade: yo!09:47
fwereaderogpeppe, are you aware of any official preference as to how we implement firewalling this time round?09:47
rogpeppei seem to remember we've got a meeting scheduled in 13 minutes, so i thought i'd try and turn up for it...09:47
rogpeppe(maybe i've got it wrong though!)09:47
fwereaderogpeppe, btw, finished To Hold Infinity, very enjoyable09:48
rogpeppefwereade: cool, glad you enjoyed it. am enjoying wwz, in a slightly grim kinda way09:48
rogpeppehmm, firewalling09:48
rogpeppeuntil we containerise everything, i think the current approach is probably the only one09:49
fwereaderogpeppe, enjoying Axiomatic too, fun to have a more thinky, less experiencey read once in a while09:49
fwereaderogpeppe, ah, expand please? I don't see the issue09:49
fwereaderogpeppe, after all everything is containerised already... in a sense... which feels like the appropriate sense for this context09:50
rogpeppefwereade: how do we firewall without making use of ec2's facilities?09:50
fwereaderogpeppe, iptables?09:50
rogpeppefwereade: can't anything get around that?09:51
fwereaderogpeppe, I have always presumed that it works as advertised, but I can't point to anything proving that09:51
fwereaderogpeppe, and I'm not saying we don't use security groups at all -- we have to -- but we know that using one per machine is a problem09:52
fwereaderogpeppe, I just don't know whether it's the sort of problem we want to fix now, or the sort of problem we leave for 13.0409:52
rogpeppefwereade: am i right about the meeting, BTW?09:53
fwereaderogpeppe, er, I have no idea... I had a vague feeling it was weds, but maybe I missed another change09:53
fwereaderogpeppe, but davecheney is on, and that may lend support to your theory ;p09:54
rogpeppedammit, it's an hour later09:55
rogpeppebugger, my dispensation is invalid09:55
rogpeppefwereade: iptables are manipulatable by root, and the charms run as root.09:55
rogpeppefwereade: we need to talk to niemeyer about this09:55
rogpeppefwereade, TheMue: well, gotta go. will miss the meeting, i think. have fun, and post any interesting/relevant conversations to juju-dev, where i will see 'em and sneakily read 'em...09:56
fwereaderogpeppe, yeah, indeed -- I'm not even sure I have a strong position on this, I just feel it's something we should get niemeyer's input on before we implement code that supposes either way09:57
fwereaderogpeppe, enjoy the holiday :)09:57
TheMuerogpeppe: OK, have fun.09:57
fwereadeTheMue, I think that either way you can certainly implement something that keeps an eye on both sets of conditions, and emits events when ports should actually open or close09:59
rogpeppefwereade: we could cache groups, because we're unlikely to have too many configurations of ports.09:59
rogpeppefwereade: which might mitigate the issue09:59
TheMuefwereade: That's what firewall does today.09:59
rogpeppeTheMue: ah, it must've changed since i last looked10:00
rogpeppeTheMue: i thought there was one group for each machine10:00
rogpeppeanyway, gotta go10:00
TheMuerogpeppe: The firewall.py does not very much. It's only used by the PA.10:00
fwereadeTheMue, where does it do that?10:01
fwereadeTheMue, I don't see anything that shares groups in there10:01
TheMuefwereade: I didn't say anything about groups. I meant watcing the ports.10:02
fwereadeTheMue, if anything does that, it's in the individual provider's open_port/close_port methods10:02
fwereadeTheMue, ah got you10:02
fwereadeTheMue, all I'd suggest then is to make sure that the thing that watches an individual machine remains distinct from the thing that watches all machines10:03
fwereadeTheMue, do I appear to be approximately sane there?10:05
TheMuefwereade: I'll keep it in mind. I'm not yet deep enough in it. Just started the porting and as a prerequisite the watcher for the exposed flag.10:05
fwereadeTheMue, cool10:06
* fwereade starts to wonder whether he's right about it being up to the UA... maybe the MA would be better...10:06
TheMuefwereade: You've got more insight than me. I sometimes miss an architecture graphics where the components, their responsibilities and roles and how they communicate are visible.10:07
* TheMue is a very visual being.10:07
fwereadeTheMue, I think the issue there is that the responsibilities in python are not necessarily as they should be10:07
fwereadeTheMue, eg theMA being responsible for the first download of the charm, and the UA being responsible for subsequent ones10:08
TheMuefwereade: OK, then two graphics: todays implementation and wanted implementation10:08
fwereadeTheMue, the first one is of limited value and the second one is subject to change as we figure out *how* we should be doing things...10:09
fwereade*should*10:09
fwereadeTheMue, hopefully without succumbing to second-system effect10:09
TheMuefwereade: That's a problem of working remote. I've used whiteboards a lot for a discussion of how something is and how it should change.10:11
TheMuefwereade: My intention is now first class diagram10:11
TheMues/now/no/10:11
Arammoin.10:34
fwereadeAram, heyhey10:54
TheMueAram: Moin11:03
Aramfwereade: TheMue: had a little bit of fun yestarday: http://play.golang.org/p/D-qPq8uIw311:05
fwereadeAram, haha, nice11:14
TheMueAram: *lol*11:18
TheMueHmm, seems it's time for a topology watcher.13:08
TheMuefwereade: Any experiences with the size of topologies in large installations?14:05
fwereadeTheMue, all I know is that yaml was too big for the 2k deployment, json makes it small enough for that with room to spare14:06
TheMuefwereade: I'm asking because topology watchers keep an old one in memory and pass it and a new one to the using callbacks/watcher users.14:06
fwereadeTheMue, IIRC max ZK node size is 1MB, so order of that, I guess14:07
TheMuefwereade: I would store it already parsed, so there should be not whitespace problem.14:07
fwereadeTheMue, it shouldn't be an overwhelming load though14:08
TheMuefwereade: ok14:08
fwereadeTheMue, however you way want to look at recent topology watchers in go, which don't keep a whole topology around14:08
fwereadeTheMue, they just keep the bits they're interested in14:08
TheMuefwereade: WHich ones you're talking about? Most I've seen so far watch simple nodes.14:09
fwereadeTheMue, MachinesWatcher and MachineUnitsWatcher14:09
TheMuefwereade: Also the event of change always forces me to at least read one complete node.14:10
fwereadeTheMue, also ServiceRelationsWatcher, new in review today14:10
fwereadeTheMue, yeah, you always read the whole new topology14:10
fwereadeTheMue, no reason to keep unit info around when all you care about is relations for one service14:10
TheMuefwereade: Thx, will take a look. I need it for the ServiceUnitsWatcher.14:10
fwereadeTheMue, cool14:11
fwereadeTheMue, a suggestion, don't know if it applies:14:11
* TheMue listens14:12
fwereadeTheMue, when doing the ServiceRelationsWatcher, it was very convenient to add (*Service)relationsFromTopology(t *topology) and use it both in Relations and the watcher14:12
fwereadeTheMue, haven't looked at MW or MUW to see whether they'd benefit from similar14:13
TheMuefwereade: OK, will look, it sounds good.14:13
fwereadeTheMue, it may be that the code to extract the stuff we care about is small enough not to bother in those cases and maybe in yours14:14
TheMuefwereade: Huh, the last sentence is difficult for me to understand.14:15
fwereadeTheMue, sorry14:15
fwereadeTheMue, I'm saying that getting a []*Relation from a service and a topology is enough work to make it worth factoring out14:16
fwereadeTheMue, but getting a []*Unit from a service and a topology may be trivial enough that it's better to duplicate the code14:16
fwereadeTheMue, similar may apply to MW and MUW14:17
TheMuefwereade: OK, understand, I will see how much it is.14:17
niemeyerHellos!15:19
twobottuxaujuju: Is juju specific to ubuntu OS on EC2 [closed] <http://askubuntu.com/questions/149952/is-juju-specific-to-ubuntu-os-on-ec2>15:27
TheMueniemeyer: Hello to the far west.15:31
niemeyerTheMue: Hi :)15:35
niemeyerTheMue: How's been the weekend?15:35
TheMueniemeyer: Fine, a but support for my brother in law, he is building a house, and sitting on the couch on Sunday, it rained cats and dogs.15:37
TheMueniemeyer: And your travel to SFO?15:37
niemeyerTheMue: Hah :)15:37
niemeyerTheMue: The trip was quite fine15:38
niemeyerHmm.. so it seems that Go's behavior on redirections has changed somehow.. lpad seems broken :(16:17
* niemeyer investigates16:17
fwereadeniemeyer, heyhey16:27
fwereadeniemeyer, TheMue: please confirm that it is not safe to select on a send to a channel that might be closed16:28
niemeyerfwereade: It is actually safe16:28
fwereadeniemeyer, really? oh, cool16:29
niemeyerfwereade: It depends a bit on what you mean by that, though16:29
niemeyerfwereade: Oh, wait.. *send*.. hmm16:29
fwereadeniemeyer, select {dodgy <- event: blah; <-t.Dying()}16:29
fwereadeniemeyer, select {dodgy <- event: blah; <-t.Dying():}16:29
niemeyerfwereade: No, that's not ok, sorry for the misinfo16:30
fwereadeniemeyer, no worries :)16:30
niemeyerfwereade: It's considered a bad practice (hence why it blows up) because it's a clear statement that the life time of the channel is messed up.16:32
fwereadeniemeyer, that was what I thought16:32
Aramhi niemeyer, how's SF?16:32
fwereadeniemeyer, and I'm pretty sure I'm in a situation where I can just leave the channel alone without ever closing it anyway :)16:32
niemeyerAram: Pretty nice, sunny.. had a good time with Andrew yesterday as well16:33
Aramniemeyer: nice.16:33
niemeyerfwereade: That's a possible answer16:33
Aramniemeyer: did you see my silly paste entry? http://play.golang.org/p/D-qPq8uIw316:33
niemeyerAram: Yeah, that was awesome :)16:34
niemeyerrobbiew: ping16:35
Aramniemeyer: I could have made it an actual animated PNG, but animated PNGs don't work in webkit browsers yet.16:35
robbiewniemeyer: pong16:35
niemeyerrobbiew: Heya16:35
niemeyerrobbiew: Do we have a meeting today?16:35
robbiewniemeyer: heh...as usual, I have no idea...checking16:36
niemeyerAram: Surprisingly short16:36
niemeyerrobbiew: Cool.. I better find out a good way to call out of the hotel if so16:36
robbiewniemeyer: no meeting16:36
niemeyerrobbiew: Super, thanks for checking16:37
fwereadegn all17:28
fwereadeniemeyer, btw, I have to go again in a sec, but I meant to ask:18:08
fwereadeniemeyer, are we planning to replicate the security-group firewalling for 12.10?18:08
niemeyerfwereade: Yeah18:09
niemeyerfwereade: Should be easy, and gets us parity18:09
niemeyerfwereade: We can then fix it another way later18:09
niemeyerfwereade: But,18:09
niemeyerfwereade: We should try to make the implementation sensible, so that we can reuse bits18:09
fwereadeniemeyer, yep, I approve (despite emotionally wanting to Do It Right ;))18:09
niemeyerfwereade: I've been talking to Frank about that18:09
niemeyerfwereade: He's working on the firewall port watcher stuff18:10
fwereadeniemeyer, excellent, I realised I didn't know what plan we were following when he mentioned it this morning18:10
niemeyerfwereade: That we have under state/firewall.py in Python18:10
niemeyerfwereade: But with some twists.. the Python version assumes it knows about a provider and what not18:10
niemeyerfwereade: The Go version will be a normal watcher18:10
fwereadeniemeyer, yeah, I presume we'll just be outputting changes18:10
fwereadeniemeyer, perfect18:10
niemeyerfwereade: Exactly18:11
fwereadeniemeyer, I would guess two levels of watchers so we can reuse the inner one when it becomes the MA (UA???)'s responsibility?18:11
niemeyerfwereade: Yeah, we actually already have one in the unit18:12
niemeyerfwereade: So this is adding the second one, on Machine18:12
fwereadeniemeyer, ah, nice18:12
niemeyerfwereade: WatchPorts18:12
niemeyerfwereade: I think we'll use the exact same thing when we move18:12
niemeyerfwereade: The difference is that the machine agent will call Machine.WatchPorts, rather than the provisioning18:12
fwereadeniemeyer, perfect :)18:13
robbiewmramm: looking for me?19:27
Aramniemeyer: somethins intriguing is happening... compare this: http://bazaar.launchpad.net/~gophers/juju-core/trunk/view/head:/mstate/state.go#L56 with this: https://codereview.appspot.com/6304099/diff2/9002:18002/mstate/state.go19:33
Aramthe machine function19:33
Aramis different :)19:33
Aramhow can this be?19:33
Aramthe AllMachines function is the same though, and both have been altered in the same commit.19:33
niemeyerAram: Why should they be the same, just so I get the context?19:34
Aramniemeyer: because I submitted what's on codereview, and what's in launchpad seems an earlier version.19:35
niemeyerAram: Ah, it's actually not19:36
niemeyerAram: https://codereview.appspot.com/6330045/19:37
Araminteresting.19:37
Aramwhy the removal of that branch?19:38
niemeyerAram: The new error will look like "can't get machine 42: not found", which is fine19:38
niemeyerAram: I had to touch that logic due to the NotFound renaming19:38
niemeyerAram: (ErrNotFound now)19:38
Aramyes, yes.19:38
niemeyerAram: But rather than replacing it, I just dropped and allowed the underlying error to go through as per the message above19:39
Aramwell yes, that was my initial version as well.19:39
niemeyerAram: Not really19:39
niemeyerAram: your initial version was the opposite.. any error would lead to "not found"19:39
Aramright.19:40
Aramniemeyer: anyway, thanks for clearing the confusion.19:41
niemeyerAram: np, and sorry for the trouble.. I wanted to ask for your review on it too, but at the same time didn't want to leave trunk broken19:41
Aramof course19:41
Aramniemeyer: first piece of the puzzle: https://codereview.appspot.com/634105020:01
niemeyerAram: Awesome, thanks!20:01
Aramniemeyer: the diff on codereview is always done against lp:juju-core? can't I do it against some other branch I have?20:12
niemeyerAram: You can, with -req20:13
niemeyerAram: It only allows trees rather than graphs, but it works20:13
Aramstrange, that's what I did, lbox propose -cr -wip -req="lp:~aramh/juju-core/mstate-charm-basic"20:14
niemeyerAram: -req has to be used at propose time20:14
Arambut it generated this: https://codereview.appspot.com/6325057 which is wrong because it should only be two lines20:14
niemeyerAram: After the merge proposal is created, it doesn't work anymore20:14
niemeyerAram: (because Launchpad doesn't allow changing it)20:14
Aramcan I delete a merge proposal and do it again from the same branch?20:14
niemeyerAram: Yeah20:14
niemeyerAram: That works fine20:14
Aramok, thanks20:15
niemeyernp20:17
niemeyerOkay, lpad works again.. I'll go out for finding some food, and will be back to work on reviews20:33
Arammorning davecheney22:50
davecheneymorning Aram22:51
davecheneyhows it going ?22:51
Aramgreat22:51
Aramniemeyer: I believe three pieces of the puzzle should be in the queue now22:56
niemeyerAram: Super, thanks!22:56
niemeyerdavecheney: Heya22:56
davecheneyhowdy lads22:57
=== Aram2 is now known as Aram

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