Expand logging of failed registry.Job calls

whoah, things are getting a little hostile


On Tue, Jul 1, 2014 at 1:04 PM, Brian Waldon <notifications@github.com>
wrote:

> In agent/agent.go:
>
> > @@ -470,12 +455,23 @@ func (a *Agent) bidForPossiblePeers(jobName string) {
> >  	for _, peer := range peers {
> >  		log.V(1).Infof("Found unresolved offer for Peer(%s) of Job(%s)", peer, jobName)
> >
> > -		peerJob := a.fetchJob(peer)
> > -		if peerJob != nil && a.ableToRun(peerJob) {
> > -			a.bid(peer)
> > -		} else {
> > -			log.V(1).Infof("Unable to bid for Peer(%s) of Job(%s)", peer, jobName)
> > +		peerJob, err := a.registry.Job(peer)
> > +		if err != nil {
> > +			log.Errorf("Failed fetching Job(%s) from Registry: %v", peer, err)
> > +			return
> > +		}
> > +
> > +		if peerJob == nil {
> > +			log.V(1).Infof("Unable to find Peer(%s) of Job(%s) in Registry", jobName, peer)
>
> I'm not your pal, bro
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/coreos/fleet/pull/603/files#r14426096>.
>