Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
dinky
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
wangpeng
dinky
Commits
056604c7
Unverified
Commit
056604c7
authored
Mar 14, 2024
by
Zzm0809
Committed by
GitHub
Mar 14, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[HotFix] hotfix auto.sh (#3289)
parent
09e6257e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
4 deletions
+22
-4
auto.sh
script/bin/auto.sh
+22
-4
No files found.
script/bin/auto.sh
View file @
056604c7
...
@@ -2,10 +2,6 @@
...
@@ -2,10 +2,6 @@
FLINK_VERSION
=
${
2
}
FLINK_VERSION
=
${
2
}
if
[
-z
"
${
FLINK_VERSION
}
"
]
;
then
echo
"please specify the flink version, for example: sh auto.sh start 1.16"
exit
1
fi
APP_HOME
=
"
$(
cd
`
dirname
$0
`
;
pwd
)
"
APP_HOME
=
"
$(
cd
`
dirname
$0
`
;
pwd
)
"
...
@@ -14,6 +10,23 @@ EXTENDS_HOME="${APP_HOME}/extends"
...
@@ -14,6 +10,23 @@ EXTENDS_HOME="${APP_HOME}/extends"
JAR_NAME
=
"dinky-admin"
JAR_NAME
=
"dinky-admin"
if
[
-z
"
${
FLINK_VERSION
}
"
]
;
then
# Obtain the Flink version under EXTENDSHOME, only perform recognition and do not perform any other operations, for prompt purposes
FLINK_VERSION_SCAN
=
$(
ls
${
EXTENDS_HOME
}
|
grep
flink |
awk
-F
'flink'
'{print $2}'
)
# If FLINK_VERSION-SCAN is not empty, assign FLINK_VERSION-SCAN to FLINK_VERSION
if
[
-n
"
${
FLINK_VERSION_SCAN
}
"
]
;
then
FLINK_VERSION
=
${
FLINK_VERSION_SCAN
}
fi
fi
# Check whether the flink version is specified
assertIsInputVersion
()
{
# If FLINK_VERSION is still empty, prompt the user to enter the Flink version
if
[
-z
"
${
FLINK_VERSION
}
"
]
;
then
echo
"The flink version is not specified and the flink version cannot be found under the extends directory. Please specify the flink version."
exit
1
fi
}
# Use FLINK_HOME:
# Use FLINK_HOME:
CLASS_PATH
=
"
${
APP_HOME
}
:
${
APP_HOME
}
/lib/*:
${
APP_HOME
}
/config:
${
EXTENDS_HOME
}
/*:
${
EXTENDS_HOME
}
/flink
${
FLINK_VERSION
}
/dinky/*:
${
EXTENDS_HOME
}
/flink
${
FLINK_VERSION
}
/*"
CLASS_PATH
=
"
${
APP_HOME
}
:
${
APP_HOME
}
/lib/*:
${
APP_HOME
}
/config:
${
EXTENDS_HOME
}
/*:
${
EXTENDS_HOME
}
/flink
${
FLINK_VERSION
}
/dinky/*:
${
EXTENDS_HOME
}
/flink
${
FLINK_VERSION
}
/*"
...
@@ -51,6 +64,7 @@ updatePid() {
...
@@ -51,6 +64,7 @@ updatePid() {
}
}
start
()
{
start
()
{
assertIsInputVersion
updatePid
updatePid
if
[
-z
"
$pid
"
]
;
then
if
[
-z
"
$pid
"
]
;
then
nohup
java
-Ddruid
.mysql.usePingMethod
=
false
-Dlog4j2
.isThreadContextMapInheritable
=
true
-Xms512M
-Xmx2048M
-XX
:PermSize
=
512M
-XX
:MaxPermSize
=
1024M
-XX
:+HeapDumpOnOutOfMemoryError
-Xverify
:none
-cp
"
${
CLASS_PATH
}
"
org.dinky.Dinky
>
/dev/null 2>&1 &
nohup
java
-Ddruid
.mysql.usePingMethod
=
false
-Dlog4j2
.isThreadContextMapInheritable
=
true
-Xms512M
-Xmx2048M
-XX
:PermSize
=
512M
-XX
:MaxPermSize
=
1024M
-XX
:+HeapDumpOnOutOfMemoryError
-Xverify
:none
-cp
"
${
CLASS_PATH
}
"
org.dinky.Dinky
>
/dev/null 2>&1 &
...
@@ -63,6 +77,7 @@ start() {
...
@@ -63,6 +77,7 @@ start() {
}
}
startOnPending
()
{
startOnPending
()
{
assertIsInputVersion
updatePid
updatePid
if
[
-z
"
$pid
"
]
;
then
if
[
-z
"
$pid
"
]
;
then
java
-Ddruid
.mysql.usePingMethod
=
false
-Xms512M
-Xmx2048M
-XX
:PermSize
=
512M
-XX
:MaxPermSize
=
1024M
-XX
:+HeapDumpOnOutOfMemoryError
-Xverify
:none
-cp
"
${
CLASS_PATH
}
"
org.dinky.Dinky
java
-Ddruid
.mysql.usePingMethod
=
false
-Xms512M
-Xmx2048M
-XX
:PermSize
=
512M
-XX
:MaxPermSize
=
1024M
-XX
:+HeapDumpOnOutOfMemoryError
-Xverify
:none
-cp
"
${
CLASS_PATH
}
"
org.dinky.Dinky
...
@@ -73,6 +88,7 @@ startOnPending() {
...
@@ -73,6 +88,7 @@ startOnPending() {
}
}
startWithJmx
()
{
startWithJmx
()
{
assertIsInputVersion
updatePid
updatePid
if
[
-z
"
$pid
"
]
;
then
if
[
-z
"
$pid
"
]
;
then
nohup
java
-Ddruid
.mysql.usePingMethod
=
false
-Xms512M
-Xmx2048M
-XX
:PermSize
=
512M
-XX
:MaxPermSize
=
1024M
-XX
:+HeapDumpOnOutOfMemoryError
-Xverify
:none
"
${
JMX
}
"
-cp
"
${
CLASS_PATH
}
"
org.dinky.Dinky
>
/dev/null 2>&1 &
nohup
java
-Ddruid
.mysql.usePingMethod
=
false
-Xms512M
-Xmx2048M
-XX
:PermSize
=
512M
-XX
:MaxPermSize
=
1024M
-XX
:+HeapDumpOnOutOfMemoryError
-Xverify
:none
"
${
JMX
}
"
-cp
"
${
CLASS_PATH
}
"
org.dinky.Dinky
>
/dev/null 2>&1 &
...
@@ -114,6 +130,7 @@ status() {
...
@@ -114,6 +130,7 @@ status() {
restart
()
{
restart
()
{
echo
""
echo
""
assertIsInputVersion
stop
stop
start
start
echo
"........................................Restart Successfully........................................"
echo
"........................................Restart Successfully........................................"
...
@@ -121,6 +138,7 @@ restart() {
...
@@ -121,6 +138,7 @@ restart() {
restartWithJmx
()
{
restartWithJmx
()
{
echo
""
echo
""
assertIsInputVersion
stop
stop
startWithJmx
startWithJmx
echo
"........................................Restart with Jmx Successfully........................................"
echo
"........................................Restart with Jmx Successfully........................................"
...
...
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