Re: [pynfs PATCH 1/4] nfs4.1: add some reboot tests

J. Bruce Fields
2019-03-15T20:50:21Z

On Fri, Mar 15, 2019 at 03:52:33PM -0400, Scott Mayhew wrote:
> On Fri, 15 Mar 2019, J. Bruce Fields wrote:
>
> > On Thu, Mar 14, 2019 at 05:12:07PM -0400, Scott Mayhew wrote:
> > > +def doTestRebootWithNClients(t, env, n=10):
> > > + boot_time = int(time.time())
> > > + lease_time = 90
> >
> > Looks like these two variables aren't used till they're set again a
> > little further down, so I'll delete these two lines.
>
> The intention there was to have some default values for the exception
> handler if the test were to barf right away for some reason.

Oh, I see, OK.

--b.

> >
> > --b.
> >
> > > + states = []
> > > + block = env.c1.new_client_session("%s_block" % env.testname(t))
> > > + for i in range(n):
> > > + name = "%s_client_%i" % (env.testname(t), i)
> > > + owner = "owner_%s" % name
> > > + c = env.c1.new_client(name)
> > > + sess = c.create_session()
> > > + reclaim_complete(sess)
> > > + fh, stateid = create_confirm(sess, owner)
> > > + states.append(State(name, owner, c, sess, fh))
> > > + lease_time = _getleasetime(sess)
> > > + boot_time = _waitForReboot(env)