diff mbox series

[testsuite] tests/sctp: bump connect timeout to 4 seconds

Message ID 20200827081100.1954467-1-omosnace@redhat.com (mailing list archive)
State Accepted
Delegated to: Ondrej Mosnáček
Headers show
Series [testsuite] tests/sctp: bump connect timeout to 4 seconds | expand

Commit Message

Ondrej Mosnacek Aug. 27, 2020, 8:11 a.m. UTC
The current value of 2 seconds causes transient failures too often in
certain slow/unstable environments (including the nested KVM Travis CI
setup). Our experience from downstream testing at Red Hat (across a
variety of HW and architectures) has shown that a value of 4 seconds
yields only very sporadic failures.

Therefore, change the value to 4 to trade off some testing time for more
stability.

Signed-off-by: Ondrej Mosnacek <omosnace@redhat.com>
---
 tests/sctp/sctp_client.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Stephen Smalley Aug. 31, 2020, 2:13 p.m. UTC | #1
On Thu, Aug 27, 2020 at 4:11 AM Ondrej Mosnacek <omosnace@redhat.com> wrote:
>
> The current value of 2 seconds causes transient failures too often in
> certain slow/unstable environments (including the nested KVM Travis CI
> setup). Our experience from downstream testing at Red Hat (across a
> variety of HW and architectures) has shown that a value of 4 seconds
> yields only very sporadic failures.
>
> Therefore, change the value to 4 to trade off some testing time for more
> stability.
>
> Signed-off-by: Ondrej Mosnacek <omosnace@redhat.com>

As much as I dislike relying on timeouts and making the testsuite even
slower, I don't have any better solution.

Acked-by:  Stephen Smalley <stephen.smalley.work@gmail.com>
(feel free to merge it yourself)
Ondrej Mosnacek Sept. 3, 2020, 3:13 p.m. UTC | #2
On Mon, Aug 31, 2020 at 4:13 PM Stephen Smalley
<stephen.smalley.work@gmail.com> wrote:
>
> On Thu, Aug 27, 2020 at 4:11 AM Ondrej Mosnacek <omosnace@redhat.com> wrote:
> >
> > The current value of 2 seconds causes transient failures too often in
> > certain slow/unstable environments (including the nested KVM Travis CI
> > setup). Our experience from downstream testing at Red Hat (across a
> > variety of HW and architectures) has shown that a value of 4 seconds
> > yields only very sporadic failures.
> >
> > Therefore, change the value to 4 to trade off some testing time for more
> > stability.
> >
> > Signed-off-by: Ondrej Mosnacek <omosnace@redhat.com>
>
> As much as I dislike relying on timeouts and making the testsuite even
> slower, I don't have any better solution.
>
> Acked-by:  Stephen Smalley <stephen.smalley.work@gmail.com>
> (feel free to merge it yourself)

Thanks, merged.
diff mbox series

Patch

diff --git a/tests/sctp/sctp_client.c b/tests/sctp/sctp_client.c
index 595da75..2f527ed 100644
--- a/tests/sctp/sctp_client.c
+++ b/tests/sctp/sctp_client.c
@@ -99,7 +99,7 @@  int main(int argc, char **argv)
 	 *    EAGAIN - Resource temporarily unavailable - SOCK_SEQPACKET
 	 *        Uses SO_RCVTIMEO when NO connects are called.
 	 */
-	tm.tv_sec = 2;
+	tm.tv_sec = 4;
 	tm.tv_usec = 0;
 	result = setsockopt(sock, SOL_SOCKET, SO_SNDTIMEO, &tm, sizeof(tm));
 	if (result < 0) {