/srv/irclogs.ubuntu.com/2014/07/10/#juju-dev.txt

* thumper off to visit the vet, bbl00:20
davecheneylucky(~/src/github.com/juju/juju/environmentserver/authentication) % vim authentication.go01:08
davecheneylucky(~/src/github.com/juju/juju/environmentserver/authentication) %01:08
davecheneywhy does this new package have ZERO tests ?!?01:08
davecheneywhy is there a whole package for one file01:08
davecheneyand two types !?!01:08
davecheneyno, not two type01:09
davecheneytwo functions01:09
rick_h__davecheney: because it's waiting for you to write the rest of it?01:09
rick_h__:)01:09
davecheneyrick_h__: i didn't add that01:11
davecheneyme is frustrated with the proliferation of tiny packages01:12
davecheneyffs people, this isn't java01:12
davecheneymenn0: https://github.com/juju/juju/pull/28401:52
davecheneysmall PR for your lunchtime perusal01:52
menn0davecheney: will look right after this meeting (if it happens)01:59
davecheneyoh shit02:06
davecheneyi was going to take a screenshot of the hangout screen that showed 12:0502:06
davecheneybut the it ticked over to 12:0602:06
davecheneyand it didn't hav the ring to it02:06
davecheney        info.SetAPICredentials(configstore.APICredentials{02:07
davecheney                User:     apiInfo.Tag.Id(),02:07
davecheney                Password: apiInfo.Password,02:07
davecheney        })02:07
davecheneyohh,02:07
davecheneyhere is an intersting one02:07
davecheneywe have a Tag, so "user-dave"02:07
davecheneybut the api credentials being written down will be "dave"02:07
davecheneyso that User field cannot be used to turn back into a tag02:07
thumperyeah, that is all fucked up02:07
thumperanyway...02:07
thumperI've touched that I think02:07
davecheneywhere do those credntials go ?02:08
thumperthose are stored in the .jenv file02:08
davecheneyif the thing at the other end is doing02:08
davecheneynames.ParseUserTag02:08
davecheneythat is ok02:08
thumperit isn't02:08
davecheneyif it's doing02:08
davecheneynames.ParseTag02:08
davecheneythen it's wrong02:08
davecheneyok, comment added anyway, i'll come back to it after I've fixed the compile errors02:09
thumperI think it is doing neither02:09
davecheneythumper:02:11
davecheney        var environUUID string02:11
davecheney        if apiInfo.EnvironTag != nil {02:11
davecheney                tag, err := names.ParseEnvironTag(apiInfo.Tag)02:11
davecheney                if err != nil {02:11
davecheney                        return err02:11
davecheney                }02:11
davecheney                environUUID = tag.Id()02:11
davecheney        }02:11
thumperyep02:12
davecheneyso, if the environtag _is_ set, then ignore it and use the id of the apiInfo.Tag ...02:12
davecheneyo_O02:12
thumperah wat?02:13
thumperI misread the code02:13
thumperthat is all sorts of fucked up02:13
thumperpretty sure it should be using EnvironTag ...02:13
davecheneyyup02:15
davecheneythumper: do you want me to land a quick branch to fix this before doing some more wholescale changes ?02:19
thumperyeah, I think that would be good02:19
davecheneyok, two secs02:20
thumperdavecheney: if it makes you feel better, I'm down in the trenches of weird/shitty code too02:20
davecheney\o/02:22
davecheneythumper: menn0 https://github.com/juju/juju/pull/28502:24
thumperdavecheney: there are no tests?02:25
davecheneydon't appear to be02:25
thumperhow silly of me... a test would have shown it wasn't working02:25
davecheneydidn't run the whole test suite02:25
davecheneyjust go test ./juju/api02:25
thumperdavecheney: is there a quick test that could be written around that?02:25
davecheneythumper: no idea02:25
davecheneyhaven't looked at the tests in that code02:26
thumpercan you take a look?02:26
davecheneyhmm02:36
davecheneyso02:36
davecheneynone of our test fixtures have an environment-uuid: field02:36
davecheneyok, this is bigger than a quick branch02:39
davecheneylogging a bug02:39
* thumper is fighting side-effects in code being tested elsewhere02:42
davecheneyhttps://bugs.launchpad.net/juju-core/+bug/133996702:42
_mup_Bug #1339967: juju: cacheAPIInfo users the wrong tag when storing the environ UUID <juju-core:New> <https://launchpad.net/bugs/1339967>02:42
davecheneyits on the list02:42
davecheneyi don't want to get distracted02:42
thumperdavecheney: can play.golang.org do github imports?02:55
waigani_thumper: failed for me, maybe it does certain ones??02:57
davecheneythumper: no02:57
thumperfailed for me too...02:57
thumperok that is why02:57
waigani_func RunConfigureScript(script string, params ConfigureParams) error {02:58
waigani_logger.Debugf("Running script on %s: %s", params.Host, script)02:58
waigani_client := params.Client02:58
waigani_if client == nil {02:58
waigani_client = ssh.DefaultClient02:58
waigani_}02:58
waigani_cmd := ssh.Command(params.Host, []string{"sudo", "/bin/bash"}, nil)02:58
waigani_cmd.Stdin = strings.NewReader(script)02:58
waigani_cmd.Stderr = params.ProgressWriter02:58
waigani_return cmd.Run()02:58
waigani_}02:58
waigani_client is not being used at all ?!?!02:58
davecheneylooks that way02:59
waigani_hmph - I'll leave a question for the reviewer03:00
davecheneydoes that code even compile ?03:00
waigani_cloudinit/sshinit/configure.go:5203:00
waigani_yep, I have not touched it03:01
waigani_davecheney: ^03:01
davecheneyit's cos of the check03:01
davecheneythe if on line 5103:01
waigani_yep03:02
davecheneyhttp://play.golang.org/p/m4Z-kfxN3w03:02
davecheneyoh well03:02
thumperwhy oh why are so many of our tests so shit?03:02
davecheneythumper: you know that 383,000 lines of code ?03:03
davecheneythat's not a number i'm particularly proud of03:03
* thumper smirks03:03
waigani_I'm assuming they meant client.Command(... not ssh.Command03:05
davecheneywaigani_: yes03:06
davecheneylog a bug03:06
waigani_davecheney: I actually need to fix it for my branch - need to manually provision with a given key03:07
waigani_davecheney: should I still associate a bug with it and address it in my PR?03:08
davecheneywaigani_: if you're not going to fix it staight away03:15
davecheneylog a bug03:15
davecheneyso when you are on leave next week03:15
davecheneyit doesn't get lost03:15
menn0woot. I think I've reviewed everything that needs reviewing.03:35
menn0I'll keep an eye on the PR queue but ping me if there's anything that needs urgent review.03:36
thumperomg...03:36
thumperI found a test that tests something that can never happen...03:36
thumpereffectively it goes like this:03:36
thumperlook for the api end points03:36
thumpermake sure there are no addresses03:36
thumperif there are no addresses, connect to the api to find the addresses03:36
thumperreturn addresses03:36
thumperyay03:37
* thumper waves his hand03:37
thumpermagic03:37
thumperjuju magic03:37
* thumper sighs03:41
menn0thumper: the test does that and passes?03:41
thumpermenn0: well it mocks out the actual connection03:42
thumperto return values03:42
menn0right. so it's an unnecessary test.03:43
thumperyup03:45
thumperhere is a good error message: logger.Warningf("cannot failed to cache API addresses: %v", localerr)03:46
thumperdouble negative, so it worked, right?03:46
menn08-)03:51
thumperWT actual F?03:56
* thumper sighs03:56
* thumper holds in the rage and turns a little green03:56
thumperwhy, oh why would the environment uuid change on an api connection?03:57
thumperperhaps to save it?03:57
thumperwhen it wasn't before?03:57
thumperthat is the only consideration I can think of03:57
thumperdavecheney: if I have a function that is package private, but I also export the func in export_test.go using the BigName = smallName method03:59
thumperdavecheney: but the function takes an arg that is an unexported interface03:59
thumperdavecheney: is go going to complain?03:59
thumperor magically work?03:59
thumperas long as what I pass in matches?03:59
thumperhmm... unnecessary test is not entirely unnecessary04:22
thumperthere are other assumptions built int04:22
thumperin04:22
menn0thumper: while working on the schema migrations doc I think I've found a bug in the current upgrade mechanics04:42
thumperoh?04:42
menn0thumper: line 817 cmd/jujud/machine.go04:42
thumperthere04:43
menn0a variable holding an error is carefully created but is never used04:43
menn0and there's no tests that look for that error04:43
menn0so if upgrades fail we silently ignore the failure and everything keeps going as if the upgrade was successful04:43
thumperheh04:44
thumperoops04:44
thumperwe should probably fix that04:44
menn0I think the last return in runUpgrades should be "return err" not "return nil"04:45
thumpersurely there is a test...04:45
thumperthis was wallyworld_, so there should be a test04:45
menn0I searched for "cannot perform upgrade" in the entire tree and it's only mentioned in that function04:45
thumperhmm04:47
thumperwrite a failing test :)04:47
wallyworld_thumper: menn0: it wasn't me04:47
thumperone where the step always fails04:47
thumperand check04:47
wallyworld_it was roger :-P04:47
wallyworld_look at annotate :-)04:47
menn0will do. I know this bit of the code quite well now.04:47
thumperalso... should probably look at the upgrade error before the "failed to update agent version error"04:48
wallyworld_i suspect there hsould have been a baned return value04:48
wallyworld_named04:48
menn0wallyworld_: yep understood04:49
wallyworld_:-)04:49
menn0I think it might be clearer without a named return anyway04:49
menn0wallyworld_: what is currently the desired behaviour if a upgrade steps fail? it's 50/50 whether it's better to downgrade or pressing on with the new version depending on which upgrade steps have already run.04:51
menn0soon we will be able to rollback using the backup, but what do we expect right now?04:51
wallyworld_menn0: hmmm. we haven't really supported rollback till now. rollback is more than db, includes config also etc. we don't really handle upgrade errors very well.04:53
wallyworld_hard problem04:53
menn0wallyworld_: right and I'm trying to make that situation better.04:53
menn0wallyworld_: but given current limitations what do we do?04:53
wallyworld_error out and then the agent restarts04:53
menn0wallyworld_: or what /should/ we do is probably the better question04:53
wallyworld_try and recover04:54
* thumper is pulling gently on the end of a piece of string, but is just getting a big knot every time04:54
wallyworld_and restart the old agent04:54
menn0wallyworld_: ok. that seems about the best we can do.04:55
wallyworld_yeah04:55
menn0the old agent may not work because of changes made by upgrade steps for the next version but we can't do much better04:55
wallyworld_we can try and rollback the file changes04:55
wallyworld_but that may not work either04:55
menn0soon we will be recovering from the backup which has both the database and configuration files04:55
wallyworld_the thought was, if it fails, it's time to call juju support04:56
menn0got it04:56
wallyworld_great, look forward to that04:56
menn0wallyworld_: it was definitely rog's change... I just had a look and I can see exactly what happened.04:58
wallyworld_\o/04:58
* wallyworld_ makes mistakes too, but sometimes needs to defend his honour :-)04:59
wallyworld_especially since thumper implied there should have been a test :-)04:59
thumperwallyworld_: that is because you always supply tests for your work04:59
menn0although the lack of pre-existing tests for that error condition probably didn't help when rog refactored that code...04:59
wallyworld_yes :-)04:59
menn0:-p04:59
wallyworld_well, i didn't write the original either05:00
menn0just teasing05:00
wallyworld_the jujud upgrade stuff is separate from the upgrade steps stuff05:00
wallyworld_:-P05:00
* menn0 rolls up his sleeves05:00
* wallyworld_ takes the bait05:00
menn0;-)05:00
* wallyworld_ needs sleep, later05:00
thumpersuccess... just one failing test to fix05:40
* thumper is done for now05:40
thumpermeetings later05:40
thumpernight all05:40
=== uru-afk is now known as urulama
ChrisW1menn0: someone refactored untested code? tsk tsk05:57
menn0ChrisW1: indeed :)05:58
davecheneythumper: re that test, http://static.comicvine.com/uploads/original/11111/111119363/3792894-7922452111-tumbl.gif06:04
davecheneyit won't complain, but you won't be able to construct a value to pass to that function06:05
davecheneyhowever, if you have someone elses' value, that will work06:05
davecheneymenn0: re named return, hold that thought06:06
davecheneyit will be a good example for waigani06:06
davecheneymenn0: chrisw1, http://dave.cheney.net/2013/11/14/more-simple-test-coverage-in-go-1-206:07
davecheneymay be useful for figuring out which footguns are lacking their protective covers06:07
menn0davecheney: I'm not sure if this is the best sample for discussing named returns06:08
davecheneymenn0: what was the bug you found before ?06:08
menn0the code is hairy06:08
menn0not really about named returns06:09
davecheney:/06:09
menn0thumper or wallyworld were theorising that perhaps someone intended there to be named returns but there wasn't06:09
menn0at any rate, no named returns are being used06:09
menn0the bug is about an error not being returned06:10
davecheneyok06:10
menn0a line that says "return nil" when it should say "return err" (well actually it's more complex than that but that's the core of it)06:10
* davecheney moves on06:10
davecheney:~06:10
=== liam_ is now known as Guest5405
menn0frustrated email sent to juju-dev07:18
menn0I'm done for this week.07:18
menn0Back on Monday.07:18
TheMuemorning08:09
urulamai've just filed bug 1340077 (https://bugs.launchpad.net/juju-core/+bug/1340077) ... didn't find similar one, but maybe it already exists08:23
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:23
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:23
davecheney1340077 1340077 1340077 1340077 1340077 1340077 1340077 1340077 1340077 1340077 1340077 1340077 1340077 1340077 1340077 134007708:24
davecheney#134007708:24
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:25
davecheneyi wonder if mup is dumb enough to fall for that08:25
davecheney#1340077 #1340077 #1340077 #1340077 #1340077 #1340077 #1340077 #1340077 #134007708:25
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:25
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:25
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:25
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:25
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:25
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:25
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:25
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:25
_mup_Bug #1340077: if "default" is named to undefined env, the parsing fails <juju-core:New> <https://launchpad.net/bugs/1340077>08:25
davecheneyand the answer is, yes08:25
urulamaQED ;)08:25
* davecheney waves to urulama 08:25
davecheneywelcome to canonical08:25
urulamathanks08:25
urulamaoh, australia, good evening then08:27
davecheneyo/08:28
davecheneyi'm representing for the southen himsphere tonight08:28
* TheMue waves as antipode08:32
jamurulama: welcome. So how does one intend to pronounce "urulama" ? My first instinct is to read it as "you're a llama", but the intent could be something different09:03
urulamajam: :D :D09:04
urulamajam: never thought about that ... it's an old nick, so old that i don't thing about it, but maybe it is time to change it09:05
urulamajam: "ooroo"+"llama" would sound as we read it09:06
jamurulama: strong l or a y or a j sound ?09:06
urulamastrong L09:06
TheMuejam: urulama: maybe it’s the right time to have nicks in phonetics (thinking of international teams)09:22
urulamaTheMue: or in asciiart :D09:22
TheMueurulama: ;)09:24
TheMueso, mine is ðə mjuː09:28
urulamait's probably a known bug that autocomplet for debug-hooks in terminal returns charm/1 as charm is on machine 1, but hooks are connected only when "juju debug-hooks charm/0" is executed?09:32
urulamaon a amazon or manual env, not on local09:34
dimiterntasdomas`, I added some review comments to your ports PR10:15
=== psivaa-off is now known as psivaa
jamurulama: I haven't heard of it, so feel free to report a bug about autocomplete, as the first unit of a service is always 0, it shouldn't depend what machine it is on.10:38
TheMueso, https://github.com/juju/juju/pull/281 is back in for review10:43
jamTheMue: dimitern vladk|offline standup?10:45
urulamaone more bug 134013310:53
_mup_Bug #1340133: debug-hooks don't work in manual env <juju-core:New> <https://launchpad.net/bugs/1340133>10:53
jamurulama: whenever I read your name my first response is "nu-uh, *you're* a llama" :)11:02
=== urulama is now known as uru_
uru_damn, taken11:02
=== uru_ is now known as uru-urnotallama
uru-urnotallamajam: better? :D11:03
TheMue*rofl*11:03
jamuru-urnotallama: :)11:04
=== uru-urnotallama is now known as urulama
jamdimitern: so you're gone from tomorrow for 2 weeks/11:11
jamah, that's next week11:11
dimiternjam, yep, next week11:11
tasdomas`dimitern, thanks11:31
=== urulama is now known as uru-afk
=== uru-afk is now known as urulama
* dimitern needs to step out now, bbl12:31
=== tasdomas` is now known as tasdomas
tasdomasare pull requests for packages like github.com/juju/names managed by a landing bot or do I just merge them myself (having received an LGTM)12:44
tasdomas?12:44
perrito666morning12:44
TheMueperrito666: morning12:45
TheMueperrito666: we’ll see on Sunday, ha? :D12:45
perrito666TheMue: I return home on sunday, I will most likely sleep trough the game12:45
TheMueperrito666: hey, you cannot do that, you’ll see  how our team beats yours :P12:46
perrito666I care as much for football as I do for ... I think there is nothing I care that little about :p12:48
TheMueperrito666: hehe, in that case12:50
bodie_morning all13:37
mgzbodie_: hey13:39
davecheneymbruzek: hey13:41
mbruzekdavecheney, hello13:41
davecheneymbruzek: did you see my update on taht issue13:41
davecheneydo you have the dmesg from that system13:42
mbruzekyes I uploaded dmesg13:42
* davecheney checks email13:42
davecheneyhmm, nup13:42
davecheneynothing13:42
mbruzekhttps://bugs.launchpad.net/ubuntu/+source/gccgo-4.9/+bug/1304754/comments/3513:43
_mup_Bug #1304754: gccgo has issues when page size is not 4kB <ppc64el> <trusty> <gcc:Fix Released> <gcc-4.9 (Ubuntu):Fix Released> <gccgo-4.9 (Ubuntu):Invalid> <gcc-4.9 (Ubuntu Trusty):Invalid> <gccgo-4.9 (Ubuntu Trusty):Fix Committed by doko> <gcc-4.9 (Ubuntu Utopic):Fix Released> <gccgo-4.9 (Ubuntu Utopic):Invalid> <https://launchpad.net/bugs/1304754>13:44
mbruzekdavecheney, ^13:44
davecheneymbruzek: it's empty13:45
mbruzekdavecheney, Sorry take the comments/35 off13:45
mbruzekthe bug was updated with my dmesg_output.txt  I thought I would be clever by showing you on which comment, but I left no messages on file upload.13:46
davecheneymbruzek: thanks13:46
davecheneyok, so it's not the usual issue13:46
davecheneydmesg shows no issue13:46
TheMuewife bought strawberry cake, daughter made a tea - a very good working environment13:58
* perrito666 finds another race15:20
wallyworld_axw: if you want a break from mongo fun https://github.com/juju/juju/pull/28815:22
katcoAWS question: does anyone know if there's any documentation on what version of signature each region supports?15:26
natefinchkatco: not sure what you mean version of signature15:28
katcoyeah, sorry: http://docs.aws.amazon.com/general/latest/gr/signing_aws_api_requests.html15:29
katcothey support v2, 3, and 415:29
katcoand i'm trying to introduce support for 4; turns out it's important to know which region supports which15:29
wallyworld_sinzui: \o/15:42
natefinchkatco: man, that is a terrible name for ... well anything.15:43
natefinchwallyworld_: btw, A/C people still not here :/  Supposed to be here between 10 and noon, so the clock is ticking15:43
katconatefinch: mm? what's a terrible name?15:43
wallyworld_natefinch: np. we'll try not to eat *all* the kunch15:44
wallyworld_lunch15:44
natefinchkatco: "SIgnature"15:44
katconatefinch: ah15:44
katconatefinch: context increase IQ by 100% ;)15:44
perrito666natefinch: so much for "they usually come here first"15:45
natefinchperrito666: Usually they end up coming early.  I guess they found out I'm not actually supposed to be working from home today, so decided to come late15:46
perrito666natefinch: sounds possible15:46
natefinchThere have been a couple times they have simply not shown up.  But I called at 11 to make sure they hadn't just left me off the list this time.15:46
sinzuiwallyworld_, the 1.20.1 final test run and the 1.20.2 first test run were the two best runs CI has seen in 6 weeks. In both cases every test passed the first try. The entire run was less than 2 hour each15:48
wallyworld_wow, awesome15:48
jcw4is there a juju / charm acolyte who might be able to help breze441 in #juju ?15:59
jcw4I tried to prime the pump a bit since his question was vague, but I think there's enough detail now that someone who knows juju/charms better may be able to help with?15:59
natefinchkatco, axw: btw, I pinged niemeyer about moving goamz to github, since some Go people had been asking about which version they should use - launchpad's or the dozens of copies on github.16:05
alexisbsinzui, good stuff on 1.20.1, thanks for getting it out there!16:14
sinzuithank you alexisb16:15
=== urulama is now known as uru-qfk
perrito666natefinch: got ac?16:32
axwnatefinch: thanks, I think that'd be a good idea.16:35
=== uru-qfk is now known as uru-afk
katconatefinch: +1, ty16:37
natefinchperrito666: they're here, but it's not fixed yet16:50
perrito666natefinch: well its something16:50
natefinchperrito666: yeah, but I fear the person they sent is not their most competent at diagnosing problems.  They have like 3 really good technicians and a bunch of flunkies that are not that great16:54
* perrito666 wonders if we cannot fix that, there are like 8 of us here17:04
voidspacerogpeppe: ping17:12
voidspacerogpeppe: are you around?17:12
rogpeppevoidspace: hiya17:12
rogpeppevoidspace: that i am17:13
voidspacerogpeppe: hey Roger, hi17:13
voidspaceI'm in Lexington17:13
rogpeppevoidspace: cool17:13
voidspacerogpeppe: I have a question about HA17:13
rogpeppevoidspace: fire away17:13
voidspacerogpeppe: should all writes go to mongo master - and does that mean that only the machine hosting the mongo primary should do writes, or do the other state servers connect remotely to the primary?17:14
voidspaceor does it mean something else17:14
voidspacewhat I'm seeing, which surprised me, is that after "ensure-availability" the machine with JobManageEnviron is not the Primary mongo17:14
rogpeppevoidspace: if you connect to a mongo secondary, it will automatically make a connection to the primary and send writes there17:14
voidspacecool17:14
voidspaceso we don't need to worry about that17:14
rogpeppevoidspace: after ensure-availability, there should be 3 machines with JobManageEnviron17:15
voidspacethey should all have JobManageEnviron, ok17:15
rogpeppevoidspace: and the choice of primary is entirely up to mongo17:15
voidspacehmmm... my machine 1 only listed JobHostUnits in its agents.conf17:15
voidspacerogpeppe: I'm looking at the behaviour of HA when mongo dies but juju itself remains running17:16
rogpeppevoidspace: when a majority of replicas die?17:16
voidspaceno, just when a single one dies17:16
rogpeppevoidspace: it *should* just carry on working17:16
rogpeppevoidspace: although there will be some churn17:17
voidspaceright, but the now "effectively dead" machine is still listed as a valid apiserver17:17
voidspacewhen in fact it is screwed17:17
rogpeppevoidspace: api servers will restart, clients will also need to reconnect17:17
voidspacebut things do still work17:17
voidspaceI'm trying to determine what doesn't work and what we need to fix17:17
voidspaceso yes, api servers will need to restart - but it doesn't look like they do17:18
voidspacebut it's only a minor issue I think17:18
voidspacethe replicaset configuration still lists the dead machine as in the replicaset17:19
voidspace(the mongo rs.conf() that is)17:20
rogpeppevoidspace: the dead machine will still remain in the replicaset until you run ensure-availability again17:23
voidspaceright17:23
voidspacerogpeppe: when you run ensure-availability the first time, and mongo picks a master, will the singular workers stop running on machine-0 and start running on the master (assuming machine-0 is no longer the master)?17:24
rogpeppevoidspace: yes, they should do17:24
voidspacerogpeppe: ok, great17:24
natefinchwell fuck, A/C guys say the $800 worth of refrigerant they put in the system is gone and we need a new system.  Fantastic.17:26
voidspacenatefinch: ouch :-/17:26
voidspace:-(17:26
natefinchthat was like 2 months ago they put that in, too.  Put in some "leak stop" stuff too.  Getting a second opinion in the morning, but... I think it's new A/C time... which means like $8,00017:27
natefinchanyway, coming into the office17:27
perrito666natefinch: f*** shouldn't they give you some refund on that? I mean they added refrigerant when they shouldn't17:27
wallyworld_natefinch: and wwitzel3 ate all the lunch17:27
natefinchthat's ok17:27
natefinchI had cake for lunch17:27
perrito666uh, can we have cake?17:29
voidspacerogpeppe: my machine-1 agents.conf only lists JobHostUnits under jobs, whereas as machine-0 (my current master) lists JobManageEnviron too17:30
voidspace*agent.conf (singular)17:30
rogpeppevoidspace: and machine 1 was created by ensure-availability?17:30
voidspaceyep17:30
voidspaceit also lists three api addresses when there are now only two state servers17:31
voidspaceand machine-2 agent.conf - which *was* master  - also only lists JobHostUnits17:32
rogpeppevoidspace: i don't believe that machine was created without JobManageEnviron17:32
rogpeppevoidspace: what's the output of juju status?17:33
voidspacerogpeppe: http://paste.ubuntu.com/7776326/17:34
rogpeppevoidspace: i see that all of machines 0, 1 and 2 are voting17:35
rogpeppevoidspace: that means that they're part of the intended replica set17:35
voidspacerogpeppe: but agent state of 2 is down17:35
voidspaceI took down mongo first17:35
voidspaceagent.conf on the other machines didn't change17:35
voidspaceI took down jujud as well17:35
rogpeppevoidspace: sure, you can be down and still have a vote17:35
voidspacestill no change (that I could see)17:35
voidspacebut it is also still listed as a valid api server17:36
voidspaceeven though it is down17:36
voidspacebut the master change worked fine17:36
rogpeppevoidspace: all those machines definitely have JobManageEnviron, BTW17:37
voidspacenot listed in agent.conf they don't :-)17:37
voidspacebut I believe you17:37
voidspaceso it's a bit odd17:38
rogpeppevoidspace: for my proof, see cmd/juju/status.go:32317:39
rogpeppevoidspace: it's odd that that's not in agent.conf though17:39
rogpeppevoidspace: that sounds like some kind of bug17:39
voidspacerogpeppe: http://paste.ubuntu.com/7776354/17:40
voidspacerogpeppe: machine 1 is the same17:40
voidspacemachine-0 also lists JobManageEnviron17:40
voidspacerogpeppe: ok, so it's an oddity (probably a bug) but not significant17:41
voidspacerogpeppe: thanks17:41
rogpeppevoidspace: well, it may well be significant17:41
voidspacehah, ah17:41
voidspaceok17:41
voidspaceif you take down the mongo on the master then the master does switch, but jujud carries on running on the "old master"17:47
rogpeppevoidspace: jujud will always continue running17:50
rogpeppevoidspace: it runs on every machine17:50
voidspacerogpeppe: what would you expect a juju that can't connect to mongo to do?17:51
rogpeppevoidspace: BTW, AFAICS the Jobs in the agent config isn't used at all17:51
voidspacerogpeppe: right17:51
voidspacegood17:51
voidspacerogpeppe: I'm still wondering what writes it out and why it's wrong, but I can look for that17:51
rogpeppevoidspace: i'd expect a juju that can't connect to mongo to sit around trying to connect to mongo17:51
voidspacerogpeppe: hah, ok :-)17:52
voidspacerogpeppe: I think juju behaves fine when we kill mongo17:55
rogpeppevoidspace: good!17:55
voidspaceit doesn't rewrite agent.conf in the way perrito666 and I thought it should17:55
voidspacebut I don't think that's a problem17:55
rogpeppevoidspace: nice to know that something works :-)17:55
voidspacethe machine log shows it stopping all the things it should I believe17:56
voidspacehah17:56
voidspaceindeed :-)17:56
voidspaceso I'm going to close that bug....17:56
rogpeppevoidspace: ha, i've found the cause of the bad Jobs17:58
rogpeppevoidspace: i think17:58
rogpeppevoidspace: in environs.NewMachineConfig17:58
perrito666rogpeppe: I am pretty sure that I can fit an apple joke in there17:58
rogpeppevoidspace: the Jobs are always set to JobHostUnits17:58
rogpeppeperrito666: arf arf17:58
* rogpeppe actually doesn't laugh, because a reference to a joke is not the same as the joke itself17:59
rogpeppe:-)17:59
voidspacehah17:59
perrito666rogpeppe: fine *(rogpeppe: I am pretty sure that I can fit an apple joke in there)18:00
* rogpeppe is still waiting for a joke18:00
voidspacerogpeppe: so the machine actually has the ManageEnviron job, but we assume that a new machine only has host units (which was the case before HA) and so that's what we put in MachineConfig18:00
rogpeppevoidspace: yup18:00
voidspacerogpeppe: you just have to dereference it yourself18:00
voidspacerogpeppe: could this be a potential problem? (not the apple joke)18:01
voidspacerogpeppe: let me hedge my bets a bit more18:01
rogpeppevoidspace: currently no18:01
voidspacewould it be fair to say that it's reasonable to assume that perhaps this could be a potential problem, at least in theory18:01
rogpeppevoidspace: the plan was always to allow a machine to change its jobs18:01
voidspaceok18:01
rogpeppevoidspace: so a machine would populate its own machine config's Jobs field18:02
perrito666rogpeppe: a skelton enters a bar and he says: bartender, please give me a whisky and a mop18:02
voidspaceI'd tell you a udp joke, but you wouldn't get it18:02
* rogpeppe laughs at both of those18:03
rogpeppealthough i'd heard the udp one before18:03
voidspaceI know another udp joke, but I can't tell that one either - it's a bit out of order18:03
voidspaceyeah, old18:03
rogpeppevoidspace: pm me :-)18:03
voidspacerogpeppe: no, that was the joke...18:03
rogpeppeoh sod18:04
rogpeppe:-)18:04
* rogpeppe lols a little more18:04
=== uru-afk is now known as urulama
bodie_I'm really excited that Elon Musk donated $1 million to the new Tesla museum in NY18:57
bodie_I sure hope they take things far18:58
urulamacan juju-test be run with a parameter to .test file?19:08
mgzvoidspace: https://bugs.launchpad.net/juju-core/+bug/130743420:11
_mup_Bug #1307434: talking to mongo can fail with "TCP i/o timeout" <cloud-installer> <landscape> <performance> <reliability> <juju-core:Triaged> <https://launchpad.net/bugs/1307434>20:11
stokachuanyoen know if the ServiceDeploy api call takes 'lxc:1' as its ToMachineSpec? I can't seem to get it to work20:17
stokachuor do i have to add machine first20:17
natefinchstokachu: juju help deploy will give you the format.   What are you trying to get it to do?20:26
stokachudeploy to an lxc container on machine 120:27
natefinchstokachu: before machine 1 exists, I take it?20:28
stokachunatefinch, no machine 1 exists20:28
natefinchstokachu: oh, hmm. lxc:1 should work....20:30
stokachuis the param syntax still {'ToMachineSpec': 'lxc:1'}20:31
natefinchstokachu: yeah - https://godoc.org/github.com/juju/juju/juju#DeployServiceParams20:33
stokachuhmm ok i must be doing something wrong with the api call20:33
rogpeppeg'night all20:36
stokachunatefinch, if you don't define a NumUnits it just deploys the charm but never attaches itself to a machine20:46
stokachushouldnt that give us an error or some indication in the json response?20:46
natefinchyeah, it's a little wacky since numunits would default to 0, which is not really a valid value in any sense of the words20:48
natefinchit should probably complain, yeah20:49
natefinchor default to 1 for numunits < 120:49
stokachuyea20:49
stokachutook me awhile to figure out why the ServiceDeploy api call wasn't associating a machine20:50
thumperwallyworld_: sorry about missing the resources meeting, but 7am meetings after my late night lead ones isn't a good time20:55
thumperwas too out to it20:55
wallyworld_thumper: np, we didn't need you anyway :-P20:56
thumpergood20:56
wallyworld_thumper: i can ping you a bit later and fill you in20:56
thumpersure20:57
natefinchstokachu: the CLI stops you from using num units < 1.. the api should, too21:00
stokachuif i dont define num units it'll just deploy the service with no machine21:00
natefinchstokachu: yeah, that's a bug.  We haven't really put a lot of effort into making the API foolproof, unfortunately.21:02
stokachuill file a bug for it to track then21:02
perrito666natefinch: that should blow at a lower level21:03
natefinchstokachu: thanks21:03
perrito666natefinch: sounds like something that we will never want to allow so making that check should not happen in the borders21:04
perrito666s/borders/edges21:04
natefinchperrito666: yep21:05
natefinchperrito666: no sense having that kind of logic in more than one place21:05
thumperwallyworld_: dog got in a bit of a fight last night, off to the vet in just under an hour, she won't put weight on one of her legs :-(21:06
wallyworld_oh :-(21:06
wallyworld_hope she's ok21:06
thumperso do I21:06
thumpershe isn't behaving normally21:06
wallyworld_:-(21:07
thumperwas at the vet yesterday for ear infection21:07
wallyworld_$$$$$$21:07
thumperwhich may have made her a little short tempered21:07
* thumper nods21:07
wallyworld_i'll ping you later after dinner here21:07
wallyworld_thumper: what do you mean by "name connection"?21:12
thumperwallyworld_: we are going to have 'juju connect' and use the name "connection" to refer to a particular thing21:13
wallyworld_thumper: this work will eventually kill the need for Environ to have to be able to provide mongo addresses21:13
thumpera connection is to an environment within a juju server as a user21:13
thumperwallyworld_: I'm happy that there is MongoInfo21:13
thumperI was just saying I didn't like axw's suggestion of calling it ConnectionInfo21:14
wallyworld_thumper: so Environ interface has StateInfo() returning a MongoInfo() and APIInfo()21:14
wallyworld_the MongoInfo return value will go away21:14
thumperbecause an Environ doesn't need it?21:15
axwthumper: yeah agreed, I mostly just didn't like the inconsistency21:15
wallyworld_Environ has no business knowing how the state persistence layer connects to mongo21:15
thumperaxw: fair enough, consistency ftw21:15
thumperwallyworld_: agreed21:15
wallyworld_and i am about to propose a branch the means it doesn't have to21:15
wallyworld_thumper: you will be happy also with stuff that is being done to unpick State, will fill you in later21:16
thumperwallyworld_: ack21:16
thumperwallyworld_: next week is fine21:16
wallyworld_ok21:16
dpb1Hi all -- 1.20.1 + latest maas:  anyone seen this? http://paste.ubuntu.com/7777233/ (line 88)21:39
thumperdpb1: not seen it, but I don't test maas21:49
* thumper off to the vet again21:50
=== thumper is now known as thumper-afk
=== bodie_ is now known as Guest89392
dpb1thumper: OK... anyone else seen it? :)21:58
=== Guest89392 is now known as bodie_
=== thumper-afk is now known as thumper
waiganithumper: https://github.com/juju/juju/pull/28922:53

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