Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
dCache
cta
Commits
c4144c1f
Commit
c4144c1f
authored
Jul 24, 2019
by
Cedric CAFFY
Browse files
Added a timer of 3 minutes to flush the successful Retrieve Request for reporting
parent
1b4c285d
Changes
2
Hide whitespace changes
Inline
Side-by-side
tapeserver/castor/tape/tapeserver/daemon/RecallReportPacker.cpp
View file @
c4144c1f
...
...
@@ -236,6 +236,7 @@ void RecallReportPacker::WorkerThread::run(){
bool
endFound
=
false
;
std
::
list
<
std
::
unique_ptr
<
Report
>>
reportedSuccessfully
;
cta
::
utils
::
Timer
t
;
while
(
1
)
{
std
::
string
debugType
;
std
::
unique_ptr
<
Report
>
rep
(
m_parent
.
m_fifo
.
pop
());
...
...
@@ -265,8 +266,11 @@ void RecallReportPacker::WorkerThread::run(){
// m_parent.fullCheckAndFinishAsyncExecute will execute the shared half of the
// request updates (individual, asynchronous is done in rep->execute(m_parent);
if
(
typeid
(
*
rep
)
==
typeid
(
RecallReportPacker
::
ReportSuccessful
)
&&
m_parent
.
m_successfulRetrieveJobs
.
size
()
>=
m_parent
.
RECALL_REPORT_PACKER_FLUSH_SIZE
)
&&
(
m_parent
.
m_successfulRetrieveJobs
.
size
()
>=
m_parent
.
RECALL_REPORT_PACKER_FLUSH_SIZE
||
t
.
secs
()
>=
m_parent
.
RECALL_REPORT_PACKER_FLUSH_TIME
)){
m_parent
.
m_lc
.
log
(
cta
::
log
::
INFO
,
"m_parent.fullCheckAndFinishAsyncExecute()"
);
m_parent
.
fullCheckAndFinishAsyncExecute
();
t
.
reset
();
}
}
catch
(
const
cta
::
exception
::
Exception
&
e
){
//we get there because to tried to close the connection and it failed
//either from the catch a few lines above or directly from rep->execute
...
...
tapeserver/castor/tape/tapeserver/daemon/RecallReportPacker.hpp
View file @
c4144c1f
...
...
@@ -239,6 +239,11 @@ private:
* The limit for successful reports to trigger flush.
*/
const
unsigned
int
RECALL_REPORT_PACKER_FLUSH_SIZE
=
500
;
/*
* The time limit for successful reports to trigger flush.
*/
const
double
RECALL_REPORT_PACKER_FLUSH_TIME
=
180
;
};
}}}}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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