[OpenAFS-devel] Re: [OpenAFS] Documentation for fs precache

Phillip Moore w.phillip.moore@gmail.com
Tue, 19 Oct 2010 09:35:31 -0400


--0015175cbaa8e1bdde0492f85da1
Content-Type: text/plain; charset=ISO-8859-1

Actually, instead of a hidden command, how about making precache an alias to
setprecache?  That seems simpler to implement.

However, it's unclear to me how to make a change in 1.6.  Do I need to patch
a specific branch?

On Tue, Oct 19, 2010 at 8:52 AM, Derrick Brashear <shadow@gmail.com> wrote:

> On Tue, Oct 19, 2010 at 7:27 AM, Phillip Moore
> <w.phillip.moore@gmail.com> wrote:
> >
> > Would you accept a patch that introduces two new fs commands:
> >
> >     fs getprecache
> >     fs setprecache
> > and that "hides" the precache command?  IOW, precache will work, but it
> will
> > not show up in fs help output.  This introduces a new pair of get/set
> > commands, and would give admins the ability to query the value, and
> > therefore manage it.
> > Alternately, fs precache can be modified to display the value when no
> > arguments are provided, instead of generate a syntax error like it does
> > right now.
>
> Either is fine. A hidden deprecated command might be better in 1.6
> (documented as existing but deprecated) and the master can simply not
> have the command at all so that when 1.next hits, ti's already gone.
>
> > There's a lack of consistency in the fs commands, but my personal
> preference
> > is for get/set commands when we add new features, as opposed to a single
> > command for both setting and querying something.
> > On Mon, Oct 18, 2010 at 1:50 PM, Derrick Brashear <shadow@gmail.com>
> wrote:
> >>
> >> On Mon, Oct 18, 2010 at 1:45 PM, Phillip Moore
> >> <w.phillip.moore@gmail.com> wrote:
> >> > Another fs command I can't find any documentation for:  fs precache
> >> > In this case, it appears that there's no way to query the value.
> This
> >> > seems like bad interface design to me.  If there's a mechanism for
> >> > setting
> >> > an important value that changes the behavior of the client, there has
> to
> >> > be
> >> > a mechanism for querying that value.  Otherwise, you can't manage it.
> >> >  Write-only, read-never parameters are very bad.
> >> > Looking at the code in src/venus/fs.c, it looks to me like this
> *should*
> >> > have been implemented as a pair of CLI commands: setprecache and
> >> > getprecache, and in fact, that should be straight forward, and fully
> >> > backwards compatible.
> >>
> >> Probably. And I take blame for that.
> >>
> >> > Is this another bleeding edge feature that the authors thought wasn't
> >> > important enough to write a man page for?
> >>
> >> No.
> >>
> >>
> >>
> >> --
> >> Derrick
> >
> >
>
>
>
> --
> Derrick
>

--0015175cbaa8e1bdde0492f85da1
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

<div><br></div>Actually, instead of a hidden command, how about making prec=
ache an alias to setprecache? =A0That seems simpler to implement.<div><br><=
/div><div>However, it&#39;s unclear to me how to make a change in 1.6. =A0D=
o I need to patch a specific branch?<br>
<br><div class=3D"gmail_quote">On Tue, Oct 19, 2010 at 8:52 AM, Derrick Bra=
shear <span dir=3D"ltr">&lt;<a href=3D"mailto:shadow@gmail.com">shadow@gmai=
l.com</a>&gt;</span> wrote:<br><blockquote class=3D"gmail_quote" style=3D"m=
argin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
On Tue, Oct 19, 2010 at 7:27 AM, Phillip Moore<br>
<div class=3D"im">&lt;<a href=3D"mailto:w.phillip.moore@gmail.com">w.philli=
p.moore@gmail.com</a>&gt; wrote:<br>
&gt;<br>
</div><div class=3D"im">&gt; Would you accept a patch that introduces two n=
ew fs commands:<br>
&gt;<br>
&gt; =A0=A0 =A0fs getprecache<br>
&gt; =A0=A0 =A0fs setprecache<br>
&gt; and that &quot;hides&quot; the precache command? =A0IOW, precache will=
 work, but it will<br>
&gt; not show up in fs help output. =A0This introduces a new pair of get/se=
t<br>
&gt; commands, and would give admins the ability to query the value, and<br=
>
&gt; therefore manage it.<br>
&gt; Alternately, fs precache can be modified to display the value when no<=
br>
&gt; arguments are provided, instead of generate a syntax error like it doe=
s<br>
&gt; right now.<br>
<br>
</div>Either is fine. A hidden deprecated command might be better in 1.6<br=
>
(documented as existing but deprecated) and the master can simply not<br>
have the command at all so that when 1.next hits, ti&#39;s already gone.<br=
>
<div class=3D"im"><br>
&gt; There&#39;s a lack of consistency in the fs commands, but my personal =
preference<br>
&gt; is for get/set commands when we add new features, as opposed to a sing=
le<br>
&gt; command for both setting and querying something.<br>
&gt; On Mon, Oct 18, 2010 at 1:50 PM, Derrick Brashear &lt;<a href=3D"mailt=
o:shadow@gmail.com">shadow@gmail.com</a>&gt; wrote:<br>
&gt;&gt;<br>
&gt;&gt; On Mon, Oct 18, 2010 at 1:45 PM, Phillip Moore<br>
&gt;&gt; &lt;<a href=3D"mailto:w.phillip.moore@gmail.com">w.phillip.moore@g=
mail.com</a>&gt; wrote:<br>
&gt;&gt; &gt; Another fs command I can&#39;t find any documentation for: =
=A0fs precache<br>
&gt;&gt; &gt; In this case, it appears that there&#39;s no way to query the=
 value. =A0 This<br>
&gt;&gt; &gt; seems like bad interface design to me. =A0If there&#39;s a me=
chanism for<br>
&gt;&gt; &gt; setting<br>
&gt;&gt; &gt; an important value that changes the behavior of the client, t=
here has to<br>
&gt;&gt; &gt; be<br>
&gt;&gt; &gt; a mechanism for querying that value. =A0Otherwise, you can&#3=
9;t manage it.<br>
&gt;&gt; &gt; =A0Write-only, read-never parameters are very bad.<br>
&gt;&gt; &gt; Looking at the code in src/venus/fs.c, it looks to me like th=
is *should*<br>
&gt;&gt; &gt; have been implemented as a pair of CLI commands: setprecache =
and<br>
&gt;&gt; &gt; getprecache, and in fact, that should be straight forward, an=
d fully<br>
&gt;&gt; &gt; backwards compatible.<br>
&gt;&gt;<br>
&gt;&gt; Probably. And I take blame for that.<br>
&gt;&gt;<br>
&gt;&gt; &gt; Is this another bleeding edge feature that the authors though=
t wasn&#39;t<br>
&gt;&gt; &gt; important enough to write a man page for?<br>
&gt;&gt;<br>
&gt;&gt; No.<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; --<br>
&gt;&gt; Derrick<br>
&gt;<br>
&gt;<br>
<br>
<br>
<br>
</div>--<br>
<font color=3D"#888888">Derrick<br>
</font></blockquote></div><br></div>

--0015175cbaa8e1bdde0492f85da1--