Apache点燃查询卡住了

时间:2016-09-26 07:00:10

标签: apache gridgain ignite

我尝试在apache点火中查询缓存的数据库,然后我得到了跟踪日志并且卡住了

本地节点的度量标准(禁用将'metricsLogFrequency'设置为0)     ^ - 节点[id = c7f54d16,name = null,uptime = 00:01:00:002]     ^ - H / N / C [主机= 1,节点= 2,CPU = 4]     ^ - CPU [cur = 0.17%,avg = 5.01%,GC = 0%]     ^ - 堆[used = 851MB,free = 53.2%,comm = 1031MB]     ^ - 非堆[used = 58MB,free = -1%,comm = 59MB]     ^ - 公共线程池[active = 0,idle = 6,qSize = 0]     ^ - 系统线程池[active = 0,idle = 16,qSize = 0]     ^ - 出站邮件队列[size = 0]

我做错了什么?

查询哪些无效

 SELECT  DISTINCT  m1 AS m1,m1_TYP AS m1_TYP FROM (SELECT entry AS a5,QS5.a1 AS a1,QS5.a4 AS a4,QS5.m1 AS m1,m1_TYP AS m1_TYP
 FROM abc AS T,(SELECT entity AS m1,typ AS m1_typ,elem AS a5,QS4.a1 AS a1,QS4.a4 AS a4
 FROM xyz AS T,(SELECT entry AS a2,QS3.a1 AS a1,QS3.a4 AS a4,QS3.m1 AS m1,m1_TYP AS m1_TYP
 FROM abc AS T,(SELECT entry AS a4,QS2.a1 AS a1,QS2.a2 AS a2,QS2.m1 AS m1,m1_TYP AS m1_TYP
 FROM abc AS T,(SELECT entry AS a3,QS1.a1 AS a1,QS1.a2 AS a2,QS1.a4 AS a4,QS1.m1 AS m1,m1_TYP AS m1_TYP
 FROM abc AS T,(SELECT a1 AS a1,COALESCE(S4.elem,val4) AS a4,m1 AS m1,m1_TYP AS m1_TYP,COALESCE(S2.elem,val2) AS a2,COALESCE(S3.elem,val3) AS a3
 FROM (SELECT entry AS a1,T.val6 AS VAL4,T.val2 AS m1,T.typ2 AS m1_TYP,T.val8 AS VAL2,T.val6 AS VAL3
 FROM abc AS T,(SELECT elem AS a1
 FROM xyz AS T
 WHERE entity = '3' AND typ = 5001 
  AND    (prop = '1oh~#has_neighbours')) AS QS0 WHERE  entry = QS0.a1 
  AND   (T.prop0 = '4xm~#type' AND T.prop8 = '1oh~#has_double_bond' AND T.prop6 = '1oh~#has_single_bond' AND T.prop6 = '1oh~#has_single_bond' AND T.prop2 = '1oh~#is_atom_of')
  AND  T.val0 = '7a~') AS Q1 LEFT OUTER JOIN efg AS S4 ON  Q1.VAL4 = S4.list_id LEFT OUTER JOIN efg AS S2 ON  Q1.VAL2 = S2.list_id LEFT OUTER JOIN efg AS S3 ON  Q1.VAL3 = S3.list_id
   WHERE   (  (a1  <>  COALESCE(S4.elem,val4) 
) )) AS QS1 WHERE entry = QS1.a3 
  AND    (T.prop0 = '4xm~#type' AND T.prop5 = '1oh~#has_neighbours' AND T.prop8 = '1oh~#has_charge')
  AND  T.val0 = '562~' AND T.val5 = '1' AND T.val8 = '6o7~') AS QS2 WHERE entry = QS2.a4 
  AND    (T.prop0 = '4xm~#type' AND T.prop5 = '1oh~#has_neighbours')
  AND  T.val0 = '7a~' AND T.val5 = '1') AS QS3 WHERE entry = QS3.a2 
  AND    (T.prop0 = '4xm~#type' AND T.prop5 = '1oh~#has_neighbours')
  AND  T.val0 = '562~' AND T.val5 = '1') AS QS4 WHERE entity = QS4.m1 AND typ = QS4.m1_TYP 
  AND    (prop = '1oh~#is_atom_of')) AS QS5 WHERE entry = QS5.a5 
  AND    (T.prop0 = '4xm~#type' AND T.prop5 = '1oh~#has_neighbours')
  AND  T.val0 = '1eg~' AND T.val5 = '0') AS QS6 LIMIT 100  

查询哪些有效

 SELECT  m1 AS m1,m1_TYP AS m1_TYP FROM (SELECT entry AS a2,QS3.a1 AS a1,QS3.a4 AS a4,QS3.m1 AS m1,m1_TYP AS m1_TYP
 FROM abc AS T,(SELECT entry AS a3,QS2.a1 AS a1,QS2.a2 AS a2,QS2.a4 AS a4,QS2.m1 AS m1,m1_TYP AS m1_TYP
 FROM abc AS T,(SELECT entry AS a4,QS1.a1 AS a1,QS1.a2 AS a2,QS1.a3 AS a3,QS1.m1 AS m1,m1_TYP AS m1_TYP
 FROM abc AS T,(SELECT a1 AS a1,m1 AS m1,m1_TYP AS m1_TYP,COALESCE(S3.elem,val3) AS a3,COALESCE(S4.elem,val4) AS a4,COALESCE(S2.elem,val2) AS a2
 FROM (SELECT entry AS a1,T.val2 AS m1,T.typ2 AS m1_TYP,T.val8 AS VAL3,T.val6 AS VAL4,T.val6 AS VAL2
 FROM abc AS T,(SELECT elem AS a1
 FROM xyz AS T
 WHERE entity = '3' AND typ = 5001 
  AND    (prop = '1oh~#has_neighbours')) AS QS0 WHERE  entry = QS0.a1 
  AND   (T.prop0 = '4xm~#type' AND T.prop6 = '1oh~#has_single_bond' AND T.prop8 = '1oh~#has_double_bond' AND T.prop6 = '1oh~#has_single_bond' AND T.prop2 = '1oh~#is_atom_of')
  AND  T.val0 = '7a~') AS Q1 LEFT OUTER JOIN efg AS S3 ON  Q1.VAL3 = S3.list_id LEFT OUTER JOIN efg AS S4 ON  Q1.VAL4 = S4.list_id LEFT OUTER JOIN efg AS S2 ON  Q1.VAL2 = S2.list_id
   WHERE   (  (a1  <>  COALESCE(S4.elem,val4) 
) )) AS QS1 WHERE entry = QS1.a4 
  AND    (T.prop0 = '4xm~#type' AND T.prop5 = '1oh~#has_neighbours')
  AND  T.val0 = '7a~' AND T.val5 = '1') AS QS2 WHERE entry = QS2.a3 
  AND    (T.prop0 = '4xm~#type' AND T.prop5 = '1oh~#has_neighbours')
  AND  T.val0 = '562~' AND T.val5 = '1') AS QS3 WHERE entry = QS3.a2 
  AND    (T.prop0 = '4xm~#type' AND T.prop5 = '1oh~#has_neighbours')
  AND  T.val0 = '562~' AND T.val5 = '1') AS QS4 LIMIT 100  

1 个答案:

答案 0 :(得分:0)

这只是当前指标的输出,默认情况下每分钟打印一次。为什么你认为查询被卡住了?您很可能只是没有正确配置索引,因此需要花费大量时间。有关如何执行此操作的详细信息,请参阅此文档:https://apacheignite.readme.io/docs/sql-queries