Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Split up UploadArea #262

Open
sampierson opened this issue Jan 8, 2019 · 0 comments
Open

Split up UploadArea #262

sampierson opened this issue Jan 8, 2019 · 0 comments

Comments

@sampierson
Copy link
Member

CodeClimate is complaining that

File upload_area.py has 253 lines of code (exceeds 250 allowed). Consider refactoring.

Looking at UploadArea, there are a couple things that could be broken out of it to simplify it:

  1. It knows a lot about SQS. Perhaps we should encapsulate all our SQS knowledge inside a class called, say. SQSQueue which has subclasses CsumSQSQueue and DeleteSQSQueue, and from UploadArea be simply calling DeletionSQSQueue().enqueue(upload_area).
  2. Methods retrieve_file_checksum_statuses_for_upload_area and retrieve_file_validation_statuses_for_upload_area don't act on the current object except to get a database handle from self.db. This diagnostic / health check logic could live in a separate module.
@parthshahva parthshahva added the H1 Proposed H1 task label Jan 23, 2019
@MDunitz MDunitz self-assigned this Mar 19, 2019
@maniarathi maniarathi self-assigned this Apr 15, 2019
@parthshahva parthshahva removed H1 Proposed H1 task hackathon labels May 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants