Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gic-cloud
Overview
Overview
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-hook
gic-cloud
Commits
3c96e6d0
Commit
3c96e6d0
authored
Apr 07, 2023
by
fudahua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 新版本的下载
parent
ab91d833
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
3 deletions
+2
-3
FlatQueryResultServiceImpl.java
...ud/data/hook/service/impl/FlatQueryResultServiceImpl.java
+2
-3
No files found.
gic-cloud-data-hook-service/src/main/java/com/gic/cloud/data/hook/service/impl/FlatQueryResultServiceImpl.java
View file @
3c96e6d0
...
@@ -677,6 +677,7 @@ public class FlatQueryResultServiceImpl implements IFlatQueryResultService {
...
@@ -677,6 +677,7 @@ public class FlatQueryResultServiceImpl implements IFlatQueryResultService {
if
(
CollectionUtils
.
isNotEmpty
(
downloadTasks
))
{
if
(
CollectionUtils
.
isNotEmpty
(
downloadTasks
))
{
for
(
DownloadTask
downloadTask
:
downloadTasks
)
{
for
(
DownloadTask
downloadTask
:
downloadTasks
)
{
downloadTask
.
setStatus
(
DownloadTaskStatus
.
BUILDING
);
downloadTask
.
setStatus
(
DownloadTaskStatus
.
BUILDING
);
downloadTask
.
setDownloadTime
(
new
Date
());
DownloadTaskServiceImpl
.
getInstance
().
updateDownloadTask
(
downloadTask
);
DownloadTaskServiceImpl
.
getInstance
().
updateDownloadTask
(
downloadTask
);
}
}
}
}
...
@@ -863,14 +864,12 @@ public class FlatQueryResultServiceImpl implements IFlatQueryResultService {
...
@@ -863,14 +864,12 @@ public class FlatQueryResultServiceImpl implements IFlatQueryResultService {
return
;
return
;
}
}
FlatQueryTaskCondition
condition
=
JSON
.
parseObject
(
task
.
getDownloadCondition
(),
FlatQueryTaskCondition
.
class
);
FlatQueryTaskCondition
condition
=
JSON
.
parseObject
(
task
.
getDownloadCondition
(),
FlatQueryTaskCondition
.
class
);
if
(!
task
.
getStatus
().
equals
(
DownloadTaskStatus
.
DOWNLOAD_HDFS
))
{
if
(!
task
.
getStatus
().
equals
(
DownloadTaskStatus
.
BUILDING
))
{
logger
.
info
(
"文件hdfs没有处理完成:{}"
,
JSONObject
.
toJSONString
(
task
));
logger
.
info
(
"文件hdfs没有处理完成:{}"
,
JSONObject
.
toJSONString
(
task
));
return
;
return
;
}
}
task
.
setStatus
(
DownloadTaskStatus
.
DOWNLOAD_HDFS
);
task
.
setDownloadWay
(-
1
);
task
.
setDownloadWay
(-
1
);
task
.
setFieldSize
(
condition
.
getAllFields
().
size
());
task
.
setFieldSize
(
condition
.
getAllFields
().
size
());
task
.
setDownloadTime
(
new
Date
());
//下载文件
//下载文件
String
dirName
=
"hdfs"
+
task
.
getId
();
String
dirName
=
"hdfs"
+
task
.
getId
();
String
path
=
HDFS_URL
+
"/"
+
dirName
;
String
path
=
HDFS_URL
+
"/"
+
dirName
;
...
...
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