/srv/irclogs.ubuntu.com/2013/01/31/#juju-dev.txt

arbit30719can some body help me solve juju and MAAS problem : I have also posted on ask ubuntu  http://askubuntu.com/questions/249350/juju-cannot-deploy-services-with-maas02:17
arbit30719hello ?02:24
arbit30719can some body help me solve juju and MAAS problem : I have also posted on ask ubuntu  http://askubuntu.com/questions/249350/juju-cannot-deploy-services-with-maas02:30
bigjoolsarbit30719: most of the devs are in Europe and USA02:31
arbit30719I see  :P02:41
arbit30719hi all04:59
jtvjam: Why do we create one global instance of each provider, but *register* a different instance?06:04
jamjtv: well for ec2 'environProvider' has no state (struct{}) so the concept of an instance of it is a bit weak.06:05
jamI think the important part is to register that the instance exists.06:06
jamI see your point, though.06:06
jamIt does look like06:06
jamenvirons.RegisterProvider("ec2", providerInstance)06:06
jamwould make more sense.06:06
jamIt works because there is no state, and all the functions just exist to create the actual environ where work is done.06:06
jtvThanks!  I was wondering if there might be externalized data associated with pointers-to-providers too.06:07
jamjtv: I imagine the openstack code just copied the ec2 code.06:07
jtvYeah...  I'm not reading too much into the "everyone does it" for that reason.  :)06:07
jamjtv: yep. We inherited a fair amount of stuff I suspect from copying it from ec206:08
jamIt would make sense to me to have a patch that registered the global variable06:08
jamotherwise, why have that var?06:08
jtvMaybe as a prototype..?06:08
jamwell it is used in functions06:08
jamSetConfig() calls providerInstance.newConfig() etc.06:08
jtvYeah.  It looks a lot as if the thing has neither state nor identity...06:09
jamso *if we get state* I think we have to use the global variable in the registration.06:09
jtvThat does sound sane, yes.06:09
jamjtv: I imagine there is a discrete instance, (you can probably take the address of it)06:09
jam&providerInstance06:09
jambut it is not actually used06:09
jamI think the type is there to collect methods06:09
jamand you can't just call Type.method()06:09
jamso you have to somewhere generate an instance of it06:09
* jam always doubts if global state is correct, though.06:10
jtvWell if there's no state...  :)06:10
jtvIt looks as if a singleton was intended.06:10
jamjtv: then you should be using a local var06:10
jam?06:11
jamto make it clear06:11
jamjtv: yeah, it does look like someone was trying for a singleton pattern.06:11
arbit30719hi all06:11
jtvA local var would be nice, but puts it out of reach of the code that needs the singleton.06:11
jtvHello arbit3071906:11
arbit30719can some body help me solve juju and MAAS problem : I have also posted on ask ubuntu  http://askubuntu.com/questions/249350/juju-cannot-deploy-services-with-maas06:11
arbit30719=)06:11
jamarbit30719: from everything I can see "agent-state: not started" means that the juju control isn't established on your machine 1, and from the traceback, it appears it will never start.06:13
jamI would say kill it (juju destroy-service mysql, juju delete 1)06:13
jamand maybe try again.06:13
jamI'm not sure why it is having trouble getting a zookeeper connection, though.06:14
arbit30719I tried several times and failed06:14
jamgive "juju status" indicating the root machine is working.06:14
arbit30719I am pretty sure root machine works fine between machine 0 and maas server06:15
jamjtv: where is the state stored in maas? Is it reasonable to try and query that for what the saved 'zookeeper' information is, to try a manual connection06:15
jam?06:15
jtvbigjools worked on that code — he may know06:16
arbit30719?06:17
bigjoolsthis is a juju bug as I recall06:19
bigjoolssomething to do with ZK06:20
bigjoolsbut I can't remember what causes it or what the resolution is06:20
bigjoolsperhaps update to the latest version from the PPA06:20
jambigjools: does maas do firewalling? Is it possible juju is trying to connect to ZK on a port that isn't open?06:21
bigjoolsit doesn't06:21
arbit30719I also tried disable firewall and failed...06:22
bigjoolsI remember this bug pretty well, just not well enough to know what the problem was :)06:22
bigjoolsI encountered it on my own systems06:22
bigjoolsarbit30719: what version of juju are you using?06:22
arbit307190.606:22
bigjoolsis that from precise/quantal?06:23
arbit30719quantal06:23
bigjoolscan you try the official PPA06:23
arbit30719you mean ?06:24
bigjoolsalso put juju-origin: ppa in the config06:25
arbit30719I think MAAS in quantal is much easier to setup06:25
bigjoolsit will get even better with the SRU that's coming06:25
arbit30719yes I do put pap in environment.yaml06:25
arbit30719SRU ?06:25
arbit30719typo   pap  -> ppa06:26
bigjoolsok06:26
bigjoolsnot sure where else to go06:26
bigjoolsI expect one of the core devs will remember when they start (in ~2.5 hours)06:27
arbit30719um...06:27
arbit30719ok06:27
bigjoolsarbit30719: ah I have an idea06:32
bigjoolscan machine 1 resolve the machine 0's DNS address?06:33
bigjoolsthe name of the machine that you use in MAAS needs to be resolvable06:33
arbit30719ha I also checked the name server (MAAS-dns)06:34
arbit30719They  can resolve both 0's and controller's name06:34
bigjoolsso ssh to machine 106:34
bigjoolsand do:06:34
bigjoolshost node-4487fc70b03706:34
arbit30719192.168.1.506:35
bigjoolscan you do:06:36
bigjoolstelnet node-4487fc70b037 218106:36
bigjoolsand see if it connects to ZK06:36
jamjtv: one small thing about your patch, I'm pretty sure you want to just use "providerInstance" not "&providerInstance"06:43
jtvWhere exactly?06:44
jam+func init() { +environs.RegisterProvider("maas", &providerInstance) +}06:44
jamI would be wrong, since that actually creates a copy of the instance06:44
jam(but again, no actual state :)06:44
jambut the code you are replacing was:06:44
jam+func init() { +environs.RegisterProvider("maas", environProvider{}) +}06:44
jamwhich isn't an address.06:44
jtvYeah.  Don't we have a type system for this?06:45
jamjtv: it is an interface06:45
jamI imagine that both providerInstance and &providerInstance support the methods you need to be part of the interface.06:45
jamEnvironProvider06:45
jtvNo...  only providerInstance does.06:45
jam(interfaces are based on what methods are available)06:45
jamjtv: if you define a method func (e environProvider) Foo()06:46
jamis that also exposed on *environProvider ?06:46
jamIf it is, then both provide the interface06:46
jamif the funcs themselves are func (e environProvider) than using the address has no effect06:47
jambecause a new copy will be created for each function call.06:47
jtvAFAIK it is only exposed on the object itself, not the pointer.06:47
jtvI think I just took the address to satisfy the type system.  Let me try.06:47
jamjtv: I'm actually pretty sure it is both06:47
jamthere is a cast earlier that hints at it06:48
jtvThat would explain.  And also freak me out.06:48
jtvGrr.  It works either way.06:48
jamjtv: http://bazaar.launchpad.net/~gophers/juju-core/trunk/view/head:/environs/openstack/provider.go#L3806:49
jamso we know that a pointer to a provider provides the interface06:50
jambecause we have an explicit cast06:50
jtvThat sort of destroys the last vestige of sense in the ec2 code, doesn't it?  Why create an instance and register its address, when registering an instance will do the same thing?06:50
jamhowever: http://bazaar.launchpad.net/~gophers/juju-core/trunk/view/head:/environs/openstack/provider.go#L6106:50
jamall of the actual methods are done based on the object itself06:50
jamnot its pointre06:50
jamso if you define funcs on the pointer, then you must have a pointer to call the object06:50
jambut if you define funcs on an object, you can have the object or a pointer to it.06:50
jtvBut not the other way around.  Shudder.06:50
jamjtv: and when calling a func-on-object, a new actual object is created during the function call06:51
jamso you cannot mutate state in one of those calls06:51
jamso you must either have 0 state, or at least 0 mutable state06:51
jtvYes.06:51
jamjtv: so IMO, funcs on objects don't make a lot of sense06:52
jamwhich would then put you in a case where you have to pass the address.06:52
jtvThey sort of do...  but only for small, immutable objects.06:52
jambut, that is the way the code exists.06:52
jamjtv: without state changes, which means why is it on an object rather than a plain func.06:52
jamI guess interfaces mean you have a way to group funcs.06:52
jtvThat's exactly what it is.06:53
jamI want *this* set of vpointers06:53
jtvThey call them "method sets," I think.06:53
jtvAFAICS the only form of dynamic dispatch in the language is that an interface is basically a tuple (vtable, object)06:53
jtvAn interface *value*, that is.06:53
jamjtv: right06:53
jtvNot an interface *definition*, obviously.06:54
jtvAnyway, I wrote all that up in our Cultural Learnings document last week:06:54
jtvhttps://docs.google.com/a/canonical.com/document/d/1GQ3u7keE3hJH2oaweAm28K78hQZAbqeQqR9xwD9OR4I/edit#06:54
jtvI'll update it with the new knowledge that a pointer to an implementing object is also a valid interface value.06:56
jamjtv: I'm using my canonical creds with lbox (though I do have some difficulties) it does seem to work.06:58
jam(reading through your docs)06:58
jtvYeah, Gavin had the same experience.  Don't know what I did wrong.06:58
jamI got a bunch of "protocol not supported" failures until it happened to work06:58
jamand then it seems to generally work afterwards, though I just had propose fail again06:59
jtvWeird07:00
jtvThanks for going through the document BTW.07:00
jamI'm pretty sure I read it the first time you mentioned it as well.07:00
jambut it is good to be reminded from time to time.07:01
jtvjam: I updated my branch to register (a copy of) the provider instance, rather than its address.  For what it's worth!07:07
jamjtv: I see the point either way. Having thought about it, I probably prefer the address method, but that is probably just my 'why isn't it actually an instance'07:08
jamIt is a method set, and instance doesn't really mean anything, but we have no way to talk about it without an instance.07:08
jtvOkay, I'll undo the change you asked for.  :)07:09
jtvOr do you mean you would like the *methods* implemented on the pointer?07:09
* jtv relocates07:20
rogpeppemornin' all08:15
jtvHi rogpeppe08:15
rogpeppejtv: hiysa08:16
jtvjam: did you mean earlier that you would prefer the provider to implement its interface on the pointer only?08:16
fwereaderogpeppe, heyhey08:18
fwereadeeveryone, heyhey08:18
rogpeppejtv, jam: that looks like a bug in Register method08:19
rogpeppealthough it won't make any difference.08:19
jtvrogpeppe: I wasn't aware, but if class T implements interface N, then *T also implements N.08:19
rogpeppejtv: yeah08:20
rogpeppejtv, jam: Environ.Provider was a latecomer to the party08:20
rogpeppejtv, jam: and if you don't have that, there's you don't need providerInstance.08:21
rogpeppein fact, you don't need providerInstance at all anyway08:21
rogpeppeenvirons.Provider could just return environProvider{}08:21
jamjtv: I would say it is "method set" vs "singleton". If you are going to have a singleton factory, then you should have the methods implemented of "*Foo" so that they all use the same instance.08:22
jamIf you just have a method set, then there isn't an instance to really think about08:22
jamas it just gets created all the tiem.08:22
jamtime08:23
jtvAnd now we're discussing how to implement a singleton.  I miss python.  :)08:23
jtvIf it really doesn't matter at all, I'll just go with Environ.Provider() and forget about the singleton.08:24
jtvThanks for pointing that out, rogpeppe  — it makes a few missing pieces fall into place for me.08:25
jamjtv: I would probably push towards one or the other for consistency.08:25
jamAt this point, I don't really care which.08:25
jamBut we shouldn't have both.08:25
jtvMakes sense.08:25
jamBecause it makes you say: oh we have a singleton, but wait, these are all pass by value, but wait, all the methods are also pass by value so it doesn't matter.08:25
jamThe last one especially requires you to actually inspect all the methods.08:26
jamRather than just being obvious from the pattern.08:26
rogpeppejtv: the reason only reason that the global var is useful is to make it more convenient to do environProvider.newConfig(environProvider{})...08:27
jtvOh08:27
jamrogpeppe: doesn't that hint that 'newConfig' should just be a local func?08:28
rogpeppejam: yeah, it probably should be08:31
rogpeppejam: if it was calling one of the environProvider's exported functions, it would be right08:32
jambut you can poke at private methods as long as you are in the same package, right?08:33
TheMueMorning08:48
mgzmornin'09:00
jammorning mgz09:40
mgzhey!09:43
rogpeppejam: sure, but there's no real reason for newConfig to be defined on environProvider09:46
dimiternjam: hey, I didn't add a test for checking userdata encoding/etc. because I don't yet see how I can test it09:55
jamdimitern: have a test that creates an object, serializes it to json, and asserts the content is base64 encoded? (and decodes to the right content?)09:56
jamthat would at least be something.09:56
jamthe bug was that we were encoding to base64, and then it was getting encoded *again* by JSON09:56
dimiternjam: you think that's enough? done on RunServerOpts only?09:56
jamso a test that it is encoded just 1 time would fit the bill09:56
jampossibly we mighht want to refactor the code so that the part that fills out the object can be tested separately from actually making an RPC09:57
dimiternyeah, but we were wrong because didn't bother to read carefully what the json module does to []byte fields..09:57
jamdimitern: so I realize what the bug was, and the fix is correct. But lets add a test so that in 6 months we don't forget and wonder "why aren't we encoding this field"09:57
dimiternis it useful to test that go does something it says it does?09:58
jamdimitern: clearly it was non-obvious09:58
jamor we wouldn't have made the mistake in the first place.09:58
dimiternjam: I added a comment there in RunServer09:58
jamdimitern: the fact that it confused us for roughly 2 days09:58
jammeans that we could have some help09:58
jamI still think it is clearly untested code09:58
jamor it wouldn't have broken09:58
dimiternjam: ok, so should it in juju or in goose?09:59
jamdimitern: seems like a goose level test to me09:59
dimiternjam: ok and now with the bot - we follow the steps you outlined from now on?09:59
jamdimitern: yeah, if it doesn't work, just poke me09:59
jambut things should land in ~2min from when you mark it approved.10:00
jamdepending on how slow the juju-core test suite is.10:00
dimiternjam, ok then, I'll think of a test then10:00
dimiternand in juju I still have to set a FIP to the state machine when bootstrapping10:01
jamdimitern: FIP ?10:01
jamfloating ip10:01
dimiternfloating ip10:01
fwereadeblast: I have a doctor's appointment, it might take a little while: I'll be back when I can be :/10:02
jamrogpeppe: arbit30719 was asking about http://askubuntu.com/questions/249350/juju-cannot-deploy-services-with-maas earlier10:05
jamany ideas about problems connecting to ZK when using juju w/ maas?10:06
jamor other people to point him to?10:06
rogpeppejam: hmm10:07
rogpeppejam: it seems as if machine 1 can't connect to zk, even though the juju client can.10:09
jamrogpeppe: right, I think bigjools said he had seen something similar in the past, but we didn't have much  more state than that.10:10
rogpeppejam: it would be nice if that exception provided more info - perhaps it got a connection refused or something10:10
rogpeppejam: and it's weird that he can't use juju ssh to connect to machine 110:11
rogpeppejam: any of the original juju team would be better at answering this question than me :-)10:11
rogpeppejam: i think bigjools' answer is a good one10:12
mgz...who are the original juju team?10:12
rogpeppemgz: kapil, jim baker, ben howard, william, gustavo10:13
mgzah, jim was too? I don't know ben.10:13
rogpeppemgz: oops not ben howard. ben... surname escapes me10:14
rogpeppemgz: ben saller10:15
rogpeppedoh10:15
arbithello i am the previos arbit3071910:17
jammgz: btw, I think your public containers stuff has landed, we should update the kanban board10:23
mgzjam: good point10:23
mgzI'll put up some tasks in 'coding' that aren't coding as such but could do with tracking there10:26
jtvHi there mgz — did you have any notes about the gomaasapi code?10:32
mgzjtv: not yet, was hoping to look at it with Gavin today10:33
jtvAh OK.  Thanks again!10:33
mgzmentioned it in the standup the other day, and rogpeppe noted it would be nice to have the whole thing up on codereview for those (gojuju people) who like to use that when reviewing things10:34
jtvAnd jam, are you comfortable enough with my "provider singleton" branch that I can land it on our feature branch?  This one: https://code.launchpad.net/~jtv/juju-core/mpv-singleton/+merge/14577710:34
mgzso, will probably put up a r1..-1 dummy merge for that10:34
jtvOn Rietveld?10:34
mgzyup10:34
rogpeppejtv: yeah. it's really nice to be able to spray comments around in context :-)10:34
jtvLooking forward to learning more.10:34
jtvI imagine it is, yes.10:35
jtvTwitter Review API!10:35
jtvSorry, just a weird thought.10:35
mgzrogpeppe: how did we do that last time? would probably make sense for jtv to put it up rather than me10:37
rogpeppemgz: you didn't do that last time :-)10:37
rogpeppemgz: perhaps a change that changes each source file in a trivial way (e.g. adding a "// to review" comment at the start)10:38
rogpeppemgz: then propose that10:38
mgzI'd do something like `bzr push -r1 lp:~/gomaasapi/base` then `~/go/bin/lbox propose -cr -v -for=lp:~/gomaasapi/base`10:38
mgzwhich would give a diff of all the bits that matter10:39
rogpeppemgz: that's a good plan10:39
rogpeppemgz: sounds good10:39
rogpeppemgz: except that the target isn't right, but i guess that doesn't matter.10:39
mgzwell, the target is backwards, but it gives the right diff10:40
arbithi all, does anybody have some suggestions about the issue I pasted on ask ubuntu http://askubuntu.com/questions/249350/juju-cannot-deploy-services-with-maas10:40
arbitIt seems that I cannot connect to zk server of machine 110:41
mgzarbit: #juju is the channel for general juju questions, but you might need to wait for US timezone peeps to awaken10:41
mgzor #maas in this case10:41
rogpeppearbit: have you tried bigjools' suggestion?10:41
arbityes I tried and failed to connect10:41
arbitigjools told me to paste here10:42
rogpeppearbit: what did the connection failure say?10:42
arbituh I might need to reply this to you later.10:43
arbitI have difficulty connect to the server right now10:44
mgzjtv, rogpeppe: https://codereview.appspot.com/722806910:50
jtvThanks10:50
rogpeppemgz: cool, thanks10:50
rvbaThanks for doing this mgz.10:51
TheMuelunchtime, biab10:59
dimiternrogpeppe, mgz: here is another bootstrap-related fix https://codereview.appspot.com/722606811:20
rogpeppedimitern: will have a look in a bit, thanks.11:24
jamdimitern: wallyworld_: poke for the mumbling11:32
dimiternjam: right there11:32
dimiternjam: my mumble decided to start crashing :(11:33
mgzit's like my yesterday11:34
dimiterndimitern@kubrik:~$ mumble11:34
dimiternSegmentation fault (core dumped)11:34
niemeyerHey all11:44
dimiternniemeyer: hiya11:45
rogpeppeniemeyer: yo!11:45
=== amithkk_ is now known as amithkk
=== amithkk is now known as Guest8601
dimiternrogpeppe: did you have time to look at the CL?12:32
rogpeppedimitern: sorry, been involved elsewhere. will look now.12:33
rogpeppedimitern: mgoPortSuffix = ":" + string(mgoPort)12:33
rogpeppelol12:33
rogpeppeentirely understandable!12:34
dimiternrogpeppe: :) yeah, learning everyday12:35
rogpeppedimitern: i should've caught it!12:35
dimiternhar har :)12:36
rogpeppedimitern: when would FloatingIP.InstanceId not be a string?12:36
rogpeppedimitern: oh, i see12:37
rogpeppedimitern: i think it should be defined as *string, not interface{}12:37
dimiternrogpeppe: it's defined as interface{} and it might be either string or null12:37
rogpeppedimitern: in nova, that is12:37
dimiternrogpeppe: well, there was something about it, which prevented *string somehow, can't remember now12:37
rogpeppedimitern: what's the difference between null and the empty string?12:38
dimiternrogpeppe: we don't care for anything but non-empty string12:38
dimiternrogpeppe: that's just how OS returns it - null, "" or "someip"12:40
rogpeppedimitern: BTW i'd be interested to know what prevented using *string12:40
rogpeppedimitern: 'cos AFAIK that's the canonical way to do null-or-string12:40
dimiternrogpeppe: well, if it's missing from the response?12:40
rogpeppedimitern: it turns into nil12:41
dimiternyeah12:41
rogpeppedimitern: (assuming the field value was nil originally)12:41
rogpeppedimitern: missing fields are unchanged.12:41
dimiternrogpeppe: I suppose  I should change that then in goose as a follow-up12:41
rogpeppedimitern: i think it's worth using static types where possible, yeah12:42
dimiternrogpeppe: that was the very beginning - still leaning go and how stuff works12:42
rogpeppedimitern: :-) i know the feeling.12:42
dimiternnot that I know it all now, but slightly better than ten :)12:42
dimiternthen*12:43
dimiternrogpeppe: what worries me a bit is there is no obvious way to test this locally..12:43
dimiternrogpeppe: otherwise from cmd line it works - tried multiple times12:44
rogpeppedimitern: why not?12:44
rogpeppedimitern: can't you implement similar functionality in the double?12:44
dimiternrogpeppe: yeah, it starts to shape up a bit in my head how I could actually12:44
dimiternrogpeppe: have 2 cases (or more probably) - with free ip and without (to alloc new), then some errors, etc.12:45
dimiternrogpeppe: and in juju i can then call bootstrap on the double and ensure it passes12:46
rogpeppedimitern: sounds plausible12:46
dimiternrogpeppe: cannot see how to live test it (on canonistack)12:46
rogpeppedimitern: ah, because canonistack always allocates an IP?12:47
dimiternrogpeppe: it's very flaky and unreliable with floating ips12:47
rogpeppedimitern: ha12:47
dimiternrogpeppe: because there are rarely any free to alloc12:47
rogpeppedimitern: in which case, you're stuffed :-)12:47
dimiternrogpeppe: and the live test will fail randomly (but very often)12:50
rogpeppedimitern: yeah. maybe you should add a live test, make sure it passes at least once, and then disable it until we've got a decent live testbed.12:50
dimiternrogpeppe: or even check if FIPs are available first, otherwise skip it in the suite12:51
rogpeppedimitern: that sounds like a good plan12:51
dimiternrogpeppe: yeah, I'll try it out next12:52
rogpeppedimitern: you've got a review12:53
dimiternrogpeppe: tyvm12:53
fwereaderogpeppe, btw, I was wondering about having PasswordHash directly in the document and the PasswordValid method pn AuthEntity12:53
fwereades/pn/on/12:53
rogpeppefwereade: yes? (that's what i'm proposing, right?)12:54
fwereaderogpeppe, I'm wondering what will use PasswordValid12:55
rogpeppefwereade: the api server12:55
fwereaderogpeppe, ok, and it's never actually going to be sent out to anything else?12:56
rogpeppefwereade: indeed12:56
rogpeppefwereade: it's specifically so that the api server can authenticate users12:56
dimiternmgz: ping12:57
rogpeppefwereade: (and agents, of course)12:57
fwereaderogpeppe, ok, I guess that's reasonable... I have something knocking around in my mind that a private key is maybe a good approach here as well -- we're not restricted to mongo's name/password scheme any more12:59
fwereaderogpeppe, this is mainly because the authorized-keys in an environment should probably be thought of as belonging to the admin user now13:00
fwereaderogpeppe, and I was wondering if it might be profitable to think around that idea a little13:00
rogpeppefwereade: passwords over https are a fairly conventional way of doing authentication over the web. i like the idea of private keys too, but passwords are more straightforward and not too bad.13:00
fwereaderogpeppe, and, yeah, I'm not sure we can expect such a thing from the gui13:01
rogpeppefwereade: yup13:01
rogpeppefwereade: well... a private key is just a very large password from the client's point of view13:02
fwereaderogpeppe, well, it never gets sent13:02
rogpeppefwereade: but it's quite useful to have a password you can type13:02
fwereaderogpeppe, yeah, indeed13:03
rogpeppefwereade: true. it would be nice if the client used their private key to establish the tls connection13:03
fwereaderogpeppe, not quite sure the tradeoff is the same from the agent POV13:03
fwereaderogpeppe, but yeah, I'm not blocking anything, just raising it as something to keep in the back of your mind13:04
rogpeppefwereade: yeah. i'm just going with the architecture previously agreed with niemeyer13:04
fwereaderogpeppe, the one case to keep in mind even if you don't address it right away is the one in which we use ubuntu SSO13:05
rogpeppefwereade: i'm not sure how the SSO protocol works13:05
rogpeppefwereade: but presumably the SSO key goes straight to the web server, so we can treat it as a password with an additional level of indirection to validate the user.13:06
rogpeppefwereade: s/SSO key/generated SSO token/13:06
fwereaderogpeppe, nor am I, I'm afraid -- but please would you look into it briefly, enough that you're reasonably sure that it'll integrate cleanly with your auth plans?13:07
rogpeppefwereade: i saw it did kerberos, and thought "hmm, that might be a lot of work" but .... http://godoc.org/github.com/jmckaskill/gokerb13:09
rogpeppes/did/used/13:10
fwereaderogpeppe, cool13:10
rogpeppefwereade: although maybe we just need to speak openid13:15
dimiternfwereade: can you take a look at this pls: https://codereview.appspot.com/7226068/14:02
fwereadedimitern, sure14:02
fwereadedimitern, I have a couple up on https://code.launchpad.net/juju-core/+activereviews as well :)14:02
dimiternfwereade: cheers, I'll take a look14:03
fwereadedimitern, what's the situation in which a freshly-started instance has a fip allocated?14:09
dimiternfwereade: there is no way this can happen14:09
dimiternfwereade: started instances do not have fips attached by default14:10
dimiternfwereade: but even if it does, I have the check fip.instanceid == serverid and exit14:10
fwereadedimitern, ok -- I was wondering then whetherit makes sense to try to get the floating ip before we start the instance, then -- ie separate allocate and assign14:11
fwereadedimitern, at bootstrap, if that fails, we can know not to even launch the instance14:11
dimiternfwereade: launching the instance and having fips available are not related - startup can fail, but then it may succeed and fip allocation can fail14:12
dimiternfwereade: and even checking before startup, nothing guarantees a positive check will not fail after startup (fips may be exhausted in the mean time)14:13
dimiternfwereade: at least most cases of errors are handled sanely and a shutdown is performed14:14
mgzdimitern: hey, still need me for owt? shall I just check for things in need of review? :)14:14
fwereadedimitern, so you can allocate the IP and have someone else take it away before you assign it to the instance? that seems surprising14:15
dimiternmgz: yeah, if you want - take a look pls https://codereview.appspot.com/722606814:16
mgzif by someone else you mean "another process using your tenant and credentials", yes14:17
dimiternfwereade: no, if you allocate it (or already have at least 1 avail) then assignment will always succeed (unless nova itself does not respond sanely)14:17
fwereadedimitern, in that case, if the environment requires a floating IP, it seems best to start by allocating that and then, if you get one, provisioning a machine to put behind it14:19
fwereadedimitern, (and finally assigning the ip to the machine)14:19
dimiternfwereade: yes, you're right14:19
dimiternhaven't thought of that14:19
dimiternit makes sense, better logic, and possible earlier failure14:20
fwereadedimitern, TLDR; I think we want `allocatePublicIP()` and `assignPublicIP(serverName string)`14:20
fwereadedimitern, cool, I'll note it14:20
dimiternfwereade: great, 10x14:20
dimiternmgz: of course, you're right as well14:21
dimiternmgz: if you mess up your own account from another location, then it'll break14:21
mgzwell, it's more of an issue with shared accounts like the one we have for goosebot14:21
mgzthen you might have multiple copies of juju, even, trying to do things at the same time :)14:22
dimiternyes14:22
dimiternand why did we need a shared account in the first place? because of the tools?14:24
mgzwell, we wanted shared resources regardless, the reason we have a shared account rather than a shared tenant is just IS hysterical raisins it seemed14:26
dimiternI see :)14:27
mgzbut the point is we want to manage a shared resource (a juju deployment of tarmac) between multiple people. there's no particular reason we'd be doing conflicting things at the same time, but it's possible14:27
rogpeppe"14:46
rogpeppemt.Sprintf(":%d", apiPort)14:46
rogpeppeWhy did these change?14:46
rogpeppe"14:46
rogpeppefwereade: because the previous version was just wrong :-)14:46
rogpeppefwereade: string(1234) != "1234"14:46
fwereaderogpeppe, glaargh14:46
fwereaderogpeppe, good point indeed, I was focusing on var/const :/14:47
mgzand there's no concept of pure functions in go...14:47
mgzso, Sprintf can't promise that, given const input, output is const-suitable14:47
rogpeppemgz: indeed. no function is really pure though, even in haskell :-)14:47
fwereademgz, rogpeppe: thanks :)14:48
=== slank_away is now known as slank
rogpeppein limbo, a close ancestor of Go, string(1234) did give "1234" (so it was const-able) but the only way of generating a string containing a single constant rune was sprintf("%c", x). i think i prefer Go's decision, but they're both useful14:50
rogpeppejam, fwereade: i'm interested in your reactions to my comments on the boilerplate environments branch: https://codereview.appspot.com/7223063/14:52
rogpeppemramm, fwereade, TheMue: meeting?15:00
TheMuerogpeppe: I'm prepared, just waiting for the invitation.15:01
mrammahh15:01
mrammjoining15:01
mrammhangout is in the meeting invite15:01
rogpeppeTheMue: https://plus.google.com/hangouts/_/539f4239bf2fd8f454b789d64cd7307166bc908315:01
* niemeyer => lunch15:07
rogpeppefwereade: here's the api model code i was playing with, in case you missed the link i pasted in the hangout: http://paste.ubuntu.com/1593298/15:46
fwereaderogpeppe, sorry, I did; thanks15:47
rogpeppefwereade: it just models a single client reading a single changing value15:47
rogpeppefwereade: (in the naive way i'd originally envisaged15:48
fwereaderogpeppe, I hope I will get to playing with it tonight - I'll be looking after laura as well but will probably be back later on :)15:48
fwereaderogpeppe, (I'm still around until just after 6)15:48
rogpeppefwereade: i'm just heading out for some lunch and a stomp outside - will be back before then but not much before.15:49
fwereaderogpeppe, then enjoy your stomp, and also your evening15:49
fwereaderogpeppe, I will see you if I see you :)15:50
rogpeppefwereade_: stomp enjoyed16:40
rogpeppefwereade_: found about a dozen broken plastic sledges at the bottom of the village "run"16:41
fwereade_rogpeppe, haha16:41
rogpeppefwereade_: all the snow's gone now though16:41
fwereade_rogpeppe, I realised I was old when my instinctive "yay, it's snowing" was almost instantly overwritten by "grrmbl I have to walk to work through that"16:43
fwereade_rogpeppe, and then I ran away to the med to try to forget it ;p16:43
rogpeppefwereade_: i'm still in the yay! phase16:43
TheMuefwereade_: both branches are in, will also add a bug for the sudo-test-change17:16
fwereade_TheMue, awesome, tyvm17:16
TheMuefwereade_: are your review cards still active? if so, could you copy the link to the reviews into the cards? makes it simpler.17:17
fwereade_TheMue, ah, sorry, sure -- I use +activereviews to keep up with them... er, when I do keep up with them :/17:18
TheMuefwereade_: hehe17:18
TheMuefwereade_: it's nice to see the cards in review state and directly follow the links17:19
fwereade_TheMue, agreed17:19
fwereade_TheMue, added17:19
fwereade_TheMue, remind me when I forget17:20
TheMuefwereade_: cheers17:20
TheMuefwereade_: So, bug is entered at https://bugs.launchpad.net/golxc/+bug/1111640 and assigned to me.17:25
_mup_Bug #1111640: Extend tests to run without sudo <golxc:New for themue> < https://launchpad.net/bugs/1111640 >17:25
fwereade_TheMue, lovely, thanks17:25
TheMuefwereade_: yw17:25
TheMuefwereade_: You've got two reviews.17:59
* rogpeppe is done for the day18:19
rogpeppeg'night all18:19
TheMuerogpeppe: good night, I'm leaving too.18:31

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