/srv/irclogs.ubuntu.com/2018/07/04/#juju.txt

veeberswallyworld_: you have a couple moments? What's the best way to expose a controller config to a cmd? (i.e. https://github.com/juju/juju/blob/develop/cmd/juju/application/deploy.go#L248)01:14
veeberswallyworld_: oh, something along the lines of getting an APIContext which we can then use to communicate with the controller and retrieve the needed info?01:17
thumperwallyworld_: https://github.com/juju/juju/pull/888802:51
thumperor anyone really...02:55
veebersthumper:lgtm03:04
thumperveebers: thanks03:04
wallyworld_sorry thumper was distracted with #@%#$$#@ k8s storage03:05
thumperwallyworld_: that's fine, veebers has sorted it03:06
veeberswallyworld_, thumper: Is this the right direction to head for having a boostrap config for charmstore url and being able to access it in a command context? (i.e. the deploy command creates a charmstore client and needs to know that url)03:17
veebersoops, and the actual link: http://paste.ubuntu.com/p/nWMGhGff7s/03:17
thumperI think we need to be very clear about the behaviour we are expecting03:18
thumperin the difference between client and server aspects03:19
thumperI don't think we should be looking at bootstrap config to determine this03:19
thumperfor the client side, I'd much rather just use an environment variable to override the behaviour03:19
thumperfor Juju, it should be controller config03:19
thumperwallyworld_: thoughts?03:20
thumperhmm...03:22
thumperwe have a --reset for model-config but not controller-config03:22
wallyworld_um03:22
wallyworld_yes controller config server side03:23
wallyworld_but at bootstrap, it can be passed in to bootstrap command03:23
wallyworld_using the existing controller config mechanism03:23
wallyworld_it's not a deploy command thing03:23
wallyworld_it's set once only at bootstrap03:23
wallyworld_and for now is immutable03:24
wallyworld_if you try and mutate itvia reste or whatever, you will get an error, like for api port03:24
thumperdo any client side things need to know or care about this value?03:26
wallyworld_not sure, but if so they get it via controller config03:26
thumperno...03:26
thumpera client wouldn't necessarily have access to it03:26
wallyworld_all clients can get controller config03:27
wallyworld_via the controller facade03:27
wallyworld_we already do that in places03:27
wallyworld_can't recall where off hand03:27
thumperdo we really want to add another api call to all call sites?03:27
thumperhmm..03:27
* thumper thinks03:27
thumperwe probably don't want a client side environment variable03:28
wallyworld_no, i don't think so03:28
thumperif we are thinking about  enterprise charm stores03:28
veeberswallyworld_: I cribbed some of that code from destroy command (i.e. func (c *destroyCommandBase) getControllerEnvironFromStore() )03:28
thumperveebers: we can't rely on the store03:28
thumperbecause most users won't have it03:28
wallyworld_the deploy command does go tto store and gets the charm and then uploads to controller03:28
wallyworld_i think03:28
wallyworld_deploy and controller should use the same store03:29
thumperwhere store here refers to the charmstore03:30
wallyworld_for enterprise case where store is behind firewall, i think it's reasonable that deploy client has access to that store03:30
thumperand not the local config store03:30
wallyworld_yes03:31
thumpertoo many things have the same name03:31
wallyworld_state03:31
thumperapi03:31
thumperbackend03:31
wallyworld_client03:31
thumper:)03:31
wallyworld_veebers: so we don't get store url from bootstrap config since that's only present on that one client used to bootstrap03:32
thumperveebers: where is the tip of the 2.4 branch going to appear in snaps?03:33
wallyworld_i think it takes about 4 hours03:33
wallyworld_edge03:33
wallyworld_oh wait03:33
thumperwallyworld_: edge is tip of develop03:33
wallyworld_2.5 is current03:33
wallyworld_misread03:33
veebersthumper: working with vino to get that job deployed03:33
* thumper nods03:33
thumperwill it be in candidate?03:34
thumperor beta?03:34
* veebers checks the job03:34
vinoveebers: see the canonical #juju03:35
veebersthumper: just checking the config. Vino sweet, just getting an answer for Tim ^_^03:37
veebersthumper: candidate03:41
veebersphew that took longer than it should have ^_^03:41
thumperveebers: thanks03:41
veeberswallyworld_: sorry was distracted. Ok, what's the best way to proceed, i.e. I need the cs url to use in the deploy command (and others) but can't (or won't) get it from controller config03:42
wallyworld_why not from controller config?03:43
wallyworld_that would be the single source for that info03:44
veeberswallyworld_: ah sorry, I misread bootstrapconfig. Yeah controller config is fine, in that diff I pasted I'm using a controllerConfig from the bootstrapConfig. Or is that code not doing what I think it is?03:44
wallyworld_the pastebin is getting stuff from local yaml files03:45
wallyworld_you need to go to the controller itself to ask for its config03:46
wallyworld_there's only 1 place i think we currently do that from the cli, which is the controller config (get) command03:47
veeberswallyworld_: ah is that the ClientStore? a local cache of info?03:47
veeberswallyworld_: ah right, and that's a ControllerCmd03:47
wallyworld_right, ClientStore is a local cache of stuff03:47
wallyworld_bootstrapconfig is stored locally as yaml but it really needs to die with fire03:48
wallyworld_it's there because reasons. mostly restore -b which we don't even support anymore03:48
wallyworld_so we should be able to get rid of it03:48
veeberswallyworld_: ack, I'll not use it then lest you come knocking at my door with matches03:49
veeberswallyworld_: I'll sort out having a way to hit the controller for that info03:49
wallyworld_look at the controller/config.go command03:50
wallyworld_there's an api facade which provides the info03:50
veeberscan do03:52
veeberswallyworld_: as in check out cmd/juju/controller/configcommand.go?03:54
wallyworld_yeah03:54
veeberssweet, did skim that before I'll dig in03:55
thumperveebers, vino: how soon do you think we'll see 2.4.1 proposed snaps in candidate?04:03
veebersthumper: I think vino is just about to update the job, we can fire it off anytime from then (or if it's needed *now* we can manually edit the job). Then I'm not sure how long it takes for LP to recognise the updated branch, build and publish> I can't imagine too long though04:05
veebers(30 min - an hour or so?')04:06
* thumper nods04:06
thumperok, thanks04:06
veebersthumper: vino is still getting grief from JJB, I can manually edit the job now if you want that process in motion04:11
veebersthumper: fyi I updated the job and fired it off now, will have to wait for the LP parts to do it's magic04:19
thumperack04:19
axw_congrats on the 2.4 release! :)04:58
veebersthumper: FYI snap candidate has been published, now 2.4.1+2.4-b5eced605:00
wallyworld_axw_: thanks, hopefully it will work well for folks. how's things with you?05:06
axw_wallyworld_: pretty good thanks. published the first (beta) release of the APM Go agent recently. nothing very exciting otherwise :)05:22
=== axw_ is now known as axw
veebershey axw o/ Congrats on the release ^_^05:23
axwthanks :)05:23
axwone of these days I'd like to hook it up to Juju05:24
veeberswallyworld_: something more along these lines? http://paste.ubuntu.com/p/GhBPvWcFBB/05:39
manadartstickupkid: Going to merge #8882 ?08:02
stickupkidmanadart: i was having issues with CI yesterday08:24
stickupkidmanadart: seems it's fixed08:24
manadartstickupkid: Ja.08:24
thumpermanadart: https://bugs.launchpad.net/juju/+bug/177989708:32
* thumper bugs and leaves08:32
mupBug #1779897: container already exists <cdo-qa> <foundations-engine> <juju:Triaged by rharding> <https://launchpad.net/bugs/1779897>08:32
manadartthumper: Saw it; will look presently.08:36
rathore_Hi all, one of my charm fails in install hook and logs show "DEBUG install FileNotFoundError: [Errno 2] No such file or directory: 'config-get'" I tried to see and this seems to be provided by juju to charms. What could be wrong09:27
magicaltroutbeen a while13:29
magicaltroutfor standard charms whats the sanest way to add some apt dependencies to install at build time?13:29
magicaltroutlayer apt or is there some stuff you can stick in layer.yaml i seem to recall13:29
rick_h_maaudet: I just assumed folks used the apt layer13:30
rick_h_err magicaltrout that is ^13:30
rick_h_magicaltrout: as it handles some cases ok for you like already installed/etc13:31
maaudetI created the bug report about yesterday's issues with MongoDB in an HA context: https://bugs.launchpad.net/juju/+bug/178008613:33
magicaltroutfair enough13:33
mupBug #1780086: MongoDB connection errors after juju enable-ha <aws> <enable-ha> <mongodb> <juju:New> <https://launchpad.net/bugs/1780086>13:33
rick_h_ty maaudet, I'll replicate it here and check it out.13:49
manadartstickupkid: Can you review https://github.com/juju/juju/pull/8891 ? It's a tiny one.14:50
stickupkidmanadart: sure nps14:50
stickupkidmanadart: done14:53
manadartstickupkid: Thanks. While you are there, this one backports all the same commits with preamble to 2.4: https://github.com/juju/juju/pull/888914:54
maaudetrick_h_: Thanks for looking it up! Do you you think that this warning has it's place since it's basically never going to work, but works through another address?15:02
rick_h_maaudet: I've been pondering it. I mean, it's good to know if you're expecting it to work, but of course in this situation I know it won't. However, we've not done things like specify to Juju "your traffic should be on X" so that if it can't/won't do that it knows that's a real error15:03
rick_h_maaudet: but on the other hand, warning that all's working ok isn't helpful15:03
rick_h_maaudet: so I'm not sure the best way forward. I feel like what it needs is better visibility that HA is up and in a happy state and if that's true...well then ignore these. Maybe they're debug messages vs warning level.15:04
maaudetrick_h_: Yeah, it should probably have something like (1/3 connections successful to the target machine) or something like that appended to the warning15:04
rick_h_maaudet: yea, the logging is coming deeper in the code so it's that bubbling/aggregating that would need to be done in some fashion15:04
rick_h_maaudet: it's basically the mongo driver code trying to connect, failing, and erroring down there without knowing there is other connections goin15:05
maaudetrick_h_: I see. That explains it.15:05
rick_h_maaudet: yea, I mean you're totally right it's just more work :)15:07
stickupkidmanadart: LGTM - just a question about this really - https://github.com/juju/juju/pull/8889#discussion_r20015383715:08
stickupkidmanadart: PR review - https://github.com/juju/juju/pull/8893?15:47
stickupkidmanadart: this one moves the old logging, to the new container package.15:47
manadartstickupkid: Looking.15:52
rick_h_thanks for landing that stickupkid16:44
rick_h_maaudet: so in looking we have this bug on the error notifications: https://bugs.launchpad.net/juju/+bug/164401116:47
mupBug #1644011: juju needs improved error messaging when controller has connection issues <usability> <juju:Triaged> <https://launchpad.net/bugs/1644011>16:47
rick_h_maaudet: so I noted that while we're in there fixing the error UX we should also hit up the warning on regular working since we'll have to be in the same area cleaning that up16:47
stickupkidmanadart: https://github.com/juju/juju/pull/8894 PR, but I'm not sure this is right - so feedback would be appreciated :D17:17
magicaltrouti know marco has told me this once before18:48
magicaltroutif i'm writing a charm and want to save state between runs so I can compare last run to this run18:48
magicaltrouthow do I store it?18:48
magicaltroutconfig works, but i'm wanting internal storage not config.yaml hopefully18:49
rick_h_magicaltrout: hmm, I'm not sure. Most folks are out with the big US holiday today18:51
rick_h_magicaltrout: https://charmsreactive.readthedocs.io/en/latest/charms.reactive.helpers.html#charms.reactive.helpers.data_changed ?18:52
magicaltroutyeah not that i was poking through the docs trying to remember18:53
magicaltroutno problem18:53
magicaltroutdata changed just tells you if something changes18:53
magicaltroutnot what18:53
magicaltroutthere is some KV mechanism somewhere IIRC18:53
rick_h_magicaltrout: right but you can stick the data you want to track into that can't you?18:53
rick_h_magicaltrout: I mean it takes the data to track as an argument?18:54
rick_h_magicaltrout: oic, you want the state itself vs arbitrary data18:54
heckles1000hello everyone, I'm experiencing some oddities ... trying to figure some things out with basic relations18:54
heckles1000as you can see here https://paste.ubuntu.com/p/dRcCF9ygpz/18:54
magicaltroutmostly, I'm trying to reconstruct a config file rick_h_ when a relation changes18:54
magicaltroutbut the config is made up from data from a bunch of relations18:55
heckles1000(preface I am just testing a redis <-> test charm relation here)18:55
magicaltroutso its brining the values from a range of relatinos back to a single config18:55
rick_h_heckles1000: k, nothing looks odd there so far. What's up?18:56
rick_h_magicaltrout: oh hmmm...18:56
magicaltroutwhy did you get the short straw rick_h_ ? you secretly wish the british were still in change? ;)18:56
heckles1000https://github.com/chrisheckler/layer-redis-test/blob/master/reactive/redis_test.py#L19,L3418:56
heckles1000I'm thinking I can make this handler only execute 1 time by gating with my own custom flag18:57
rick_h_magicaltrout: meh, mid-week holiday :( so swapped it out for friday so I can head to the lake earlier18:57
heckles1000https://github.com/chrisheckler/layer-redis-test/blob/master/reactive/redis_test.py#L20 - this is the flag18:58
heckles1000even though I set it at the end of the handler, it seems the handler still executes 3 times18:58
rick_h_heckles1000: right, you can use your own flags and just set it once the method runs and it'll gate future executions of it18:59
rick_h_heckles1000: hmm, what's the trigger stuff about? /me looks up the trigger stuff18:59
heckles1000oh, I should take that out19:00
heckles1000or push my current code19:00
heckles1000my b19:00
heckles1000I'm trying to eliminate this handler from executing > 1 time19:00
heckles1000https://paste.ubuntu.com/p/h8hhP9D2Qz/19:00
heckles1000if I login to the machine and cat the file I'm writing to, you can tell the handler has ran multiple times19:01
rick_h_heckles1000: I'd drop some log lines in to help diagnose why it's rerunning. You should be able to add logs to check the status of the flags, etc. I see you unset it in the broken handler. Maybe that got triggered somehow?19:02
rick_h_heckles1000: check out the hookenv.log and see if you can narrow it down19:02
heckles1000ok19:02
rick_h_heckles1000: the trigger thing I think definitely needs to go as that should be global in the file and not rerun on multiple function runs19:02
heckles1000ahh, ok, I was reading the trigger docs and it shows ithem in the handlers19:03
rick_h_yea, I do see that as well. I don't get why you'd let there be an option to create the trigger several times though.19:03
rick_h_maybe it makes sure not to I guess...19:03
heckles1000yeah, I'm a bit confused there, I was thinking I might use it to ensure my handler only runs once19:04
heckles1000let me see if I can slim this down any19:04
heckles1000rick_h_: does this look better https://github.com/chrisheckler/layer-redis-test/blob/master/reactive/redis_test.py19:09
rick_h_heckles1000: yea, seems reasonable19:10
heckles1000rick_h_: seems to be working as intended now, thanks for the insight19:13
rick_h_heckles1000: awesome19:13
thumpermorning team20:22
rick_h_morning thumper20:22
bdxare you guys seeing the goal state errors on unit with remote relations?20:41
bdxhttps://paste.ubuntu.com/p/Rpb2R93VgM/20:41
bdxI filed this https://bugs.launchpad.net/juju/+bug/178015420:43
mupBug #1780154: goal-state error on remote relation <juju:New> <https://launchpad.net/bugs/1780154>20:43
rick_h_bdx: not sure about that. I'm not sure how much you can know about the remote end20:43
rick_h_bdx: k, I'll bring it up on afternoon calls20:43
bdxcool, thx20:43
thumperoh...21:11
thumperit certainly shouldn't error21:11
thumperbdx: thanks, thrown it at wallyworld21:13
bdxnp, thank you21:47
veeberswallyworld: It's probably bad taste to add to ModelCommandBase something like GetControllerConfig, or GetCharmstoreAPIURL right, perhaps I should just add the helpers to the commands that need ti (deploy and upgradecharm so far)23:06
wallyworldveebers: still otp, one sec23:06

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