From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Campbell Subject: Re: [PATCH OSSTEST v2 12/18] Toolstack: Refactor migration support. Date: Thu, 22 Jan 2015 15:19:24 +0000 Message-ID: <1421939964.23842.36.camel@citrix.com> References: <1417536141.29004.6.camel@citrix.com> <1417536299-1810-12-git-send-email-ian.campbell@citrix.com> <21694.41138.137642.85569@mariner.uk.xensource.com> <1421939195.23842.33.camel@citrix.com> <21697.5267.690726.556698@mariner.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <21697.5267.690726.556698@mariner.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Jackson Cc: Jim Fehlig , xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org On Thu, 2015-01-22 at 15:17 +0000, Ian Jackson wrote: > Ian Campbell writes ("Re: [PATCH OSSTEST v2 12/18] Toolstack: Refactor migration support."): > > On Tue, 2015-01-20 at 18:38 +0000, Ian Jackson wrote: > > > Again, I think you should pass the $dho rather than the name. In > > > general it's better to pass the hash object to these kind of methods. > > > > For ts-guest-localmigrate is there a cunning stunt you would recommend > > to generate a $dho with ->{Name} == "localhost"? > > > > Or perhaps: > > $dho ? $dho->{Name} : "localhost" > > ? (i.e. $dho==undef => localhost) > > That would do, although it's a big magic. > > Magic in a different way would be: > > ->migrate($ts, $gho, { %$dho, Name => 'localhost' }, $timeout) In the caller? There is no $dho in that case. But I think maybe you meant $gho? (i.e. this is supposed to produce a copy of $gho with a different name) Ian.