diff --git a/deploy/crds/kieapp.crd.yaml b/deploy/crds/kieapp.crd.yaml index c364d941f..3d679161a 100644 --- a/deploy/crds/kieapp.crd.yaml +++ b/deploy/crds/kieapp.crd.yaml @@ -1628,8 +1628,13 @@ spec: description: KieServerSet KIE Server configuration for a single set, or for multiple sets if deployments is set to >1 properties: - MDBMaxSession: - description: MDBMaxSession number of KIE Executor sessions + KieExecutorMDBMaxSession: + description: 'KieExecutorMDBMaxSession number of max KIE + Executor sessions, it must be lower than the value of + max-pool-size, by default is max-pool-size set to 60. + Max pool size can be set by system property jboss.mdb.strict.max.pool.size + (using javaOptsAppend: "-Djboss.mdb.strict.max.pool.size=40"), + for more information see https://access.redhat.com/solutions/2955481.' type: integer build: description: KieAppBuildObject Data to define how to build @@ -4501,8 +4506,14 @@ spec: single set, or for multiple sets if deployments is set to >1 properties: - MDBMaxSession: - description: MDBMaxSession number of KIE Executor sessions + KieExecutorMDBMaxSession: + description: 'KieExecutorMDBMaxSession number of max + KIE Executor sessions, it must be lower than the value + of max-pool-size, by default is max-pool-size set + to 60. Max pool size can be set by system property + jboss.mdb.strict.max.pool.size (using javaOptsAppend: + "-Djboss.mdb.strict.max.pool.size=40"), for more information + see https://access.redhat.com/solutions/2955481.' type: integer build: description: KieAppBuildObject Data to define how to diff --git a/deploy/olm-catalog/dev/7.12.1-1/manifests/kieapp.crd.yaml b/deploy/olm-catalog/dev/7.12.1-1/manifests/kieapp.crd.yaml index c364d941f..3d679161a 100644 --- a/deploy/olm-catalog/dev/7.12.1-1/manifests/kieapp.crd.yaml +++ b/deploy/olm-catalog/dev/7.12.1-1/manifests/kieapp.crd.yaml @@ -1628,8 +1628,13 @@ spec: description: KieServerSet KIE Server configuration for a single set, or for multiple sets if deployments is set to >1 properties: - MDBMaxSession: - description: MDBMaxSession number of KIE Executor sessions + KieExecutorMDBMaxSession: + description: 'KieExecutorMDBMaxSession number of max KIE + Executor sessions, it must be lower than the value of + max-pool-size, by default is max-pool-size set to 60. + Max pool size can be set by system property jboss.mdb.strict.max.pool.size + (using javaOptsAppend: "-Djboss.mdb.strict.max.pool.size=40"), + for more information see https://access.redhat.com/solutions/2955481.' type: integer build: description: KieAppBuildObject Data to define how to build @@ -4501,8 +4506,14 @@ spec: single set, or for multiple sets if deployments is set to >1 properties: - MDBMaxSession: - description: MDBMaxSession number of KIE Executor sessions + KieExecutorMDBMaxSession: + description: 'KieExecutorMDBMaxSession number of max + KIE Executor sessions, it must be lower than the value + of max-pool-size, by default is max-pool-size set + to 60. Max pool size can be set by system property + jboss.mdb.strict.max.pool.size (using javaOptsAppend: + "-Djboss.mdb.strict.max.pool.size=40"), for more information + see https://access.redhat.com/solutions/2955481.' type: integer build: description: KieAppBuildObject Data to define how to diff --git a/deploy/olm-catalog/prod/7.12.1-1/manifests/kieapp.crd.yaml b/deploy/olm-catalog/prod/7.12.1-1/manifests/kieapp.crd.yaml index c364d941f..3d679161a 100644 --- a/deploy/olm-catalog/prod/7.12.1-1/manifests/kieapp.crd.yaml +++ b/deploy/olm-catalog/prod/7.12.1-1/manifests/kieapp.crd.yaml @@ -1628,8 +1628,13 @@ spec: description: KieServerSet KIE Server configuration for a single set, or for multiple sets if deployments is set to >1 properties: - MDBMaxSession: - description: MDBMaxSession number of KIE Executor sessions + KieExecutorMDBMaxSession: + description: 'KieExecutorMDBMaxSession number of max KIE + Executor sessions, it must be lower than the value of + max-pool-size, by default is max-pool-size set to 60. + Max pool size can be set by system property jboss.mdb.strict.max.pool.size + (using javaOptsAppend: "-Djboss.mdb.strict.max.pool.size=40"), + for more information see https://access.redhat.com/solutions/2955481.' type: integer build: description: KieAppBuildObject Data to define how to build @@ -4501,8 +4506,14 @@ spec: single set, or for multiple sets if deployments is set to >1 properties: - MDBMaxSession: - description: MDBMaxSession number of KIE Executor sessions + KieExecutorMDBMaxSession: + description: 'KieExecutorMDBMaxSession number of max + KIE Executor sessions, it must be lower than the value + of max-pool-size, by default is max-pool-size set + to 60. Max pool size can be set by system property + jboss.mdb.strict.max.pool.size (using javaOptsAppend: + "-Djboss.mdb.strict.max.pool.size=40"), for more information + see https://access.redhat.com/solutions/2955481.' type: integer build: description: KieAppBuildObject Data to define how to diff --git a/deploy/olm-catalog/test/7.12.1-1/manifests/kieapp.crd.yaml b/deploy/olm-catalog/test/7.12.1-1/manifests/kieapp.crd.yaml index c364d941f..3d679161a 100644 --- a/deploy/olm-catalog/test/7.12.1-1/manifests/kieapp.crd.yaml +++ b/deploy/olm-catalog/test/7.12.1-1/manifests/kieapp.crd.yaml @@ -1628,8 +1628,13 @@ spec: description: KieServerSet KIE Server configuration for a single set, or for multiple sets if deployments is set to >1 properties: - MDBMaxSession: - description: MDBMaxSession number of KIE Executor sessions + KieExecutorMDBMaxSession: + description: 'KieExecutorMDBMaxSession number of max KIE + Executor sessions, it must be lower than the value of + max-pool-size, by default is max-pool-size set to 60. + Max pool size can be set by system property jboss.mdb.strict.max.pool.size + (using javaOptsAppend: "-Djboss.mdb.strict.max.pool.size=40"), + for more information see https://access.redhat.com/solutions/2955481.' type: integer build: description: KieAppBuildObject Data to define how to build @@ -4501,8 +4506,14 @@ spec: single set, or for multiple sets if deployments is set to >1 properties: - MDBMaxSession: - description: MDBMaxSession number of KIE Executor sessions + KieExecutorMDBMaxSession: + description: 'KieExecutorMDBMaxSession number of max + KIE Executor sessions, it must be lower than the value + of max-pool-size, by default is max-pool-size set + to 60. Max pool size can be set by system property + jboss.mdb.strict.max.pool.size (using javaOptsAppend: + "-Djboss.mdb.strict.max.pool.size=40"), for more information + see https://access.redhat.com/solutions/2955481.' type: integer build: description: KieAppBuildObject Data to define how to diff --git a/deploy/ui/form.json b/deploy/ui/form.json index a9d318baa..1e37ab951 100644 --- a/deploy/ui/form.json +++ b/deploy/ui/form.json @@ -1724,7 +1724,7 @@ "label": "Configure KieExecutorMDB threads", "type": "object", "max": 1, - "jsonPath": "$.spec.objects.servers[*].MDBMaxSession", + "jsonPath": "$.spec.objects.servers[*].KieExecutorMDBMaxSession", "visible": true, "fields": [ { @@ -1732,8 +1732,8 @@ "type": "integer", "required": false, "jsonPath": "$.spec.objects.servers[*].MDBMaxSession", - "originalJsonPath": "$.spec.objects.servers[*].MDBMaxSession", - "description": "Number of max session used by the JMS Executor." + "originalJsonPath": "$.spec.objects.servers[*].KieExecutorMDBMaxSession", + "description": "Number of max session used by the JMS Executor, it must be lower than the value of max-pool-size passed as jboss.mdb.strict.max.pool.size, if leaved empty the max.pool.size will be set to 60." } ] }, diff --git a/pkg/apis/app/v2/kieapp_types.go b/pkg/apis/app/v2/kieapp_types.go index d0fa80730..9352ba958 100644 --- a/pkg/apis/app/v2/kieapp_types.go +++ b/pkg/apis/app/v2/kieapp_types.go @@ -151,8 +151,8 @@ type KieServerSet struct { Kafka *KafkaExtObject `json:"kafka,omitempty"` KafkaJbpmEventEmitters *KafkaJBPMEventEmittersObject `json:"kafkaJbpmEventEmitters,omitempty"` Cors *CORSFiltersObject `json:"cors,omitempty"` - // MDBMaxSession number of KIE Executor sessions - MDBMaxSession *int `json:"MDBMaxSession,omitempty"` + // KieExecutorMDBMaxSession number of max KIE Executor sessions, it must be lower than the value of max-pool-size, by default is max-pool-size set to 60. Max pool size can be set by system property jboss.mdb.strict.max.pool.size (using javaOptsAppend: "-Djboss.mdb.strict.max.pool.size=40"), for more information see https://access.redhat.com/solutions/2955481. + KieExecutorMDBMaxSession *int `json:"KieExecutorMDBMaxSession,omitempty"` } // ConsoleObject configuration of the RHPAM workbench @@ -768,8 +768,8 @@ type ServerTemplate struct { KafkaJbpmEventEmitters *KafkaJBPMEventEmittersObject `json:"kafkaJbpmEventEmitters,omitempty"` Cors *CORSFiltersObject `json:"cors,omitempty"` StartupStrategy *StartupStrategy `json:"startupStrategy,omitempty"` - // MDBMaxSession number of KIE Executor sessions - MDBMaxSession *int `json:"MDBMaxSession,omitempty"` + // KieExecutorMDBMaxSession number of KIE Executor sessions + KieExecutorMDBMaxSession *int `json:"KieExecutorMDBMaxSession,omitempty"` } // DashbuilderTemplate contains all the variables used in the yaml templates diff --git a/pkg/apis/app/v2/zz_generated.deepcopy.go b/pkg/apis/app/v2/zz_generated.deepcopy.go index 9e77697a9..9816705b4 100644 --- a/pkg/apis/app/v2/zz_generated.deepcopy.go +++ b/pkg/apis/app/v2/zz_generated.deepcopy.go @@ -1279,8 +1279,8 @@ func (in *KieServerSet) DeepCopyInto(out *KieServerSet) { *out = new(CORSFiltersObject) (*in).DeepCopyInto(*out) } - if in.MDBMaxSession != nil { - in, out := &in.MDBMaxSession, &out.MDBMaxSession + if in.KieExecutorMDBMaxSession != nil { + in, out := &in.KieExecutorMDBMaxSession, &out.KieExecutorMDBMaxSession *out = new(int) **out = **in } @@ -1551,8 +1551,8 @@ func (in *ServerTemplate) DeepCopyInto(out *ServerTemplate) { *out = new(StartupStrategy) (*in).DeepCopyInto(*out) } - if in.MDBMaxSession != nil { - in, out := &in.MDBMaxSession, &out.MDBMaxSession + if in.KieExecutorMDBMaxSession != nil { + in, out := &in.KieExecutorMDBMaxSession, &out.KieExecutorMDBMaxSession *out = new(int) **out = **in } diff --git a/pkg/controller/kieapp/defaults/defaults.go b/pkg/controller/kieapp/defaults/defaults.go index b8705569f..b313d307c 100644 --- a/pkg/controller/kieapp/defaults/defaults.go +++ b/pkg/controller/kieapp/defaults/defaults.go @@ -761,17 +761,17 @@ func getServersConfig(cr *api.KieApp) ([]api.ServerTemplate, error) { } usedNames[name] = true template := api.ServerTemplate{ - KieName: name, - KieServerID: name, - Build: getBuildConfig(product, cr, serverSet), - KeystoreSecret: serverSet.KeystoreSecret, - StorageClassName: serverSet.StorageClassName, - JbpmCluster: serverSet.JbpmCluster, - PersistRepos: serverSet.PersistRepos, - ServersM2PvSize: serverSet.ServersM2PvSize, - ServersKiePvSize: serverSet.ServersKiePvSize, - StartupStrategy: cr.Status.Applied.CommonConfig.StartupStrategy, - MDBMaxSession: serverSet.MDBMaxSession, + KieName: name, + KieServerID: name, + Build: getBuildConfig(product, cr, serverSet), + KeystoreSecret: serverSet.KeystoreSecret, + StorageClassName: serverSet.StorageClassName, + JbpmCluster: serverSet.JbpmCluster, + PersistRepos: serverSet.PersistRepos, + ServersM2PvSize: serverSet.ServersM2PvSize, + ServersKiePvSize: serverSet.ServersKiePvSize, + StartupStrategy: cr.Status.Applied.CommonConfig.StartupStrategy, + KieExecutorMDBMaxSession: serverSet.KieExecutorMDBMaxSession, } if cr.Status.Applied.Objects.Console == nil || cr.Status.Applied.Environment == api.RhdmProductionImmutable { @@ -864,8 +864,8 @@ func getServersConfig(cr *api.KieApp) ([]api.ServerTemplate, error) { } // KieExecutorMDB - if serverSet.MDBMaxSession != nil { - template.MDBMaxSession = serverSet.MDBMaxSession + if serverSet.KieExecutorMDBMaxSession != nil { + template.KieExecutorMDBMaxSession = serverSet.KieExecutorMDBMaxSession } if cr.Status.Applied.CommonConfig.StartupStrategy.StrategyName != "" { diff --git a/pkg/controller/kieapp/defaults/defaults_test.go b/pkg/controller/kieapp/defaults/defaults_test.go index f27a9eafd..5b23ed068 100644 --- a/pkg/controller/kieapp/defaults/defaults_test.go +++ b/pkg/controller/kieapp/defaults/defaults_test.go @@ -7267,7 +7267,7 @@ func TestKieExecutorMDB(t *testing.T) { Environment: api.RhpamProductionImmutable, Objects: api.KieAppObjects{ Servers: []api.KieServerSet{ - {MDBMaxSession: Pint(40)}, + {KieExecutorMDBMaxSession: Pint(40)}, }, }, }, @@ -7276,11 +7276,11 @@ func TestKieExecutorMDB(t *testing.T) { env, err := GetEnvironment(cr, test.MockService()) assert.Nil(t, err, "Error getting TestKieExecutorMDB environment") - assert.NotNil(t, cr.Status.Applied.Objects.Servers[0].MDBMaxSession) + assert.NotNil(t, cr.Status.Applied.Objects.Servers[0].KieExecutorMDBMaxSession) mdbMaxSessionPassed := false for _, env := range env.Servers[0].DeploymentConfigs[0].Spec.Template.Spec.Containers[0].Env { - if strings.HasPrefix(env.Name, "JBOSS_MDB") { - if env.Name != "JBOSS_MDB_MAX_SESSION" && env.Value == "40" { + if strings.HasPrefix(env.Name, "JBOSS_KIE_EXECUTOR_MDB") { + if env.Name == "JBOSS_KIE_EXECUTOR_MDB_MAX_SESSIONS" && env.Value == "40" { mdbMaxSessionPassed = true } } @@ -7302,7 +7302,7 @@ func TestKieExecutorMDBEmpty(t *testing.T) { env, err := GetEnvironment(cr, test.MockService()) assert.Nil(t, err, "Error getting TestKieExecutorMDBEmpty environment") - assert.Nil(t, cr.Status.Applied.Objects.Servers[0].MDBMaxSession) + assert.Nil(t, cr.Status.Applied.Objects.Servers[0].KieExecutorMDBMaxSession) mdbMaxSessionNotPassed := true for _, env := range env.Servers[0].DeploymentConfigs[0].Spec.Template.Spec.Containers[0].Env { if strings.HasPrefix(env.Name, "JBOSS_MDB") { diff --git a/rhpam-config/7.12.1/common.yaml b/rhpam-config/7.12.1/common.yaml index 0d72ff8c8..83ef62195 100644 --- a/rhpam-config/7.12.1/common.yaml +++ b/rhpam-config/7.12.1/common.yaml @@ -1099,9 +1099,9 @@ servers: #[[end]] #[[end]] ## CORS END - #[[if .MDBMaxSession]] - - name: JBOSS_MDB_MAX_SESSIONS - value: "[[.MDBMaxSession]]" + #[[if .KieExecutorMDBMaxSession]] + - name: JBOSS_KIE_EXECUTOR_MDB_MAX_SESSIONS + value: "[[.KieExecutorMDBMaxSession]]" #[[end]] livenessProbe: httpGet: