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

Removed the inverse relations in the job entities #408

Merged
merged 1 commit into from Oct 11, 2016
Merged

Removed the inverse relations in the job entities #408

merged 1 commit into from Oct 11, 2016

Conversation

ajoymajumdar
Copy link
Contributor

  1. Removed the inverse relations in the job entities - JobEntity, JobRequestEntity, JobExecutionEntity and JobMetadataEntity,. This was done to reduce the SQL calls to get the associated entities.
  2. Modified certain queries to use named queries.

…RequestEntity, JobExecutionEntity and JobMetadataEntity,. This was done to reduce the SQL calls to get the associated entities.

2. Modified certain queries to use named queries.
@coveralls
Copy link

Coverage Status

Coverage decreased (-0.05%) to 88.722% when pulling 8f57c50 on ajoymajumdar:develop into efe6ec3 on Netflix:develop.

Copy link
Contributor

@tgianos tgianos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything looks good to me other than the one thing to keep in mind going forward.

*/
Long deleteByCreatedBefore(@NotNull final Date date);
List<JobRequestEntity> findByCreatedBefore(@NotNull final Date date);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As discussed my only concern here is memory if this list becomes too large. Currently this method is called daily as part of a task so we should be ok but it's something we might want to improve going forward either by returning just the Id's or paginating this list.

@tgianos tgianos merged commit 580fb9b into Netflix:develop Oct 11, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants