File tree Expand file tree Collapse file tree 2 files changed +13
-7
lines changed Expand file tree Collapse file tree 2 files changed +13
-7
lines changed Original file line number Diff line number Diff line change @@ -1048,15 +1048,15 @@ bool AgencyComm::ensureStructureInitialized() {
1048
1048
break ;
1049
1049
}
1050
1050
1051
+ // we can get here if a competing process tries to initialize
1052
+ // the agency structures as well
1051
1053
LOG_TOPIC (" 63f7b" , INFO, Logger::AGENCYCOMM)
1052
1054
<< " Initializing agency failed. We'll try again soon" ;
1053
- // We should really have exclusive access, here, this is strange!
1054
- std::this_thread::sleep_for (std::chrono::seconds (1 ));
1055
1055
1056
1056
LOG_TOPIC (" 9d265" , TRACE, Logger::AGENCYCOMM)
1057
1057
<< " Waiting for agency to get initialized" ;
1058
1058
1059
- std::this_thread::sleep_for (std::chrono::seconds ( 1 ));
1059
+ std::this_thread::sleep_for (std::chrono::milliseconds ( 250 ));
1060
1060
}
1061
1061
1062
1062
return true ;
Original file line number Diff line number Diff line change 82
82
83
83
SFRE=1.0
84
84
COMP=500
85
- KEEP=2000
85
+ KEEP=50000
86
86
if [ -z " $ONGOING_PORTS " ] ; then
87
87
CO_BASE=$(( $PORT_OFFSET + 8530 ))
88
88
DB_BASE=$(( $PORT_OFFSET + 8629 ))
@@ -297,19 +297,25 @@ done
297
297
298
298
testServer () {
299
299
PORT=$1
300
+ COUNTER=0
300
301
while true ; do
301
302
if [ -z " $AUTHORIZATION_HEADER " ]; then
302
303
${CURL} //$ADDRESS :$PORT /_api/version > /dev/null 2>&1
303
304
else
304
305
${CURL} //$ADDRESS :$PORT /_api/version -H " $AUTHORIZATION_HEADER " > /dev/null 2>&1
305
306
fi
306
- if [ " $? " != " 0" ] ; then
307
- echo Server on port $PORT does not answer yet.
307
+ if [ " x$? " != " x0" ] ; then
308
+ COUNTER=$(( $COUNTER + 1 ))
309
+ if [ " x$COUNTER " = " x4" ]; then
310
+ # only print every now and then
311
+ echo Server on port $PORT does not answer yet.
312
+ COUNTER=0
313
+ fi ;
308
314
else
309
315
echo Server on port $PORT is ready for business.
310
316
break
311
317
fi
312
- sleep 1
318
+ sleep 0.25
313
319
done
314
320
}
315
321
You can’t perform that action at this time.
0 commit comments