Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
dCache
nfs4j
Commits
7f34973f
Commit
7f34973f
authored
Feb 09, 2011
by
Tigran Mkrtchyan
☕
Browse files
nfsv41: pass cacheThis to the the corresponding slot
parent
d863ba71
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/org/dcache/chimera/nfs/v4/NFSv41Session.java
View file @
7f34973f
...
...
@@ -68,8 +68,9 @@ public class NFSv41Session {
return
_slots
.
length
-
1
;
}
public
boolean
updateSlot
(
int
slot
,
int
sequence
,
List
<
nfs_resop4
>
reply
)
throws
ChimeraNFSException
{
return
getSlot
(
slot
).
update
(
sequence
,
reply
);
public
boolean
updateSlot
(
int
slot
,
int
sequence
,
boolean
cacheThis
,
List
<
nfs_resop4
>
reply
)
throws
ChimeraNFSException
{
return
getSlot
(
slot
).
update
(
sequence
,
reply
,
cacheThis
);
}
/**
...
...
src/org/dcache/chimera/nfs/v4/OperationSEQUENCE.java
View file @
7f34973f
...
...
@@ -56,8 +56,6 @@ public class OperationSEQUENCE extends AbstractNFSv4Operation {
* in a COMPOUND. Such operations will get the error NFS4ERR_OP_NOT_IN_SESSION if they do
* appear at the start of a COMPOUND.
*
*
*
*/
...
...
@@ -87,19 +85,17 @@ public class OperationSEQUENCE extends AbstractNFSv4Operation {
}
List
<
nfs_resop4
>
reply
;
if
(
_args
.
opsequence
.
sa_cachethis
)
{
reply
=
context
.
processedOperations
();
}
else
{
reply
=
null
;
}
if
(
session
.
updateSlot
(
_args
.
opsequence
.
sa_slotid
.
value
.
value
,
_args
.
opsequence
.
sa_sequenceid
.
value
.
value
,
reply
))
{
List
<
nfs_resop4
>
reply
=
context
.
processedOperations
();
if
(
session
.
updateSlot
(
_args
.
opsequence
.
sa_slotid
.
value
.
value
,
_args
.
opsequence
.
sa_sequenceid
.
value
.
value
,
_args
.
opsequence
.
sa_cachethis
,
reply
)){
/*
* retransmit + cached reply available.
* Stop processing.
*/
* retransmit + cached reply available.
* Stop processing.
*/
return
false
;
}
session
.
getClient
().
updateLeaseTime
(
NFSv4Defaults
.
NFS4_LEASE_TIME
);
context
.
setSession
(
session
);
...
...
src/org/dcache/chimera/nfs/v4/SessionSlot.java
View file @
7f34973f
...
...
@@ -49,7 +49,7 @@ public class SessionSlot {
* @return true if retransmit is detected and cached reply available.
* @throws ChimeraNFSException
*/
boolean
update
(
int
sequence
,
List
<
nfs_resop4
>
reply
)
throws
ChimeraNFSException
{
boolean
update
(
int
sequence
,
List
<
nfs_resop4
>
reply
,
boolean
cacheThis
)
throws
ChimeraNFSException
{
if
(
sequence
==
_sequence
)
{
_log
.
info
(
"retransmit detected"
);
...
...
@@ -85,7 +85,11 @@ public class SessionSlot {
}
_sequence
=
sequence
;
_reply
=
reply
;
if
(
cacheThis
){
_reply
=
reply
;
}
else
{
_reply
=
null
;
}
return
false
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment