Skip to content

Commit

Permalink
Убрал флаг installExtensionsByDefault
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanovEV committed Jan 19, 2024
1 parent f67a04f commit 328f1c0
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 12 deletions.
1 change: 0 additions & 1 deletion resources/globalConfiguration.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
"initMethod": "fromStorage",
"runMigration": true,
"additionalInitializationSteps": [],
"installExtensionsByDefault": true,
"extensions": []
},
"bdd": {
Expand Down
4 changes: 0 additions & 4 deletions resources/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -165,10 +165,6 @@
"type": "string"
}
},
"installExtensionsByDefault": {
"type": "boolean",
"description": "Устанавливать расширения из папки исходников по умолчанию.\n По умолчанию содержит значение \"true\"."
},
"extensions": {
"type": "array",
"description": "Массив расширений для загрузки в конфигурацию.",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ class InitInfoBaseOptions implements Serializable {
""")
String[] additionalInitializationSteps

@JsonPropertyDescription("Устанавливать расширения из папки исходников по умолчанию")
Boolean installExtensionsByDefault = true

@JsonPropertyDescription("Массив расширений для загрузки в конфигурацию.")
Extension[] extensions;

Expand Down Expand Up @@ -59,7 +56,6 @@ class InitInfoBaseOptions implements Serializable {
"initMethod=" + initMethod +
", runMigration=" + runMigration +
", additionalInitializationSteps=" + additionalInitializationSteps +
", installExtensionsByDefault=" + installExtensionsByDefault +
", extensions=" + extensions +
'}';
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,14 @@ class JobConfiguration implements Serializable {
(initMethod == InitInfoBaseMethod.DEFAULT_BRANCH_FROM_STORAGE && branchName != defaultBranch)
}

boolean needLoadExtensions() {
IStepExecutor steps = ContextRegistry.getContext().getStepExecutor()
def env = steps.env();
String branchName = env.BRANCH_NAME;
def extensions = initInfoBaseOptions.extensions

return extensions.length != 0
}

String v8AgentLabel() {
return v8version
Expand Down
10 changes: 7 additions & 3 deletions vars/pipeline1C.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,9 @@ void call() {

stages {
stage('Сборка из исходников'){
when {
expression { config.needLoadExtensions() }
}
steps {
timeout(time: config.timeoutOptions.getBinaries, unit: TimeUnit.MINUTES) {
createDir('build/out/cfe')
Expand All @@ -86,9 +89,6 @@ void call() {
}
}
stage('Создание ИБ') {
// when {
// beforeAgent true
// }
steps {
timeout(time: config.timeoutOptions.createInfoBase, unit: TimeUnit.MINUTES) {
createDir('build/out/')
Expand Down Expand Up @@ -120,6 +120,10 @@ void call() {
}

stage('Загрузка расширений в конфигурацию'){
when {
beforeAgent true
expression { config.needLoadExtensions() }
}
steps {
timeout(time: config.timeoutOptions.loadExtensions, unit: TimeUnit.MINUTES) {
loadExtensions config
Expand Down

0 comments on commit 328f1c0

Please sign in to comment.