Skip to content

Commit

Permalink
Remove forbidden use of @batchsize
Browse files Browse the repository at this point in the history
  • Loading branch information
bukajsytlos committed Jun 14, 2024
1 parent 7ee8236 commit 3b83d8a
Show file tree
Hide file tree
Showing 10 changed files with 0 additions and 20 deletions.
1 change: 0 additions & 1 deletion src/main/java/com/faforever/api/data/domain/Game.java
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,6 @@ public Set<GameReview> getReviews() {
@OneToOne(fetch = FetchType.LAZY)
@PrimaryKeyJoinColumn
@UpdatePermission(expression = Prefab.ALL)
@BatchSize(size = 1000)
public GameReviewsSummary getReviewsSummary() {
return reviewsSummary;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import com.yahoo.elide.annotation.Include;
import lombok.Setter;
import org.hibernate.annotations.BatchSize;
import org.hibernate.annotations.Immutable;

import jakarta.annotation.Nullable;
Expand Down Expand Up @@ -65,7 +64,6 @@ public Float getAverageScore() {
}

@OneToOne(mappedBy = "reviewsSummary")
@BatchSize(size = 1000)
public Game getGame() {
return game;
}
Expand Down
3 changes: 0 additions & 3 deletions src/main/java/com/faforever/api/data/domain/Map.java
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ public List<MapVersion> getVersions() {
@ManyToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "author")
@Nullable
@BatchSize(size = 1000)
public Player getAuthor() {
return author;
}
Expand All @@ -114,7 +113,6 @@ public MapStatistics getStatistics() {
referencedColumnName = "id")
)
})
@BatchSize(size = 1000)
public MapVersion getLatestVersion() {
return latestVersion;
}
Expand All @@ -134,7 +132,6 @@ public MapReviewsSummary getReviewsSummary() {
@ManyToOne
@JoinColumn(name = "license")
@Nullable
@BatchSize(size = 1000)
public License getLicense() {
return license;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import com.yahoo.elide.annotation.Include;
import lombok.Setter;
import org.hibernate.annotations.BatchSize;
import org.hibernate.annotations.Immutable;

import jakarta.annotation.Nullable;
Expand Down Expand Up @@ -70,7 +69,6 @@ public Float getAverageScore() {

@OneToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "map_id", insertable = false, updatable = false)
@BatchSize(size = 1000)
public Map getMap() {
return map;
}
Expand Down
2 changes: 0 additions & 2 deletions src/main/java/com/faforever/api/data/domain/MapVersion.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
import com.yahoo.elide.annotation.Include;
import com.yahoo.elide.annotation.UpdatePermission;
import lombok.Setter;
import org.hibernate.annotations.BatchSize;

import jakarta.persistence.Column;
import jakarta.persistence.Entity;
Expand Down Expand Up @@ -112,7 +111,6 @@ public boolean isHidden() {
@ManyToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "map_id")
@NotNull
@BatchSize(size = 1000)
public Map getMap() {
return this.map;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import com.yahoo.elide.annotation.Include;
import lombok.Setter;
import org.hibernate.annotations.BatchSize;
import org.hibernate.annotations.Immutable;

import jakarta.annotation.Nullable;
Expand Down Expand Up @@ -70,7 +69,6 @@ public Float getAverageScore() {

@OneToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "map_version_id", insertable = false, updatable = false)
@BatchSize(size = 1000)
public MapVersion getMapVersion() {
return mapVersion;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import com.yahoo.elide.annotation.Include;
import lombok.Setter;
import org.hibernate.annotations.BatchSize;
import org.hibernate.annotations.Immutable;

import jakarta.persistence.Column;
Expand Down Expand Up @@ -48,7 +47,6 @@ public Integer getDraws() {

@OneToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "map_version_id", insertable = false, updatable = false)
@BatchSize(size = 1000)
public MapVersion getMapVersion() {
return mapVersion;
}
Expand Down
2 changes: 0 additions & 2 deletions src/main/java/com/faforever/api/data/domain/Mod.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
import com.yahoo.elide.annotation.Include;
import com.yahoo.elide.annotation.UpdatePermission;
import lombok.Setter;
import org.hibernate.annotations.BatchSize;
import org.hibernate.annotations.JoinColumnOrFormula;
import org.hibernate.annotations.JoinColumnsOrFormulas;
import org.hibernate.annotations.JoinFormula;
Expand Down Expand Up @@ -114,7 +113,6 @@ public ModReviewsSummary getReviewsSummary() {
@ManyToOne
@JoinColumn(name = "license")
@Nullable
@BatchSize(size = 1000)
public License getLicense() {
return license;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import com.yahoo.elide.annotation.Include;
import lombok.Setter;
import org.hibernate.annotations.BatchSize;
import org.hibernate.annotations.Immutable;

import jakarta.annotation.Nullable;
Expand Down Expand Up @@ -70,7 +69,6 @@ public Float getAverageScore() {

@OneToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "mod_id", insertable = false, updatable = false)
@BatchSize(size = 1000)
public Mod getMod() {
return mod;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import com.yahoo.elide.annotation.Include;
import lombok.Setter;
import org.hibernate.annotations.BatchSize;
import org.hibernate.annotations.Immutable;

import jakarta.annotation.Nullable;
Expand Down Expand Up @@ -70,7 +69,6 @@ public Float getAverageScore() {

@OneToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "mod_version_id", insertable = false, updatable = false)
@BatchSize(size = 1000)
public ModVersion getModVersion() {
return modVersion;
}
Expand Down

0 comments on commit 3b83d8a

Please sign in to comment.