Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
B
bi-report
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
data
bi-report
Commits
3f33c411
Commit
3f33c411
authored
May 29, 2020
by
赵建伟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update codes
parent
376114b1
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
29 additions
and
13 deletions
+29
-13
workspace.xml
.idea/workspace.xml
+4
-2
workspace.xml
lib/java/bi-report-service/.idea/workspace.xml
+14
-11
HivesqlServiceImpl.java
.../data/gateway/server/service/impl/HivesqlServiceImpl.java
+3
-0
SparksqlServiceImpl.java
...data/gateway/server/service/impl/SparksqlServiceImpl.java
+6
-0
start_service.sh
sbin/start_service.sh
+2
-0
No files found.
.idea/workspace.xml
View file @
3f33c411
<?xml version="1.0" encoding="UTF-8"?>
<project
version=
"4"
>
<component
name=
"ChangeListManager"
>
<list
default=
"true"
id=
"18c38e3b-9b7f-4a3f-b141-edcb320b1d24"
name=
"Default Changelist"
comment=
""
/>
<list
default=
"true"
id=
"18c38e3b-9b7f-4a3f-b141-edcb320b1d24"
name=
"Default Changelist"
comment=
""
>
<change
beforePath=
"$PROJECT_DIR$/sbin/start_service.sh"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/sbin/start_service.sh"
afterDir=
"false"
/>
</list>
<option
name=
"SHOW_DIALOG"
value=
"false"
/>
<option
name=
"HIGHLIGHT_CONFLICTS"
value=
"true"
/>
<option
name=
"HIGHLIGHT_NON_ACTIVE_CHANGELIST"
value=
"false"
/>
...
...
@@ -127,7 +129,7 @@
<workItem
from=
"1588761853482"
duration=
"3826000"
/>
<workItem
from=
"1588905392183"
duration=
"4522000"
/>
<workItem
from=
"1589447155495"
duration=
"19738000"
/>
<workItem
from=
"1590723962134"
duration=
"
470
000"
/>
<workItem
from=
"1590723962134"
duration=
"
914
000"
/>
</task>
<task
id=
"LOCAL-00001"
summary=
"add init codes."
>
<created>
1587723565207
</created>
...
...
lib/java/bi-report-service/.idea/workspace.xml
View file @
3f33c411
<?xml version="1.0" encoding="UTF-8"?>
<project
version=
"4"
>
<component
name=
"ChangeListManager"
>
<list
default=
"true"
id=
"73604af3-3cbc-41f8-9a5f-e6a14a2ada76"
name=
"Default Changelist"
comment=
"add"
/>
<list
default=
"true"
id=
"73604af3-3cbc-41f8-9a5f-e6a14a2ada76"
name=
"Default Changelist"
comment=
"add"
>
<change
beforePath=
"$PROJECT_DIR$/../../../sbin/start_service.sh"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/../../../sbin/start_service.sh"
afterDir=
"false"
/>
</list>
<option
name=
"SHOW_DIALOG"
value=
"false"
/>
<option
name=
"HIGHLIGHT_CONFLICTS"
value=
"true"
/>
<option
name=
"HIGHLIGHT_NON_ACTIVE_CHANGELIST"
value=
"false"
/>
...
...
@@ -217,6 +219,7 @@
<workItem
from=
"1588837331043"
duration=
"673000"
/>
<workItem
from=
"1589455301393"
duration=
"17006000"
/>
<workItem
from=
"1590398287572"
duration=
"8449000"
/>
<workItem
from=
"1590724213753"
duration=
"947000"
/>
</task>
<servers
/>
</component>
...
...
@@ -286,32 +289,32 @@
</state>
<state
x=
"553"
y=
"153"
key=
"CommitChangelistDialog2/246.1080.1920.1151/0.22.1920.1058@0.22.1920.1058"
timestamp=
"1584956237641"
/>
<state
x=
"784"
y=
"1223"
key=
"CommitChangelistDialog2/246.1080.1920.1151/0.22.1920.1058@246.1080.1920.1151"
timestamp=
"1588154132365"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.bottom"
timestamp=
"1590
487369269
"
>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.bottom"
timestamp=
"1590
724671694
"
>
<screen
x=
"1752"
y=
"1200"
width=
"1920"
height=
"1151"
/>
</state>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.bottom/0.22.1920.1129@0.22.1920.1129"
timestamp=
"1588761074648"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.bottom/1752.1200.1920.1151/0.22.1920.1178/1920.120.1920.1080@1752.1200.1920.1151"
timestamp=
"1590
487369269
"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.bottom/1752.1200.1920.1151/0.22.1920.1178/1920.120.1920.1080@1752.1200.1920.1151"
timestamp=
"1590
724671694
"
/>
<state
width=
"1878"
height=
"321"
key=
"GridCell.Tab.0.bottom/246.1080.1920.1151/0.22.1920.1058@0.22.1920.1058"
timestamp=
"1584688137007"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.bottom/246.1080.1920.1151/0.22.1920.1058@246.1080.1920.1151"
timestamp=
"1588838004638"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.center"
timestamp=
"1590
487369267
"
>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.center"
timestamp=
"1590
724671693
"
>
<screen
x=
"1752"
y=
"1200"
width=
"1920"
height=
"1151"
/>
</state>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.center/0.22.1920.1129@0.22.1920.1129"
timestamp=
"1588761074647"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.center/1752.1200.1920.1151/0.22.1920.1178/1920.120.1920.1080@1752.1200.1920.1151"
timestamp=
"1590
487369267
"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.center/1752.1200.1920.1151/0.22.1920.1178/1920.120.1920.1080@1752.1200.1920.1151"
timestamp=
"1590
724671693
"
/>
<state
width=
"1878"
height=
"321"
key=
"GridCell.Tab.0.center/246.1080.1920.1151/0.22.1920.1058@0.22.1920.1058"
timestamp=
"1584688137005"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.center/246.1080.1920.1151/0.22.1920.1058@246.1080.1920.1151"
timestamp=
"1588838004637"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.left"
timestamp=
"1590
487369265
"
>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.left"
timestamp=
"1590
724671692
"
>
<screen
x=
"1752"
y=
"1200"
width=
"1920"
height=
"1151"
/>
</state>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.left/0.22.1920.1129@0.22.1920.1129"
timestamp=
"1588761074647"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.left/1752.1200.1920.1151/0.22.1920.1178/1920.120.1920.1080@1752.1200.1920.1151"
timestamp=
"1590
487369265
"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.left/1752.1200.1920.1151/0.22.1920.1178/1920.120.1920.1080@1752.1200.1920.1151"
timestamp=
"1590
724671692
"
/>
<state
width=
"1878"
height=
"321"
key=
"GridCell.Tab.0.left/246.1080.1920.1151/0.22.1920.1058@0.22.1920.1058"
timestamp=
"1584688137005"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.left/246.1080.1920.1151/0.22.1920.1058@246.1080.1920.1151"
timestamp=
"1588838004636"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.right"
timestamp=
"1590
487369268
"
>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.right"
timestamp=
"1590
724671694
"
>
<screen
x=
"1752"
y=
"1200"
width=
"1920"
height=
"1151"
/>
</state>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.right/0.22.1920.1129@0.22.1920.1129"
timestamp=
"1588761074648"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.right/1752.1200.1920.1151/0.22.1920.1178/1920.120.1920.1080@1752.1200.1920.1151"
timestamp=
"1590
487369268
"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.right/1752.1200.1920.1151/0.22.1920.1178/1920.120.1920.1080@1752.1200.1920.1151"
timestamp=
"1590
724671694
"
/>
<state
width=
"1878"
height=
"321"
key=
"GridCell.Tab.0.right/246.1080.1920.1151/0.22.1920.1058@0.22.1920.1058"
timestamp=
"1584688137006"
/>
<state
width=
"1878"
height=
"243"
key=
"GridCell.Tab.0.right/246.1080.1920.1151/0.22.1920.1058@246.1080.1920.1151"
timestamp=
"1588838004637"
/>
<state
width=
"1878"
height=
"395"
key=
"GridCell.Tab.1.bottom"
timestamp=
"1590137977817"
>
...
...
@@ -338,11 +341,11 @@
<screen
x=
"0"
y=
"22"
width=
"1920"
height=
"1058"
/>
</state>
<state
x=
"560"
y=
"291"
key=
"Vcs.Push.Dialog.v2/246.1080.1920.1151/0.22.1920.1058@0.22.1920.1058"
timestamp=
"1584949293518"
/>
<state
x=
"2221"
y=
"1390"
width=
"670"
height=
"675"
key=
"run.anything.popup"
timestamp=
"1590
40220334
4"
>
<state
x=
"2221"
y=
"1390"
width=
"670"
height=
"675"
key=
"run.anything.popup"
timestamp=
"1590
72465060
4"
>
<screen
x=
"1752"
y=
"1200"
width=
"1920"
height=
"1151"
/>
</state>
<state
x=
"469"
y=
"208"
width=
"670"
height=
"663"
key=
"run.anything.popup/0.22.1920.1129@0.22.1920.1129"
timestamp=
"1588345465540"
/>
<state
x=
"2221"
y=
"1390"
width=
"670"
height=
"675"
key=
"run.anything.popup/1752.1200.1920.1151/0.22.1920.1178/1920.120.1920.1080@1752.1200.1920.1151"
timestamp=
"1590
40220334
4"
/>
<state
x=
"2221"
y=
"1390"
width=
"670"
height=
"675"
key=
"run.anything.popup/1752.1200.1920.1151/0.22.1920.1178/1920.120.1920.1080@1752.1200.1920.1151"
timestamp=
"1590
72465060
4"
/>
<state
x=
"715"
y=
"1270"
width=
"670"
height=
"675"
key=
"run.anything.popup/246.1080.1920.1151/0.22.1920.1058@246.1080.1920.1151"
timestamp=
"1588837938694"
/>
<state
x=
"2330"
y=
"1458"
width=
"764"
height=
"676"
key=
"search.everywhere.popup"
timestamp=
"1589943432014"
>
<screen
x=
"1752"
y=
"1200"
width=
"1920"
height=
"1151"
/>
...
...
lib/java/bi-report-service/service-server/src/main/java/com/gmei/data/gateway/server/service/impl/HivesqlServiceImpl.java
View file @
3f33c411
package
com
.
gmei
.
data
.
gateway
.
server
.
service
.
impl
;
import
com.gmei.data.gateway.server.service.HivesqlService
;
import
com.gmei.data.gateway.server.utils.DateUtils
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Value
;
...
...
@@ -59,6 +60,8 @@ public class HivesqlServiceImpl implements HivesqlService {
}
}
String
hql
=
sbf
.
toString
();
hql
=
hql
.
replaceAll
(
"#partition_date"
,
String
.
format
(
"'%s'"
,
DateUtils
.
getYesterdayDateSimpleStr
()))
.
replaceAll
(
"#partition_day"
,
String
.
format
(
"'%s'"
,
DateUtils
.
getYesterdayDateSimpleStr
()));
Connection
conn
=
null
;
try
{
...
...
lib/java/bi-report-service/service-server/src/main/java/com/gmei/data/gateway/server/service/impl/SparksqlServiceImpl.java
View file @
3f33c411
...
...
@@ -2,6 +2,7 @@ package com.gmei.data.gateway.server.service.impl;
import
com.gmei.data.gateway.server.dto.ExcelGenDto
;
import
com.gmei.data.gateway.server.service.SparksqlService
;
import
com.gmei.data.gateway.server.utils.DateUtils
;
import
com.gmei.data.gateway.server.utils.ProperUtils
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
...
...
@@ -63,6 +64,8 @@ public class SparksqlServiceImpl implements SparksqlService {
}
}
String
hql
=
sbf
.
toString
();
hql
=
hql
.
replaceAll
(
"#partition_date"
,
String
.
format
(
"'%s'"
,
DateUtils
.
getYesterdayDateSimpleStr
()))
.
replaceAll
(
"#partition_day"
,
String
.
format
(
"'%s'"
,
DateUtils
.
getYesterdayDateSimpleStr
()));
Connection
conn
=
null
;
try
{
...
...
@@ -132,6 +135,9 @@ public class SparksqlServiceImpl implements SparksqlService {
}
}
String
hql
=
sbf
.
toString
();
hql
=
hql
.
replaceAll
(
"#partition_date"
,
String
.
format
(
"'%s'"
,
DateUtils
.
getYesterdayDateSimpleStr
()))
.
replaceAll
(
"#partition_day"
,
String
.
format
(
"'%s'"
,
DateUtils
.
getYesterdayDateSimpleStr
()));
Connection
conn
=
null
;
try
{
conn
=
DriverManager
.
getConnection
(
sparkSqlJdbcUrl
,
"data"
,
""
);
...
...
sbin/start_service.sh
View file @
3f33c411
#!/bin/bash
nohup
java
-jar
/home/bi/bi-report/lib/java/bi-report-service/service-server/target/report-service-server-1.0.0-SNAPSHOT.jar
>>
/data/bi-report/logs/bi-report-service.out 2>&1 &
tail
-100f
/data/bi-report/logs/bi-report-service.out
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment