<!-- 
RSS generated by JIRA (9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c) at Sat Feb 10 03:16:07 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>Whamcloud Community JIRA</title>
    <link>https://jira.whamcloud.com</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.4.14</version>
        <build-number>940014</build-number>
        <build-date>05-12-2023</build-date>
    </build-info>


<item>
            <title>[LU-15178] clean up/clarify use of CEF_SPECULATIVE/LDLM_FL_SPECULATIVE</title>
                <link>https://jira.whamcloud.com/browse/LU-15178</link>
                <project id="10000" key="LU">Lustre</project>
                    <description>&lt;p&gt;There were some poor choices made (by me) when the lockahead code was originally finalized.&#160; The concept of a &quot;speculative&quot; lock, a lock requested before it&apos;s used (and which may never be used), is a mix of two things: asynchronous on the client, and nonblocking (in terms of not cancelling or waiting for other locks) on the server.&lt;/p&gt;

&lt;p&gt;But the async behavior is a client only concept, so LDLM_FL_SPECULATIVE only actually enforces non-blocking behavior, and has nothing to do with async.&#160; (The existing LDLM_FL_BLOCK_NOWAIT is also used for O_NONBLOCK in a way which means it could not be reused for this.)&lt;/p&gt;

&lt;p&gt;Async lock requests must be non-blocking, but non-blocking requests are not fundamentally speculative.&lt;/p&gt;

&lt;p&gt;Separating the concept of async requests from the concept of a non-blocking request lets us make non-blocking requests for readahead, where the request is best described as &apos;optional&apos; - The lock will always be used if it is granted, but it&apos;s OK if it&apos;s not granted.&lt;/p&gt;

&lt;p&gt;This means creating separate CEF_ASYNC and CEF_NOWAIT flags on the client.&#160; CEF_ASYNC does require CEF_NOWAIT, but CEF_NOWAIT does &lt;b&gt;not&lt;/b&gt; require CEF_ASYNC.&#160; (We&apos;ll enforce this with an assert.)&lt;/p&gt;

&lt;p&gt;It&apos;s also a good idea to rename the existing LDLM_FL_SPECULATIVE lock flag to LDLM_FL_NOWAIT - the behavior and the bit # will remain unchanged, so we can rename it without causing interop issues with older clients.&#160; This will be carefully commented in the code.&lt;/p&gt;

&lt;p&gt;To summarize, there are three variables which describe a lock request.&lt;br/&gt;
Sync vs Async: Is the requesting thread going to wait for the response from the server?&lt;/p&gt;

&lt;p&gt;Blocking vs non-blocking (wait vs nowait): Will the lock request cancel existing locks, or will it fail if it finds a conflicting lock?&#160; Note that async requires non-blocking.&lt;/p&gt;

&lt;p&gt;Expansion vs No-expansion: No-expand is a property of lockahead locks, where they have manually specified extent ranges and the server does not expand them.&#160; Normal locks are expanded.&lt;/p&gt;

