Hardcoded timeout for resync and delete operations in PBM cli code

Description

  1. Command “pbm config --force-resync --wait” ends with timeout

    • Problem description:

      • In our environment the resync operation takes about 1.5 minute. This command ends with following error after 30 seconds:

        • Error: waiting for resync [opid "662f43475d9bcd2d16b97b24"]: timeout

      • On behind in logs I see that commands is still running without issues and it is finished properly after 1.5 minute without any errors.

      • I have checked code for this function and found out that this 30 seconds timeout is hardcoded for context:

    • Solution proposal:

      • This value should be configurable in same way as it is done for backup.timeouts.startingStatus in pbm agent config yaml file.

        • resync.timeout: 900 (in seconds)

  2. Command “pbm cleanup --wait --older-than 30d --yes” ends with timeout

    • Problem description:

      • In our environment the delete operation takes about 2 minutes. This command ends with following error after 1 minute:

        • Error: read agents log: connection(<fqdn>:27017[-12]) incomplete read of message header: context deadline exceeded"

      • On behind in logs I see that commands is still running without issues and it is finished properly after 2 minute without any errors.

      • I have checked code for this function and found out that this 1 minute timeout is hardcoded for context:

    • Solution proposal:

      • This value should be configurable in same way as it is done for backup.timeouts.startingStatus in pbm agent config yaml file.

        • delete.timeout: 900 (in seconds)

Environment

None

Activity

Show:

Aaditya Dubey June 7, 2024 at 12:32 PM

Hi

Thank you for the report and feedback. We are considering it as an improvement request.

Done

Details

Assignee

Reporter

Labels

Needs QA

Yes

Sprint

Fix versions

Affects versions

Priority

Smart Checklist

Created April 29, 2024 at 7:09 AM
Updated September 2, 2024 at 8:57 AM
Resolved August 14, 2024 at 11:56 AM