Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
ebulk
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
ebulk
Commits
3e8f03c5
Commit
3e8f03c5
authored
Jul 12, 2019
by
Roque
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Error message removed for no-error scenarios
parent
b6c537b3
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
2 deletions
+12
-2
ebulk
ebulk
+4
-1
ebulk-data/embulk-wendelin-dataset-tool/lib/embulk/filelogger.rb
...ata/embulk-wendelin-dataset-tool/lib/embulk/filelogger.rb
+8
-1
No files found.
ebulk
View file @
3e8f03c5
...
...
@@ -10,6 +10,7 @@ DATASET_REPORT_FILE_NAME="/.dataset-task-report"
DATASET_COMPLETE_FILE_NAME
=
"/.dataset-completed"
DISCARD_CHANGES_FILE_NAME
=
"/.discard-changes"
LOG_DIR
=
"
$EBULK_DATA_PATH
/logs"
STATUS_FILE
=
"
$EBULK_DATA_PATH
/.status"
CREDENTIALS_FILE
=
"
$EBULK_DATA_PATH
/.credentials"
CONFIG_FILE
=
"
$EBULK_DATA_PATH
/.config"
DESCRIPTION_DATASET_PATH_PREFIX
=
"
$EBULK_DATA_PATH
/.dataset-description"
...
...
@@ -300,6 +301,7 @@ function runProcess {
fi
$embulk
run
-I
$TOOL_PATH
/embulk-wendelin-dataset-tool/lib
$FILE
$DIFF_COMMAND
2>
"
$LOG_DIR
/error.log"
||
{
if
[
"
$STATUS
"
==
\"\"
]
;
then
if
[
!
-f
$STATUS_FILE
]
;
then
if
[
"
$DATASET_DESCRIPTION
"
==
""
]
;
then
echo
echo
-e
"
${
ORANGE
}
[ERROR] Embulk tool stopped its execution.
${
NC
}
"
...
...
@@ -310,13 +312,14 @@ function runProcess {
echo
"[INFO] Please check the logs in '
$LOG_DIR
' directory for more details."
echo
fi
fi
fi
}
}
function
javaNotInstalled
{
echo
-e
"
${
ORANGE
}
[ERROR] java 8 must be installed. Please, install java 8 and try again.
${
NC
}
"
echo
"[INFO] You can download the installation package for your operative system clicking on the Download button on https://java.com/en/"
echo
"[INFO] You can download the installation package for your operative system clicking on the Download button on https://java.com/en/"
echo
"[INFO] Please follow the instructions to install java 8 here https://java.com/en/download/help/download_options.xml"
echo
}
...
...
ebulk-data/embulk-wendelin-dataset-tool/lib/embulk/filelogger.rb
View file @
3e8f03c5
...
...
@@ -7,15 +7,20 @@ class LogManager
INFO
=
"INFO"
ERROR
=
"ERROR"
WARN
=
"WARNING"
STATUS_FILE
=
".status"
def
initialize
()
now
=
Time
.
now
.
strftime
(
"%d-%m-%Y"
)
@filename
=
"
#{
now
.
to_s
}
.log"
@user
@password
@status_file
=
"./"
File
.
delete
(
@status_file
+
STATUS_FILE
)
if
File
.
exist?
(
@status_file
+
STATUS_FILE
)
end
def
setFilename
(
tool_dir
,
prefix
)
@status_file
=
tool_dir
+
"/"
File
.
delete
(
@status_file
+
STATUS_FILE
)
if
File
.
exist?
(
@status_file
+
STATUS_FILE
)
log_dir
=
"
#{
tool_dir
}
/logs/"
if
not
File
.
directory?
(
log_dir
)
Dir
.
mkdir
log_dir
...
...
@@ -55,9 +60,11 @@ class LogManager
puts
unless
@path
.
nil?
puts
"PROCESS ABORTED : For more detailed information, please refer to the log file '
#{
@path
}
'"
exec
(
"Process.kill 9, Process.pid >/dev/null 2>&1"
)
end
end
exec
(
"Process.kill 9, Process.pid >/dev/null 2>&1"
)
File
.
open
(
@status_file
+
STATUS_FILE
,
'w'
)
exit!
end
def
logOutOfMemoryError
(
reference
)
...
...
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