&lt;p&gt;Today, we allow the following:&lt;/p&gt;
&lt;div class=&apos;table-wrap&apos;&gt;
&lt;table class=&apos;confluenceTable&apos;&gt;&lt;tbody&gt;
&lt;tr&gt;
&lt;th class=&apos;confluenceTh&apos;&gt;Sync/Async&lt;/th&gt;
&lt;th class=&apos;confluenceTh&apos;&gt;Blocking/Non-Blocking&lt;/th&gt;
&lt;th class=&apos;confluenceTh&apos;&gt;Expansion/No Expansion&lt;/th&gt;
&lt;th class=&apos;confluenceTh&apos;&gt;Notes&lt;/th&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Sync&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Blocking&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Expansion&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;OK&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Sync&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Blocking&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;No Expansion&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;OK&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#ff8b00&quot;&gt;Sync&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#ff8b00&quot;&gt;Non-Blocking&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#ff8b00&quot;&gt;Expansion&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Not allowed &lt;b&gt;today&lt;/b&gt; because Async + Non-blocking behavior combined.&lt;br/&gt;
New patch allows this by separating behavior.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#ff8b00&quot;&gt;Sync&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#ff8b00&quot;&gt;Non-Blocking&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#ff8b00&quot;&gt;No Expansion&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&#160;Not allowed &lt;b&gt;today&lt;/b&gt; because Async + Non-blocking behavior combined.&lt;br/&gt;
New patch allows this by separating behavior.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#FF0000&quot;&gt;&lt;del&gt;Async&lt;/del&gt;&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#FF0000&quot;&gt;&lt;del&gt;Blocking&lt;/del&gt;&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#FF0000&quot;&gt;&lt;del&gt;Expansion&lt;/del&gt;&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#172b4d&quot;&gt;No async + blocking&lt;/font&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#FF0000&quot;&gt;&lt;del&gt;Async&lt;/del&gt;&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#FF0000&quot;&gt;&lt;del&gt;Blocking&lt;/del&gt;&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#FF0000&quot;&gt;&lt;del&gt;No Expansion&lt;/del&gt;&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#172b4d&quot;&gt;No async + blocking&lt;/font&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#ff8b00&quot;&gt;Async&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#ff8b00&quot;&gt;Non-Blocking&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;font color=&quot;#ff8b00&quot;&gt;Expansion&lt;/font&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Not allowed, due to size issues explained in ofd_intent_cb.&lt;br/&gt;
Can allow for &lt;b&gt;read&lt;/b&gt; locks, will do so in new patch.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Async&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Non-Blocking&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;No Expansion&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;OK (Standard lockahead)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
&lt;/div&gt;



&lt;p&gt;A little complicated.&lt;/p&gt;

&lt;p&gt;Patch forthcoming later.&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;</description>
                <environment></environment>
        <key id="66908">LU-15178</key>
            <summary>clean up/clarify use of CEF_SPECULATIVE/LDLM_FL_SPECULATIVE</summary>
                <type id="4" iconUrl="https://jira.whamcloud.com/secure/viewavatar?size=xsmall&amp;avatarId=11310&amp;avatarType=issuetype">Improvement</type>
                                            <priority id="4" iconUrl="https://jira.whamcloud.com/images/icons/priorities/minor.svg">Minor</priority>
                        <status id="1" iconUrl="https://jira.whamcloud.com/images/icons/statuses/open.png" description="The issue is open and ready for the assignee to start work on it.">Open</status>
                    <statusCategory id="2" key="new" colorName="default"/>
                                    <resolution id="-1">Unresolved</resolution>
                                        <assignee username="paf0186">Patrick Farrell</assignee>
                                    <reporter username="paf0186">Patrick Farrell</reporter>
                        <labels>
                    </labels>
                <created>Fri, 29 Oct 2021 15:22:10 +0000</created>
                <updated>Wed, 3 Nov 2021 18:27:31 +0000</updated>
                                                                                <due></due>
                            <votes>0</votes>
                                    <watches>2</watches>
                                                                            <comments>
                            <comment id="317386" author="gerrit" created="Wed, 3 Nov 2021 18:27:31 +0000"  >&lt;p&gt;&quot;Patrick Farrell &amp;lt;pfarrell@whamcloud.com&amp;gt;&quot; uploaded a new patch: &lt;a href=&quot;https://review.whamcloud.com/45449&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://review.whamcloud.com/45449&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-15178&quot; title=&quot;clean up/clarify use of CEF_SPECULATIVE/LDLM_FL_SPECULATIVE&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-15178&quot;&gt;LU-15178&lt;/a&gt; llite: Clarify async vs nowait&lt;br/&gt;
Project: fs/lustre-release&lt;br/&gt;
Branch: master&lt;br/&gt;
Current Patch Set: 1&lt;br/&gt;
Commit: 3d3af4e9a79b85b026ede8409903c0a546844882&lt;/p&gt;</comment>
                    </comments>
                    <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                            <customfield id="customfield_10890" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_10390" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i028tz:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10090" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>9223372036854775807</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                </customfields>
    </item>
</channel>
</rss>