Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
byit-myth-job
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
liyuan
byit-myth-job
Commits
4d1d3d65
Commit
4d1d3d65
authored
Oct 22, 2020
by
huangfusuper
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
执行机占位异常BUG
parent
e43c5f3b
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
3 deletions
+1
-3
PlaceholderUtils.java
...on/src/main/java/com/byit/job/utils/PlaceholderUtils.java
+1
-3
No files found.
byit-myth-core/myth-core-common/src/main/java/com/byit/job/utils/PlaceholderUtils.java
View file @
4d1d3d65
...
...
@@ -50,11 +50,11 @@ public class PlaceholderUtils {
//寻找这个替换符 结束的位置
int
endIndex
=
sbt
.
indexOf
(
PLACEHOLDER_SUFFIX
,
startIndex
+
PLACEHOLDER_PREFIX
.
length
());
//确定是否存在后缀
int
nextIndex
=
0
;
if
(
endIndex
!=
-
1
){
//截取变量值
String
placeholder
=
sbt
.
substring
(
startIndex
+
PLACEHOLDER_PREFIX
.
length
(),
endIndex
);
//确定下一次查询的位置
int
nextIndex
;
//开始从 map中解析
if
(
parameter
.
containsKey
(
placeholder
)){
String
placeholderValue
=
parameter
.
get
(
placeholder
);
...
...
@@ -62,8 +62,6 @@ public class PlaceholderUtils {
sbt
.
replace
(
startIndex
,
endIndex
+
PLACEHOLDER_SUFFIX
.
length
(),
placeholderValue
);
//再次计算替换后的查询开始位置
nextIndex
=
startIndex
+
placeholderValue
.
length
();
}
else
{
throw
new
RuntimeException
(
"站位解析异常"
);
}
startIndex
=
sbt
.
indexOf
(
PLACEHOLDER_PREFIX
,
nextIndex
);
}
...
...
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