Skip to content
Snippets Groups Projects
Commit 24687f49 authored by Cam Saül's avatar Cam Saül
Browse files

Fix BigQuery error message

parent dc45b0db
No related branches found
No related tags found
No related merge requests found
......@@ -176,13 +176,13 @@
(defn- post-process-native
([^QueryResponse response]
(post-process-native response 15))
(post-process-native response 20))
([^QueryResponse response, ^Integer timeout-seconds]
(if-not (.getJobComplete response)
;; 99% of the time by the time this is called `.getJobComplete` will return `true`. On the off chance it doesn't, wait a few seconds for the job to finish.
(do
(when (zero? timeout-seconds)
(throw (ex-info query-timeout-error-message response)))
(throw (ex-info query-timeout-error-message (into {} response))))
(Thread/sleep 1000)
(post-process-native response (dec timeout-seconds)))
;; Otherwise the job *is* complete
......
......@@ -11,8 +11,7 @@
(defn- index [_]
(-> (if (@(resolve 'metabase.core/initialized?))
(stencil/render-string (slurp (or (io/resource "frontend_client/index.html")
;; Occasionally people try to launch from 'lein ring server' and move stuff around. In that case give them a useful error message.
(throw (Exception. "Cannot find './resources/frontend_client/index.html'."))))
(throw (Exception. "Cannot find './resources/frontend_client/index.html'. Did you remember to build the Metabase frontend?"))))
{:bootstrap_json (json/generate-string (setting/public-settings))})
(slurp (io/resource "frontend_client/init.html")))
resp/response
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment