我们观察到StackDriver报告的多个并发查询与我们在“data_access”日志中看到的并且数字报告我的“查询”度量标准之间的不一致。
从下午1点16分左右附带的图片中可以看出,并发查询的数量达到了87(不确定是否可能,因为并发查询配额为50),如果我们计算jobCompletedEvent来自“data_access”日志与createTimeTIMESTAMP(“2017-01-19 13:16:48”,“America / Los_Angeles”)我们只能看到24。
这个实例不是孤立的,我们发生了很多这样的事情。
SELECT
count(*)
FROM (
SELECT
createTime,
startTime,
endTime
FROM (
SELECT
protoPayload.serviceData.jobCompletedEvent.job.jobStatistics.createTime AS createTime,
protoPayload.serviceData.jobCompletedEvent.job.jobStatistics.startTime AS startTime,
protoPayload.serviceData.jobCompletedEvent.job.jobStatistics.endTime AS endTime
FROM
`catalog.cloudaudit_googleapis_com_data_access_201701*`))
WHERE
createTime<TIMESTAMP("2017-01-19 13:16:48","America/Los_Angeles")
AND endTime>TIMESTAMP("2017-01-19 13:16:48","America/Los_Angeles")
进一步调查它有点奇怪。如果我查看jobGetQueryResultsResponse stats
,这是查询 SELECT
insertId,
jobId,
createTime,
startTime,
endTime
FROM (
SELECT
insertId,
jobId,
createTime,
startTime,
endTime
FROM (
SELECT
insertId,
protoPayload.serviceData.jobGetQueryResultsResponse.job.jobName.jobId AS jobId,
protoPayload.serviceData.jobGetQueryResultsResponse.job.jobStatistics.createTime AS createTime,
protoPayload.serviceData.jobGetQueryResultsResponse.job.jobStatistics.startTime AS startTime,
protoPayload.serviceData.jobGetQueryResultsResponse.job.jobStatistics.endTime AS endTime,
protoPayload.status.message error
FROM
`catalog.cloudaudit_googleapis_com_data_access_201701*`))
WHERE
createTime<=TIMESTAMP("2017-01-19 13:16:48")
AND endTime>=TIMESTAMP("2017-01-19 13:16:48")
它现在返回321条记录(下面的代码段),其中有许多重复项具有唯一的insertID但是相同的jobId
116 5467305DA3861.A4954C2.780CB7F5 job__oFOLJVnNr8Xj7zFnNrgqww6_Ww 2017-01-19 13:16:35 UTC 2017-01-19 13:16:36 UTC 2017-01-19 13:16:53 UTC
117 54672C24D1181.A036F52.D205C885 bqjob_r31c3135d053792f3_00000159b6d384e3_1 2017-01-19 13:03:52 UTC 2017-01-19 13:03:55 UTC 2017-01-19 13:46:09 UTC
118 54672C333EB29.A498C8D.1E00E7D1 job__oFOLJVnNr8Xj7zFnNrgqww6_Ww 2017-01-19 13:16:35 UTC 2017-01-19 13:16:36 UTC 2017-01-19 13:16:53 UTC
119 5467285CC92D1.A496505.560166F3 job__oFOLJVnNr8Xj7zFnNrgqww6_Ww 2017-01-19 13:16:35 UTC 2017-01-19 13:16:36 UTC 2017-01-19 13:16:53 UTC
120 5467355C301E1.A49D803.540CE70C job__oFOLJVnNr8Xj7zFnNrgqww6_Ww 2017-01-19 13:16:35 UTC 2017-01-19 13:16:36 UTC 2017-01-19 13:16:53 UTC
121 54673441FDAF9.A49C44D.82036D2F job__oFOLJVnNr8Xj7zFnNrgqww6_Ww 2017-01-19 13:16:35 UTC 2017-01-19 13:16:36 UTC 2017-01-19 13:16:53 UTC
这是否会引发不一致以及配额影响是什么。您能否澄清一下如何计算“查询计数”度量标准。 BigQuery StackDriver日志的可靠性如何,以及从“data_access”日志获取准确计数的最佳方法是什么。