Re: Kylin ODBC

2016-09-14 Thread Alberto Ramón
The cube is the Kylin Example, the fact table have 9.800 Row, and return
time to Kylin UI are 0.3 Seconds
and CATEGORY_GROUPINGS has 144 rows

==> I think isnt't a performance problem

*sound like , cast problem, overflow of int, or Nulls*
But I don't Know the which Row / Column have a problematic Value in any log
  :(

2016-09-14 8:08 GMT+02:00 Abhilash L L :

> Hello Alberto,
>
> When the request is made via the Kylin UI, it adds an 'accept partial'
> flag, which is similar to a 'limit' in sql world.
>
> When the query is being sent over odbc, kylin server is expected to
> send all the records as the output
>
>  Please check the thread titled 'kylin cube performance' for more
> information.
>
> Regards,
> Abhilash
>
> On Wed, Sep 14, 2016 at 10:48 AM, Alberto Ramón  > wrote:
>
>> I found this
>> From Kylin ODBC LOG:
>>
>> *[INFO ][2016-09-14.06:48:47]select "PART_DT", *
>> *"LEAF_CATEG_ID", *
>> *"LSTG_SITE_ID", *
>> *"LSTG_FORMAT_NAME", *
>> *"PRICE", *
>> *"SELLER_ID" *
>> *from "DEFAULT"."KYLIN_SALES"*
>> *[ERROR][2016-09-14.06:49:53]The REST query request failed, the error
>> message is: Error while executing SQL "select "PART_DT",
>> "LEAF_CATEG_ID",  "LSTG_SITE_ID",  "LSTG_FORMAT_NAME",
>> "PRICE",  "SELLER_ID"  from "DEFAULT"."KYLIN_SALES"": Timeout visiting
>> cube!*
>>
>> This querie *from Microsoft, never finish* or kill my HBase, but from
>> Kylin UI works fine < 0.5 sec
>>
>> 2016-09-14 6:49 GMT+02:00 Alberto Ramón :
>>
>>> Hello
>>> I tested New Microsoft Power BI with Kylin
>>> [image: Imágenes integradas 1]
>>> With KYLIN_CAL_DT connector can read data:
>>> [image: Imágenes integradas 2]
>>>
>>>
>>> But with KYLIN GROUPING AND SALES:
>>> And I have this error
>>>
>>> Unexpected error: *Value was either too large or too small for an
>>> Int32.*
>>> Details:
>>> Microsoft.Mashup.Evaluator.Interface.ErrorException: Value was
>>> either too large or too small for an Int32. --->
>>> Microsoft.Mashup.Evaluator.Interface.ErrorException: Value was either
>>> too large or too small for an Int32. ---> 
>>> Microsoft.Mashup.Evaluator.Interface.ErrorException:
>>> Value was either too large or too small for an Int32. --->
>>> Microsoft.Mashup.Evaluator.Interface.ErrorException: Value was either
>>> too large or too small for an Int32. ---> 
>>> Microsoft.Mashup.Evaluator.Interface.ErrorException:
>>> Value was either too large or too small for an Int32. --->
>>> System.OverflowException: Value was either too large or too small for an
>>> Int32. ---> System.OverflowException: Value was either too large or too
>>> small for an Int32.
>>>at System.Convert.ToInt32(Int64 value)
>>>at Microsoft.Mashup.Engine1.Library.Odbc.OdbcDataReaderExtensio
>>> ns.GetNullableInt32(IDataReader reader, Int32 ordinal)
>>>
>>>
>>> Some idea?
>>> In true, I have also problems of connectivity using:Qlik and Sisense
>>> Software
>>>
>>
>>
>


Re: How does Kylin communicate with underlying Hadoop services ?

2016-09-14 Thread Billy(Yiming) Liu
Hive is the data source, not the query engine for Kylin. Kylin is the query
engine itself.
The Hive command you found is the command to retrieve the data source, not
user query.

2016-09-14 10:42 GMT+08:00 udana pathirana :

> So basically you execute Beeline or Hive command to send queries to
> Hive.(according to the logs , I could see  the same thing).
> I am just curious, you didn't you use JDBC connection to HiveServer2
> (thrift server) instead , without executing system commands.
> Something like :
>
> Connection con = DriverManager.getConnection("jdbc:hive://hive-server.
> hadoop.local:1/", "", "");
> Statement stmt = con.createStatement();
> String tableName = "testHiveDriverTable";
>
> On Mon, Sep 12, 2016 at 9:46 PM, Yiming Liu 
> wrote:
>
>> 1. Yes
>> 2. Both Hive CLI and Beeline are supported. check kylin.hive.client in
>> kylin.properties
>> 3. Yes. ZK works as a lock service for cube build.
>>
>> 2016-09-12 10:00 GMT+08:00 udana pathirana :
>>
>>> I have some questions about how Kylin connects to different services
>>>
>>> 1) Does Kylin communicate with HBase using hbase-client library
>>> (org.apache.hadoop.hbase.client.Connection) ? I assume it reads HBase
>>> master node/port from the hbase-site.xml ?
>>>
>>> 2) Does Kylin communicate with Hive using JDBC/SQL protocol? Same as
>>> Beeline ? If so, does it read Hive server/port from hive-site.xml ?
>>>
>>> 3) Does Kylin connect to ZK ? IF so why ? How does it connect ; using
>>> zkCli or client library ?
>>>
>>
>>
>>
>> --
>> With Warm regards
>>
>> Yiming Liu (刘一鸣)
>>
>
>


