Skip to content

Commit

Permalink
Fix sampling
Browse files Browse the repository at this point in the history
  • Loading branch information
adam-collins authored Aug 9, 2016
1 parent d391d96 commit 3969b62
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/main/scala/au/org/ala/biocache/util/LayersStore.scala
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,12 @@ class LayersStore ( layersStoreUrl: String) {
respBody = r._2
retry = r._3

if (respCode != HttpStatus.SC_OK)
if (respCode != HttpStatus.SC_OK) {
logger.warn("Problem getting sampling status: " + r + " retries=" + retries)

//count down retries if status is not OK
retries -= 1
}
if (callback != null) {
if (respCode != HttpStatus.SC_OK) {
callback.progressMessage("Problem getting status: " + respCode + "/" + HttpStatus.getStatusText(respCode))
Expand Down Expand Up @@ -87,7 +91,6 @@ class LayersStore ( layersStoreUrl: String) {
}
}
}
retries -= 1
}

if (retries <= 0 || respBody == null) {
Expand Down

0 comments on commit 3969b62

Please sign in to comment.