[GitHub] incubator-griffin pull request #401: Fix UI bugs

2018-08-22 Thread icesmartjuan
GitHub user icesmartjuan opened a pull request:

https://github.com/apache/incubator-griffin/pull/401

Fix UI bugs 

1. In profiling, when selecting rule on UI, for "Enum detection Top5 
count", it generates rule like:
{
"rule": "source.desc, desc, count(*) AS count GROUP BY source.desc 
ORDER BY count DESC LIMIT 5",
"dsl.type": "griffin-dsl",
"dq.type": "PROFILING"
}
Actually, we need it to be like:
{
"rule": "source.desc AS desc, count(*) AS count GROUP BY 
source.desc ORDER BY count DESC LIMIT 5",
"dsl.type": "griffin-dsl",
"dq.type": "PROFILING",
"out": [
{
"type": "metric",
"name": "desc_group",
"flatten": "array"
}
]
}
To flatten the group by metric as an array, and naming it as "${the group 
column name}_group". Then the metric will be like:
{"name":"prof_job","tmst":153476850,"value":{"desc_group":[{"desc": 
"aaa", "count": 3}, {"desc": "bbb", "count": 5}]}}

Please notice that there're 2 mistakes in current enum rule, one is the 
"rule" content, the other one is the lack of "out" field.

2. There's a bug in Dashboard page, when refreshing, it works good, and a 
metric chart is painted. But after select the measure drop-down box, the chart 
size is collapsed into a line, which is terrible.

3. In "partition configuration" pages of creating accuracy measure, the 
item "Time Zone" is blank by default, but in the same page of creating 
profiling measure, the item "Time Zone" has a default value, which should act 
the same as the accuracy measure creation page.

4. In "Select Models" page of creating profiling measure, when you select 
"Regular Expression Detection Count" as a rule for a string column, there will 
be a text box below, for regular expression. I think the UI is not bad so far.
However, it doesn't work in a right way. The rule it generates is like:
{
"rule": "count(source.desc RLIKE '^[0-9]{4}$') AS 
`desc_regexcount`",
"dsl.type": "griffin-dsl",
"dq.type": "PROFILING"
}
After test, it returns total count of the column, which means the statement 
"RLIKE" doesn't work. We need to change it like this:
{
"rule": "count(source.desc) AS `desc_regexcount` WHERE source.desc 
RLIKE '^[0-9]{4}$'",
"dsl.type": "griffin-dsl",
"dq.type": "PROFILING"
}
I've tested the latter, it works.

5. For "Download Miss Sample" page, the item list seems a litte strange, it 
would be better to list them in a table and hover with a hand pointer rather 
than a text cursor. Besides, sometimes it's slow for the downloading, I think 
it's better to tell user to wait after a click.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/icesmartjuan/incubator-griffin fix_ui_bugs

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/incubator-griffin/pull/401.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #401


commit f9d54f6b451d79a122e9473c80853362bd1e2827
Author: Li, Juan 
Date:   2018-08-22T07:57:25Z

Fix UI bugs:
1. In profiling, when selecting rule on UI, for "Enum detection Top5 
count", it generates rule like:
{
"rule": "source.desc, desc, count(*) AS count GROUP BY source.desc 
ORDER BY count DESC LIMIT 5",
"dsl.type": "griffin-dsl",
"dq.type": "PROFILING"
}
Actually, we need it to be like:
{
"rule": "source.desc AS desc, count(*) AS count GROUP BY 
source.desc ORDER BY count DESC LIMIT 5",
"dsl.type": "griffin-dsl",
"dq.type": "PROFILING",
"out": [
{
"type": "metric",
"name": "desc_group",
"flatten": "array"
}
]
}
To flatten the group by metric as an array, and naming it as "${the group 
column name}_group". Then the metric will be like:
{"name":"prof_job","tmst":153476850,"value":{"desc_group":[{"desc": 
"aaa", "count": 3}, {"desc": "bbb", "count": 5}]}}

Please notice that there're 2 mistakes in current enum rule, one is the 
"rule" content, the other one is the lack of "out" field.

2. There's a bug in Dashboard page, when refreshing, it works good, and a 
metric chart is painted. But after select the measure drop-down box, the chart 
size is collapsed into a line, which is terrible.

3. In "partition configuration" pages of creating accuracy measure, the 
item "Time Zone" is blank by default, but in the same page of creating 
profiling 

[GitHub] incubator-griffin pull request #400: fix bugs of measure and service module ...

2018-08-22 Thread bhlx3lyx7
GitHub user bhlx3lyx7 opened a pull request:

https://github.com/apache/incubator-griffin/pull/400

fix bugs of measure and service module for new json format



You can merge this pull request into a Git repository by running:

$ git pull https://github.com/bhlx3lyx7/incubator-griffin json-update-new

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/incubator-griffin/pull/400.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #400


commit 6260e2bacc6fc55286e4a4e584e990a07a6a4b57
Author: Lionel Liu 
Date:   2018-08-22T07:39:51Z

fix bugs of measure and service module after json format update




---


[GitHub] incubator-griffin pull request #399: Fix bugs of measure and service module ...

2018-08-22 Thread bhlx3lyx7
Github user bhlx3lyx7 closed the pull request at:

https://github.com/apache/incubator-griffin/pull/399


---