-- 
With Warm regards

Yiming Liu (刘一鸣)


答复: which cube to use when u build many cubes under a model

2016-09-14 Thread 仇同心
 Kylin completed a customized Adapter, completed in Calcite SQL parsing, 
forming a syntax tree (AST), defined by Kylin syntax tree each node query 
execution rules.Calcite after traversal syntax tree node generated a Kylin 
describe the Digest of the query model, Kylin will Digest to judge whether 
there is a match for this Cube.If there is a Cube with the query matching, that 
is, to choose a minimum Cost of query to query the Cube (KylinCube query Cost 
calculation is an open interface, can according to the number of dimensions, 
can be based on the quantity to calculate Cost data)

In CubeInstance.java:

You  can see:
  @Override
public CapabilityResult isCapable(SQLDigest digest) {
CapabilityResult result = CubeCapabilityChecker.check(this, digest);
if (result.capable) {
result.cost = getCost(digest);
for (CapabilityInfluence i : result.influences) {
result.cost *= (i.suggestCostMultiplier() == 0) ? 1.0 : 
i.suggestCostMultiplier();
}
} else {
result.cost = -1;
}
return result;
}

private int getCost(SQLDigest digest) {
int calculatedCost = cost;

//the number of dimensions is not as accurate as number of row key cols
calculatedCost += getRowKeyColumnCount() * COST_WEIGHT_DIMENSION + 
getMeasures().size() * COST_WEIGHT_MEASURE;

for (LookupDesc lookupDesc : 
this.getDescriptor().getModel().getLookups()) {
// more tables, more cost
if ("inner".equals(lookupDesc.getJoin().getType())) {
// inner join cost is bigger than left join, as it will filter 
some records
calculatedCost += COST_WEIGHT_INNER_JOIN;
}
}

return calculatedCost;
}

发件人: Mars J [mailto:xujiao.myc...@gmail.com]
发送时间: 2016年9月13日 15:04
收件人: user@kylin.apache.org
主题: which cube to use when u build many cubes under a model

Hi ,
 I'm every curious about that if I define and build many cubes under one 
specific model, e.g cube1,cube2,cube3, these cubes may have same dimensions, so 
if a query invole such a dimension ,which cube kylin will use to respond ?


Re: Kylin ODBC

2016-09-14 Thread Abhilash L L
Hello Alberto,

When the request is made via the Kylin UI, it adds an 'accept partial'
flag, which is similar to a 'limit' in sql world.

When the query is being sent over odbc, kylin server is expected to
send all the records as the output

 Please check the thread titled 'kylin cube performance' for more
information.

Regards,
Abhilash

On Wed, Sep 14, 2016 at 10:48 AM, Alberto Ramón 
wrote:

> I found this
> From Kylin ODBC LOG:
>
> *[INFO ][2016-09-14.06:48:47]select "PART_DT", *
> *"LEAF_CATEG_ID", *
> *"LSTG_SITE_ID", *
> *"LSTG_FORMAT_NAME", *
> *"PRICE", *
> *"SELLER_ID" *
> *from "DEFAULT"."KYLIN_SALES"*
> *[ERROR][2016-09-14.06:49:53]The REST query request failed, the error
> message is: Error while executing SQL "select "PART_DT",
> "LEAF_CATEG_ID",  "LSTG_SITE_ID",  "LSTG_FORMAT_NAME",
> "PRICE",  "SELLER_ID"  from "DEFAULT"."KYLIN_SALES"": Timeout visiting
> cube!*
>
> This querie *from Microsoft, never finish* or kill my HBase, but from
> Kylin UI works fine < 0.5 sec
>
> 2016-09-14 6:49 GMT+02:00 Alberto Ramón :
>
>> Hello
>> I tested New Microsoft Power BI with Kylin
>> [image: Imágenes integradas 1]
>> With KYLIN_CAL_DT connector can read data:
>> [image: Imágenes integradas 2]
>>
>>
>> But with KYLIN GROUPING AND SALES:
>> And I have this error
>>
>> Unexpected error: *Value was either too large or too small for an Int32.*
>> Details:
>> Microsoft.Mashup.Evaluator.Interface.ErrorException: Value was
>> either too large or too small for an Int32. --->
>> Microsoft.Mashup.Evaluator.Interface.ErrorException: Value was either
>> too large or too small for an Int32. ---> 
>> Microsoft.Mashup.Evaluator.Interface.ErrorException:
>> Value was either too large or too small for an Int32. --->
>> Microsoft.Mashup.Evaluator.Interface.ErrorException: Value was either
>> too large or too small for an Int32. ---> 
>> Microsoft.Mashup.Evaluator.Interface.ErrorException:
>> Value was either too large or too small for an Int32. --->
>> System.OverflowException: Value was either too large or too small for an
>> Int32. ---> System.OverflowException: Value was either too large or too
>> small for an Int32.
>>at System.Convert.ToInt32(Int64 value)
>>at Microsoft.Mashup.Engine1.Library.Odbc.OdbcDataReaderExtensio
>> ns.GetNullableInt32(IDataReader reader, Int32 ordinal)
>>
>>
>> Some idea?
>> In true, I have also problems of connectivity using:Qlik and Sisense
>> Software
>>
>
>