Uploaded image for project: 'IGB'
  1. IGB
  2. IGBF-2121

Make cron string for pending app cleaning job configurable

    Details

    • Type: Task
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: None
    • Labels:
      None
    • Story Points:
      1
    • Sprint:
      Fall 7 : 11 Nov to 22 Nov, Fall 8 : 25 Nov to 6 Dec, Fall 9 : 9 Dec to 20 Dec

      Description

      • To change the time span for deleting a stale app, edit: app_pending_cleanup.py. To make this configuration via settings.py and settings.ini.template
      • To add logging statements to cron job

        Attachments

          Issue Links

            Activity

            Hide
            rpatil14 Riddhi Jagdish Patil (Inactive) added a comment -

            Coding is completed.
            Unit testing in progress. This will take one whole day as the cron will run at night.

            Show
            rpatil14 Riddhi Jagdish Patil (Inactive) added a comment - Coding is completed. Unit testing in progress. This will take one whole day as the cron will run at night.
            Hide
            rpatil14 Riddhi Jagdish Patil (Inactive) added a comment - - edited
            Show
            rpatil14 Riddhi Jagdish Patil (Inactive) added a comment - - edited Code changes present in below branch: https://bitbucket.org/rpatil14/appstore_riddhi/branch/IGBF-2121#diff
            Hide
            ann.loraine Ann Loraine added a comment - - edited

            Change request:

            • Please use the "config" function with "default" option to set APP_PENDING_CLEANUP_CRONSTRING and APP_PENDING_CLEANUP_TIME_OFFSET. Use the currently hard-coded settings as the default value. For examples, see other places in the same file.
            • Add above config strings as empty values to settings.ini.template, at the end of the file.
            Show
            ann.loraine Ann Loraine added a comment - - edited Change request: Please use the "config" function with "default" option to set APP_PENDING_CLEANUP_CRONSTRING and APP_PENDING_CLEANUP_TIME_OFFSET. Use the currently hard-coded settings as the default value. For examples, see other places in the same file. Add above config strings as empty values to settings.ini.template, at the end of the file.
            Hide
            rpatil14 Riddhi Jagdish Patil (Inactive) added a comment -

            Changes can be find in https://bitbucket.org/rpatil14/appstore_riddhi/branch/IGBF-2121#diff branch

            cc. [~aloraine]

            Show
            rpatil14 Riddhi Jagdish Patil (Inactive) added a comment - Changes can be find in https://bitbucket.org/rpatil14/appstore_riddhi/branch/IGBF-2121#diff branch cc. [~aloraine]
            Hide
            ann.loraine Ann Loraine added a comment -

            Looks great - please submit PR

            Show
            ann.loraine Ann Loraine added a comment - Looks great - please submit PR
            Show
            rpatil14 Riddhi Jagdish Patil (Inactive) added a comment - Pull request submitted: https://bitbucket.org/lorainelab/appstore/pull-requests/167/igbf-2121/diff
            Hide
            ann.loraine Ann Loraine added a comment - - edited

            Merged.
            I need to update settings.ini used for setting up test environment and also deploy on dev-appstore-2.
            Will be ready for testing shortly.

            Show
            ann.loraine Ann Loraine added a comment - - edited Merged. I need to update settings.ini used for setting up test environment and also deploy on dev-appstore-2. Will be ready for testing shortly.
            Hide
            rpatil14 Riddhi Jagdish Patil (Inactive) added a comment - - edited

            Code changes to add config comments to file:
            https://bitbucket.org/rpatil14/appstore_riddhi/branch/IGBF-2121-Bug

            Settings.ini does not allow addition of comments so added comments to settings.py

            cc.[~aloraine]

            Show
            rpatil14 Riddhi Jagdish Patil (Inactive) added a comment - - edited Code changes to add config comments to file: https://bitbucket.org/rpatil14/appstore_riddhi/branch/IGBF-2121-Bug Settings.ini does not allow addition of comments so added comments to settings.py cc. [~aloraine]
            Show
            rpatil14 Riddhi Jagdish Patil (Inactive) added a comment - Pull request submitted: https://bitbucket.org/lorainelab/appstore/pull-requests/173/igbf-2121-bug/diff cc. [~aloraine]
            Hide
            ann.loraine Ann Loraine added a comment -

            Merged & deployed to https://dev-appstore-2.bioviz.org and ready for testing.

            Show
            ann.loraine Ann Loraine added a comment - Merged & deployed to https://dev-appstore-2.bioviz.org and ready for testing.
            Hide
            shamika Shamika Gajanan Kulkarni (Inactive) added a comment -

            This ticket has been tested and I had observed that app entries within the time span for deleting stale entries do not get deleted and the ones which fall out of the time span got deleted. I just want to make sure that it was done by the scheduler itself and not someone else who was working on testing the Appstore tickets. Just to be sure I am testing this once again today. Hope it's okay.

            Show
            shamika Shamika Gajanan Kulkarni (Inactive) added a comment - This ticket has been tested and I had observed that app entries within the time span for deleting stale entries do not get deleted and the ones which fall out of the time span got deleted. I just want to make sure that it was done by the scheduler itself and not someone else who was working on testing the Appstore tickets. Just to be sure I am testing this once again today. Hope it's okay.
            Hide
            shamika Shamika Gajanan Kulkarni (Inactive) added a comment -

            The ticket has been tested and the observations are as follows:
            1) Stale entries [apps uploaded before 1 hour from cron job running time] and with submitter_approved values as False were deleted from AppPending table and jar was deleted from S3 bucket. [Get Average Score]
            2) The apps with submitter_approved value as false and uploaded within 1 hour time span were not deleted from AppPending table during this run time. The jar still remains in S3 bucket. This will be deleted when the next cron job runs after 2 hours. [Super Simple IGB App]

            Kindly refer the screenshots attached. Moving to closed. Thank you.

            Show
            shamika Shamika Gajanan Kulkarni (Inactive) added a comment - The ticket has been tested and the observations are as follows: 1) Stale entries [apps uploaded before 1 hour from cron job running time] and with submitter_approved values as False were deleted from AppPending table and jar was deleted from S3 bucket. [Get Average Score] 2) The apps with submitter_approved value as false and uploaded within 1 hour time span were not deleted from AppPending table during this run time. The jar still remains in S3 bucket. This will be deleted when the next cron job runs after 2 hours. [Super Simple IGB App] Kindly refer the screenshots attached. Moving to closed. Thank you.

              People

              • Assignee:
                rpatil14 Riddhi Jagdish Patil (Inactive)
                Reporter:
                rpatil14 Riddhi Jagdish Patil (Inactive)
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: