-
Notifications
You must be signed in to change notification settings - Fork 263
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix a bug of branchGraph cache with test_case
- Loading branch information
lvcangquan.lcq
committed
Apr 25, 2022
1 parent
9c87a39
commit 5b717f8
Showing
21 changed files
with
409 additions
and
2 deletions.
There are no files selected for viewing
Submodule bash-buddy
updated
10 files
+4 −1 | .editorconfig | |
+0 −104 | README.md | |
+1 −1 | bin/.editorconfig | |
+14 −14 | bin/gen_source_guard | |
+54 −194 | lib/common_utils.sh | |
+71 −96 | lib/java_build_utils.sh | |
+177 −316 | lib/prepare_jdks.sh | |
+59 −87 | lib/trap_error_info.sh | |
+0 −87 | templates/appveyor.template.yml | |
+18 −19 | templates/integration_test_template.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/InputCheckOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
public class InputCheckOp { | ||
public InputCheckOp() { | ||
} | ||
|
||
public Boolean process(Integer input) { | ||
Integer compareNumber = 20; | ||
if (input > compareNumber) { | ||
return false; | ||
} else { | ||
return true; | ||
} | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
...test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/OnlinePreProcessOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
public class OnlinePreProcessOp { | ||
public OnlinePreProcessOp() { | ||
} | ||
|
||
public Integer process(Integer sqrtResult) { | ||
Integer addNumber = 2; | ||
Integer onlineInput = sqrtResult + addNumber; | ||
return onlineInput; | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/OnlineSolveOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
public class OnlineSolveOp { | ||
public OnlineSolveOp() { | ||
} | ||
|
||
public Integer process(Integer onlineInput) { | ||
Integer addNumber = 2; | ||
Integer onlineResult = onlineInput + addNumber; | ||
return onlineResult; | ||
} | ||
} |
15 changes: 15 additions & 0 deletions
15
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/PreProcessOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
import java.math.BigInteger; | ||
|
||
public class PreProcessOp { | ||
public PreProcessOp() { | ||
} | ||
|
||
public void process(Integer input) { | ||
int compareNumber = 10; | ||
if (input < compareNumber) { | ||
System.out.println("input is smaller than 10"); | ||
} | ||
} | ||
} |
10 changes: 10 additions & 0 deletions
10
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/RandomOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
public class RandomOp { | ||
public RandomOp() { | ||
} | ||
|
||
public void process(Integer result) { | ||
System.out.println("Random process is finished " + result); | ||
} | ||
} |
14 changes: 14 additions & 0 deletions
14
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/ResultCheckOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
public class ResultCheckOp { | ||
public ResultCheckOp() { | ||
} | ||
|
||
public Boolean process(Integer result) { | ||
Integer compareNumber = 10; | ||
if (result < compareNumber) { | ||
return true; | ||
} | ||
return false; | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
...est/java/com/allibaba/compileflow/test/om/branch_graph/calculate/ResultPostProcessOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
public class ResultPostProcessOp { | ||
public ResultPostProcessOp() { | ||
} | ||
|
||
public Integer process(Integer result) { | ||
Integer addNumber = 10; | ||
Integer finalResult = result + addNumber; | ||
return finalResult; | ||
} | ||
} |
11 changes: 11 additions & 0 deletions
11
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/ScaleOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
public class ScaleOp { | ||
public ScaleOp() { | ||
} | ||
|
||
public void process(Integer input) { | ||
System.out.printf("%d enter proportion process", input); | ||
} | ||
|
||
} |
16 changes: 16 additions & 0 deletions
16
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/SqrtProcessOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
public class SqrtProcessOp { | ||
public SqrtProcessOp() { | ||
} | ||
|
||
public Integer process(Integer input) { | ||
try { | ||
double sqrtResult = Math.sqrt(input); | ||
return (int)sqrtResult; | ||
} catch (Exception e) { | ||
System.out.println("SqrtProcessOp is failed"); | ||
return 0; | ||
} | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/TypeCheckOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
import com.allibaba.compileflow.test.om.branch_graph.common.TypeInfo; | ||
import com.allibaba.compileflow.test.om.branch_graph.common.TypeEnum; | ||
|
||
public class TypeCheckOp { | ||
public TypeCheckOp() { | ||
} | ||
|
||
public TypeEnum process(TypeInfo typeInfo) { | ||
return typeInfo.getCalculateType(); | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/TypeOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
import com.allibaba.compileflow.test.om.branch_graph.common.TypeInfo; | ||
import com.allibaba.compileflow.test.om.branch_graph.common.TypeEnum; | ||
|
||
public class TypeOp { | ||
public TypeOp() { | ||
} | ||
|
||
public TypeEnum process(TypeInfo typeInfo) { | ||
return typeInfo.getCalculateType(); | ||
} | ||
} |
23 changes: 23 additions & 0 deletions
23
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/TypeProcessOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
import com.allibaba.compileflow.test.om.branch_graph.common.TypeInfo; | ||
import com.allibaba.compileflow.test.om.branch_graph.common.TypeEnum; | ||
|
||
public class TypeProcessOp { | ||
public TypeProcessOp() { | ||
} | ||
|
||
public TypeInfo process(Integer sqrtResult) { | ||
Integer compareNumber1 = 5; | ||
Integer compareNumber2 = 100; | ||
TypeInfo typeInfo = new TypeInfo(); | ||
if (sqrtResult < compareNumber1) { | ||
typeInfo.setCalculateType(TypeEnum.ONLINE_SOLVE); | ||
} else if (sqrtResult > compareNumber2) { | ||
typeInfo.setCalculateType(TypeEnum.OFFLINE_SOLVE); | ||
} else { | ||
typeInfo.setCalculateType(TypeEnum.SCALE_SOLVE); | ||
} | ||
return typeInfo; | ||
} | ||
} |
14 changes: 14 additions & 0 deletions
14
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/TypeReadOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
import com.allibaba.compileflow.test.om.branch_graph.common.TypeEnum; | ||
|
||
public class TypeReadOp { | ||
public TypeReadOp() { | ||
} | ||
|
||
public void process(TypeEnum type) { | ||
if (type == TypeEnum.ONLINE_SOLVE || type == TypeEnum.OFFLINE_SOLVE) { | ||
System.out.println("TypeReadOp is processed"); | ||
} | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
...est/java/com/allibaba/compileflow/test/om/branch_graph/calculate/offlinePreProcessOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
public class offlinePreProcessOp { | ||
public offlinePreProcessOp() { | ||
} | ||
|
||
public Integer process(Integer sqrtResult) { | ||
Integer addNumber = 100; | ||
Integer rayInput = sqrtResult + addNumber; | ||
return rayInput; | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
src/test/java/com/allibaba/compileflow/test/om/branch_graph/calculate/offlineSolveOp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.calculate; | ||
|
||
public class offlineSolveOp { | ||
public offlineSolveOp() { | ||
} | ||
|
||
public Integer process(Integer offlineInput) { | ||
Integer addNumber = 200; | ||
Integer rayResult = offlineInput + addNumber; | ||
return rayResult; | ||
} | ||
} |
10 changes: 10 additions & 0 deletions
10
src/test/java/com/allibaba/compileflow/test/om/branch_graph/common/TypeEnum.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.common; | ||
|
||
public enum TypeEnum { | ||
SCALE_SOLVE, | ||
ONLINE_SOLVE, | ||
OFFLINE_SOLVE; | ||
|
||
private TypeEnum() { | ||
} | ||
} |
18 changes: 18 additions & 0 deletions
18
src/test/java/com/allibaba/compileflow/test/om/branch_graph/common/TypeInfo.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package com.allibaba.compileflow.test.om.branch_graph.common; | ||
|
||
import com.allibaba.compileflow.test.om.branch_graph.common.TypeEnum; | ||
|
||
public class TypeInfo { | ||
private TypeEnum calculateType; | ||
|
||
public TypeInfo() { | ||
} | ||
|
||
public void setCalculateType(TypeEnum type) { | ||
calculateType = type; | ||
} | ||
|
||
public TypeEnum getCalculateType() { | ||
return calculateType; | ||
} | ||
} |
Oops, something went wrong.