Closed Sachin-Mamoru closed 3 days ago
You can find a sample correlation log of IS 6.1.0 and IS 7.0.0-rc1-SNAPSHOT from the given links.
According to the log files there are 4 sets of call we need to focus on. Please refer the above mentioned files for more information.
Initial authorize call
IDN_AUTH_SESSION_STORE
instead of IDN_AUTH_TEMP_SESSION_STORE
.Set of network call related to Client App related data loading.
executeQuery|SELECT ID, NAME, DESCRIPTION FROM IDN_CONFIG_TYPE WHERE NAME = ? |jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT R.ID, R.TENANT_ID, R.NAME, R.CREATED_TIME, R.LAST_MODIFIED, R.HAS_FILE, R.HAS_ATTRIBUTE, T.NAME AS RESOURCE_TYPE, T.DESCRIPTION AS DESCRIPTION, F.ID AS FILE_ID, F.NAME AS FILE_NAME, A.ID AS ATTR_ID, A.ATTR_KEY AS ATTR_KEY, A.ATTR_VALUE AS ATTR_VALUE FROM IDN_CONFIG_RESOURCE AS R INNER JOIN IDN_CONFIG_TYPE AS T ON R.TYPE_ID = T.ID LEFT JOIN IDN_CONFIG_ATTRIBUTE AS A ON ( R.HAS_ATTRIBUTE = TRUE AND A.RESOURCE_ID = R.ID ) LEFT JOIN IDN_CONFIG_FILE AS F ON ( R.HAS_FILE = TRUE AND F.RESOURCE_ID = R.ID )WHERE R.NAME = ? AND R.TENANT_ID = ? AND R.TYPE_ID = ?|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT ID, NAME, DESCRIPTION FROM IDN_CONFIG_TYPE WHERE NAME = ? |jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT R.ID, R.TENANT_ID, R.NAME, R.CREATED_TIME, R.LAST_MODIFIED, R.HAS_FILE, R.HAS_ATTRIBUTE, T.NAME AS RESOURCE_TYPE, T.DESCRIPTION AS DESCRIPTION, F.ID AS FILE_ID, F.NAME AS FILE_NAME, A.ID AS ATTR_ID, A.ATTR_KEY AS ATTR_KEY, A.ATTR_VALUE AS ATTR_VALUE FROM IDN_CONFIG_RESOURCE AS R INNER JOIN IDN_CONFIG_TYPE AS T ON R.TYPE_ID = T.ID LEFT JOIN IDN_CONFIG_ATTRIBUTE AS A ON ( R.HAS_ATTRIBUTE = TRUE AND A.RESOURCE_ID = R.ID ) LEFT JOIN IDN_CONFIG_FILE AS F ON ( R.HAS_FILE = TRUE AND F.RESOURCE_ID = R.ID )WHERE R.NAME = ? AND R.TENANT_ID = ? AND R.TYPE_ID = ?|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT ID, NAME, DESCRIPTION FROM IDN_CONFIG_TYPE WHERE NAME = ? |jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT R.ID, R.TENANT_ID, R.NAME, R.CREATED_TIME, R.LAST_MODIFIED, R.HAS_FILE, R.HAS_ATTRIBUTE, T.NAME AS RESOURCE_TYPE, T.DESCRIPTION AS DESCRIPTION, F.ID AS FILE_ID, F.NAME AS FILE_NAME, A.ID AS ATTR_ID, A.ATTR_KEY AS ATTR_KEY, A.ATTR_VALUE AS ATTR_VALUE FROM IDN_CONFIG_RESOURCE AS R INNER JOIN IDN_CONFIG_TYPE AS T ON R.TYPE_ID = T.ID LEFT JOIN IDN_CONFIG_ATTRIBUTE AS A ON ( R.HAS_ATTRIBUTE = TRUE AND A.RESOURCE_ID = R.ID ) LEFT JOIN IDN_CONFIG_FILE AS F ON ( R.HAS_FILE = TRUE AND F.RESOURCE_ID = R.ID ) WHERE R.NAME = ? AND R.TENANT_ID = ? AND R.TYPE_ID = ?|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT COUNT(SP_APP.APP_NAME) FROM SP_APP LEFT JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE SP_APP.TENANT_ID = ? AND SP_APP.APP_NAME != ? AND (SP_APP.APP_NAME = ?)|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT SP_APP.ID, SP_APP.APP_NAME, SP_APP.DESCRIPTION, SP_APP.UUID, SP_APP.IMAGE_URL, SP_APP.ACCESS_URL, SP_INBOUND_AUTH.INBOUND_AUTH_KEY, SP_INBOUND_AUTH.INBOUND_AUTH_TYPE, SP_APP.USERNAME, SP_APP.USER_STORE, SP_APP.TENANT_ID FROM SP_APP LEFT JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE SP_APP.TENANT_ID = ? AND SP_APP.APP_NAME != ? AND (SP_APP.APP_NAME = ?) ORDER BY SP_APP.ID DESC LIMIT ?, ?|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT ID, NAME, DESCRIPTION FROM IDN_CONFIG_TYPE WHERE NAME = ? |jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT R.ID, R.TENANT_ID, R.NAME, R.CREATED_TIME, R.LAST_MODIFIED, R.HAS_FILE, R.HAS_ATTRIBUTE, T.NAME AS RESOURCE_TYPE, T.DESCRIPTION AS DESCRIPTION, F.ID AS FILE_ID, F.NAME AS FILE_NAME, A.ID AS ATTR_ID, A.ATTR_KEY AS ATTR_KEY, A.ATTR_VALUE AS ATTR_VALUE FROM IDN_CONFIG_RESOURCE AS R INNER JOIN IDN_CONFIG_TYPE AS T ON R.TYPE_ID = T.ID LEFT JOIN IDN_CONFIG_ATTRIBUTE AS A ON ( R.HAS_ATTRIBUTE = TRUE AND A.RESOURCE_ID = R.ID ) LEFT JOIN IDN_CONFIG_FILE AS F ON ( R.HAS_FILE = TRUE AND F.RESOURCE_ID = R.ID ) WHERE R.NAME = ? AND R.TENANT_ID = ? AND R.TYPE_ID = ?|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT COUNT(SP_APP.APP_NAME) FROM SP_APP LEFT JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE SP_APP.TENANT_ID = ? AND SP_APP.APP_NAME != ? AND (SP_APP.APP_NAME = ?)|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT SP_APP.ID, SP_APP.APP_NAME, SP_APP.DESCRIPTION, SP_APP.UUID, SP_APP.IMAGE_URL, SP_APP.ACCESS_URL, SP_INBOUND_AUTH.INBOUND_AUTH_KEY, SP_INBOUND_AUTH.INBOUND_AUTH_TYPE, SP_APP.USERNAME, SP_APP.USER_STORE, SP_APP.TENANT_ID FROM SP_APP LEFT JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE SP_APP.TENANT_ID = ? AND SP_APP.APP_NAME != ? AND (SP_APP.APP_NAME = ?) ORDER BY SP_APP.ID DESC LIMIT ?, ?|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT COUNT(SP_APP.APP_NAME) FROM SP_APP LEFT JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE SP_APP.TENANT_ID = ? AND SP_APP.APP_NAME != ? AND (SP_APP.APP_NAME = ?)|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT SP_APP.ID, SP_APP.APP_NAME, SP_APP.DESCRIPTION, SP_APP.UUID, SP_APP.IMAGE_URL, SP_APP.ACCESS_URL, SP_INBOUND_AUTH.INBOUND_AUTH_KEY, SP_INBOUND_AUTH.INBOUND_AUTH_TYPE, SP_APP.USERNAME, SP_APP.USER_STORE, SP_APP.TENANT_ID FROM SP_APP LEFT JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE SP_APP.TENANT_ID = ? AND SP_APP.APP_NAME != ? AND (SP_APP.APP_NAME = ?) ORDER BY SP_APP.ID DESC LIMIT ?, ?|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT ID, NAME, DESCRIPTION FROM IDN_CONFIG_TYPE WHERE NAME = ? |jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT R.ID, R.TENANT_ID, R.NAME, R.CREATED_TIME, R.LAST_MODIFIED, R.HAS_FILE, R.HAS_ATTRIBUTE, T.NAME AS RESOURCE_TYPE, T.DESCRIPTION AS DESCRIPTION, F.ID AS FILE_ID, F.NAME AS FILE_NAME, A.ID AS ATTR_ID, A.ATTR_KEY AS ATTR_KEY, A.ATTR_VALUE AS ATTR_VALUE FROM IDN_CONFIG_RESOURCE AS R INNER JOIN IDN_CONFIG_TYPE AS T ON R.TYPE_ID = T.ID LEFT JOIN IDN_CONFIG_ATTRIBUTE AS A ON ( R.HAS_ATTRIBUTE = TRUE AND A.RESOURCE_ID = R.ID ) LEFT JOIN IDN_CONFIG_FILE AS F ON ( R.HAS_FILE = TRUE AND F.RESOURCE_ID = R.ID ) WHERE R.NAME = ? AND R.TENANT_ID = ? AND R.TYPE_ID = ?|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT ID, NAME, DESCRIPTION FROM IDN_CONFIG_TYPE WHERE NAME = ? |jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT R.ID, R.TENANT_ID, R.NAME, R.CREATED_TIME, R.LAST_MODIFIED, R.HAS_FILE, R.HAS_ATTRIBUTE, T.NAME AS RESOURCE_TYPE, T.DESCRIPTION AS DESCRIPTION, F.ID AS FILE_ID, F.NAME AS FILE_NAME, A.ID AS ATTR_ID, A.ATTR_KEY AS ATTR_KEY, A.ATTR_VALUE AS ATTR_VALUE FROM IDN_CONFIG_RESOURCE AS R INNER JOIN IDN_CONFIG_TYPE AS T ON R.TYPE_ID = T.ID LEFT JOIN IDN_CONFIG_ATTRIBUTE AS A ON ( R.HAS_ATTRIBUTE = TRUE AND A.RESOURCE_ID = R.ID ) LEFT JOIN IDN_CONFIG_FILE AS F ON ( R.HAS_FILE = TRUE AND F.RESOURCE_ID = R.ID ) WHERE R.NAME = ? AND R.TENANT_ID = ? AND R.TYPE_ID = ?|jdbc:h2:./repository/database/WSO2IDENTITY_DB
Below are the queries used by IS 6.1.0
executeQuery|SELECT COUNT(SP_APP.APP_NAME) FROM SP_APP LEFT JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE SP_APP.TENANT_ID = ? AND SP_APP.APP_NAME != ? AND (SP_APP.APP_NAME = ?)|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT SP_APP.ID, SP_APP.APP_NAME, SP_APP.DESCRIPTION, SP_APP.UUID, SP_APP.IMAGE_URL, SP_APP.ACCESS_URL, SP_INBOUND_AUTH.INBOUND_AUTH_KEY, SP_INBOUND_AUTH.INBOUND_AUTH_TYPE, SP_APP.USERNAME, SP_APP.USER_STORE, SP_APP.TENANT_ID FROM SP_APP LEFT JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE SP_APP.TENANT_ID = ? AND SP_APP.APP_NAME != ? AND (SP_APP.APP_NAME = ?) ORDER BY SP_APP.ID DESC LIMIT ?, ?|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT COUNT(SP_APP.APP_NAME) FROM SP_APP LEFT JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE SP_APP.TENANT_ID = ? AND SP_APP.APP_NAME != ? AND (SP_APP.APP_NAME = ?)|jdbc:h2:./repository/database/WSO2IDENTITY_DB
executeQuery|SELECT SP_APP.ID, SP_APP.APP_NAME, SP_APP.DESCRIPTION, SP_APP.UUID, SP_APP.IMAGE_URL, SP_APP.ACCESS_URL, SP_INBOUND_AUTH.INBOUND_AUTH_KEY, SP_INBOUND_AUTH.INBOUND_AUTH_TYPE, SP_APP.USERNAME, SP_APP.USER_STORE, SP_APP.TENANT_ID FROM SP_APP LEFT JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE SP_APP.TENANT_ID = ? AND SP_APP.APP_NAME != ? AND (SP_APP.APP_NAME = ?) ORDER BY SP_APP.ID DESC LIMIT ?, ?|jdbc:h2:./repository/database/WSO2IDENTITY_DB
commonauth call
Authorize redirect call
executeQuery|SELECT OPERATION, SESSION_OBJECT, TIME_CREATED FROM IDN_AUTH_SESSION_STORE WHERE SESSION_ID =? AND SESSION_TYPE=? ORDER BY TIME_CREATED DESC LIMIT 1|jdbc:mysql://localhost:3306/reg_db_5?useSSL=false
executeUpdate|INSERT INTO IDN_AUTH_SESSION_STORE(SESSION_ID, SESSION_TYPE,OPERATION, TIME_CREATED, EXPIRY_TIME) VALUES (?,?,?,?,?)|jdbc:mysql://localhost:3306/reg_db_5?useSSL=false
[x] Skip tenant resolving logic for super tenant user.
[x] Skip Role Based Scope Issuer scope validation by default as this is a feature used by the APIM product when the IS is acting as the key manager.
Initial authorize call
[session_data.session_data_persist.session_and_temp_data_separation_enabled]
config was disabled by default.
Set of network call related to Client App related data loading. (UI related)
/api/server/v1/branding-preference/resolve
.
commonauth call
Authorize redirect call
latest changes added
The following changes were done to the IS 7.0.0 alpha-SNAPSHOT before the test.
session and temp data separation enabled
in legacy modeAdded the below config in the deployment.toml
file to enable the config.
[session_data.session_data_persist.session_and_temp_data_separation_enabled]
enable=true
The below analysis done to the code grant flow authorize call.
To verify this, increased the maximum db pool count by 10 in IS 7.0.0, performance increased.
Increased pool size
Scope validation removed and event listers removed cases showed the so far best results. Hence ran a test on the both cases combined.
SELECT APP_NAME FROM SP_APP INNER JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE INBOUND_AUTH_KEY = 'consumerKey_192' AND INBOUND_AUTH_TYPE = 'oauth2' AND SP_APP.TENANT_ID = -1234 AND SP_INBOUND_AUTH.TENANT_ID=-1234;
Threads on awaiting notification
and timed awaiting notification
states has increased in is7.
On average,
176 -> 212
25 -> 42
awaiting notification
is7
https-jsse-nio-9443-exec-xxx
type of threads. is6
pool-xx-thread-xx
Threads are mostly blocked at tomcat level in is7.
timed awaiting notification
Concurrency - 300 Average response time of the fastest API call - ~340ms Slow query threshold - 100ms
IS 7.0.0 - Query | Average Duration (s) | Frequency |
---|---|---|
INSERT INTO IDN_AUTH_SESSION_META_DATA... | 0.12 | 35 |
INSERT INTO IDN_AUTH_SESSION_APP_INFO... | 0.28 | 32 |
INSERT INTO IDN_OAUTH2_TOKEN_BINDING... | 0.13 | 31 |
INSERT INTO IDN_OAUTH2_ACCESS_TOKEN_SCOPE... | 0.13 | 11 |
SELECT TOKEN_ID FROM IDN_OAUTH2_ACCESS_TOKEN... | 0.12 | 6 |
SELECT OPERATION, SESSION_OBJECT, TIME_CREATED FROM IDN_AUTH_TEMP_SESSION_STORE... | 0.23 | 3 |
SELECT UM_ROLE_NAME FROM UM_USER_ROLE, UM_ROLE, UM_USER... | 0.16 | 5 |
IS 6.1.0 - Query | Average Duration (s) | Frequency |
---|---|---|
INSERT INTO IDN_AUTH_SESSION_META_DATA... | 0.12 | 25 |
With the increase of the concurrency, the heavy queries such as listed above are getting slow.
Query | Any changes |
---|---|
IDN_AUTH_SESSION_META_DATA | None |
IDN_AUTH_SESSION_APP_INFO | None |
IDN_OAUTH2_TOKEN_BINDING | None |
IDN_OAUTH2_ACCESS_TOKEN_SCOPE | TOKEN_SCOPE field size increased from 60 -> 255 |
IDN_OAUTH2_ACCESS_TOKEN | New field AUTHORIZED_ORGANIZATION VARCHAR(36) DEFAULT 'NONE' NOT NULL , Con app key constraint updated with the new field, new index added CREATE INDEX IDX_TBR_TS ON IDN_OAUTH2_ACCESS_TOKEN(TOKEN_BINDING_REF, TOKEN_STATE) |
IDN_AUTH_TEMP_SESSION_STORE | None |
Send Consent Approve Request
When doing the performance degradation analysis we used oauth code grant flow. The flow has the below 5 API calls.
4. Send Consent Approve Request
Sample Correlation log DB calls of IS 7.0.0-beta4:
|executeQuery|SELECT OPERATION, SESSION_OBJECT, TIME_CREATED FROM IDN_AUTH_TEMP_SESSION_STORE WHERE SESSION_ID =? AND SESSION_TYPE=? ORDER BY TIME_CREATED DESC LIMIT 1|jdbc:mysql://localhost:3306/reg_db_t_2?useSSL=false
|executeUpdate|INSERT INTO IDN_AUTH_TEMP_SESSION_STORE(SESSION_ID, SESSION_TYPE,OPERATION, TIME_CREATED, EXPIRY_TIME) VALUES (?,?,?,?,?)|jdbc:mysql://localhost:3306/reg_db_t_2?useSSL=false
|execute|INSERT INTO IDN_OAUTH2_AUTHORIZATION_CODE (CODE_ID, AUTHORIZATION_CODE, CONSUMER_KEY_ID, CALLBACK_URL, SCOPE, AUTHZ_USER, USER_DOMAIN, TENANT_ID, TIME_CREATED, VALIDITY_PERIOD, SUBJECT_IDENTIFIER, PKCE_CODE_CHALLENGE, PKCE_CODE_CHALLENGE_METHOD, AUTHORIZATION_CODE_HASH, IDP_ID) SELECT ?,?,IDN_OAUTH_CONSUMER_APPS.ID,?,?,?,?,?,?,?,?,?,?,?,IDP.ID FROM IDN_OAUTH_CONSUMER_APPS, IDP WHERE CONSUMER_KEY=? AND IDP.NAME=? AND IDP.TENANT_ID=? AND IDN_OAUTH_CONSUMER_APPS.TENANT_ID=?|jdbc:mysql://localhost:3306/reg_db_t_2?useSSL=false
|executeBatch|INSERT INTO IDN_OAUTH2_AUTHZ_CODE_SCOPE (CODE_ID, SCOPE, TENANT_ID) VALUES (?,?,?)|jdbc:mysql://localhost:3306/reg_db_t_2?useSSL=false
|executeUpdate|INSERT INTO IDN_AUTH_SESSION_STORE(SESSION_ID, SESSION_TYPE, OPERATION, SESSION_OBJECT, TIME_CREATED, EXPIRY_TIME, TENANT_ID) VALUES (?,?,?,?,?,?,?)|jdbc:mysql://localhost:3306/reg_db_t_2?useSSL=false
|executeUpdate|INSERT INTO IDN_AUTH_SESSION_STORE(SESSION_ID, SESSION_TYPE, OPERATION, SESSION_OBJECT, TIME_CREATED, EXPIRY_TIME, TENANT_ID) VALUES (?,?,?,?,?,?,?)|jdbc:mysql://localhost:3306/reg_db_t_2?useSSL=false
Sample Correlation log DB calls of IS 6.1.0:
|executeUpdate|DELETE FROM IDN_AUTH_TEMP_SESSION_STORE WHERE SESSION_ID = ? AND SESSION_TYPE = ?|jdbc:mysql://localhost:3306/reg_db_2?useSSL=false
|execute|INSERT INTO IDN_OAUTH2_AUTHORIZATION_CODE (CODE_ID, AUTHORIZATION_CODE, CONSUMER_KEY_ID, CALLBACK_URL, SCOPE, AUTHZ_USER, USER_DOMAIN, TENANT_ID, TIME_CREATED, VALIDITY_PERIOD, SUBJECT_IDENTIFIER, PKCE_CODE_CHALLENGE, PKCE_CODE_CHALLENGE_METHOD, AUTHORIZATION_CODE_HASH, IDP_ID) SELECT ?,?,IDN_OAUTH_CONSUMER_APPS.ID,?,?,?,?,?,?,?,?,?,?,?,IDP.ID FROM IDN_OAUTH_CONSUMER_APPS, IDP WHERE CONSUMER_KEY=? AND IDP.NAME=? AND IDP.TENANT_ID=?|jdbc:mysql://localhost:3306/reg_db_2?useSSL=false
|executeBatch|INSERT INTO IDN_OAUTH2_AUTHZ_CODE_SCOPE (CODE_ID, SCOPE, TENANT_ID) VALUES (?,?,?)|jdbc:mysql://localhost:3306/reg_db_2?useSSL=false
|executeUpdate|INSERT INTO IDN_AUTH_SESSION_STORE(SESSION_ID, SESSION_TYPE, OPERATION, SESSION_OBJECT, TIME_CREATED, EXPIRY_TIME, TENANT_ID) VALUES (?,?,?,?,?,?,?)|jdbc:mysql://localhost:3306/reg_db_2?useSSL=false
|executeUpdate|INSERT INTO IDN_AUTH_SESSION_STORE(SESSION_ID, SESSION_TYPE, OPERATION, SESSION_OBJECT, TIME_CREATED, EXPIRY_TIME, TENANT_ID) VALUES (?,?,?,?,?,?,?)|jdbc:mysql://localhost:3306/reg_db_2?useSSL=false
The query
|executeUpdate|DELETE FROM IDN_AUTH_TEMP_SESSION_STORE WHERE SESSION_ID = ? AND SESSION_TYPE = ?|jdbc:mysql://localhost:3306/reg_db_2?useSSL=false
has been replaced with
|executeQuery|SELECT OPERATION, SESSION_OBJECT, TIME_CREATED FROM IDN_AUTH_TEMP_SESSION_STORE WHERE SESSION_ID =? AND SESSION_TYPE=? ORDER BY TIME_CREATED DESC LIMIT 1|jdbc:mysql://localhost:3306/reg_db_t_2?useSSL=false
|executeUpdate|INSERT INTO IDN_AUTH_TEMP_SESSION_STORE(SESSION_ID, SESSION_TYPE,OPERATION, TIME_CREATED, EXPIRY_TIME) VALUES (?,?,?,?,?)|jdbc:mysql://localhost:3306/reg_db_t_2?useSSL=false
Instead of deleting the temp session data record, the record has been marked as deleted and in a separate session data cleaner, these records are being removed. By the time of perf test execution this clean up task is not happening causing the DB to contain huge number of temp session data records.
https://github.com/wso2/carbon-identity-framework/pull/5362
[session_data.cleanup]
enable_expired_data_cleanup = true
clean_logged_out_sessions_at_immediate_cycle = true
enable_pre_session_data_cleanup = true
Post Authentication Authorize call
|executeQuery|SELECT CONSENTED_SCOPES.SCOPE, CONSENTED_SCOPES.CONSENT FROM IDN_OAUTH2_USER_CONSENT USER_CONSENT, IDN_OAUTH2_USER_CONSENTED_SCOPES CONSENTED_SCOPES WHERE USER_CONSENT.USER_ID = ? AND USER_CONSENT.APP_ID = ? AND USER_CONSENT.TENANT_ID = ? AND USER_CONSENT.CONSENT_ID = CONSENTED_SCOPES.CONSENT_ID
|executeUpdate|INSERT INTO IDN_AUTH_TEMP_SESSION_STORE(SESSION_ID, SESSION_TYPE, OPERATION, SESSION_OBJECT, TIME_CREATED, EXPIRY_TIME, TENANT_ID) VALUES (?,?,?,?,?,?,?)
|executeQuery|SELECT UUID FROM SP_APP INNER JOIN SP_INBOUND_AUTH ON SP_APP.ID = SP_INBOUND_AUTH.APP_ID WHERE INBOUND_AUTH_KEY = ? AND INBOUND_AUTH_TYPE = ? AND SP_APP.TENANT_ID = ? AND SP_INBOUND_AUTH.TENANT_ID=?|jdbc:mysql://localhost:3306/reg_db_1?useSSL=false
|executeQuery|SELECT FILTEREDSCOPES.NAME, FILTEREDSCOPES.DISPLAY_NAME, FILTEREDSCOPES.DESCRIPTION, IDN_CLAIM.CLAIM_URI FROM (SELECT * FROM IDN_OAUTH2_SCOPE WHERE IDN_OAUTH2_SCOPE.TENANT_ID=? AND IDN_OAUTH2_SCOPE.SCOPE_TYPE=?) FILTEREDSCOPES LEFT JOIN IDN_OIDC_SCOPE_CLAIM_MAPPING ON IDN_OIDC_SCOPE_CLAIM_MAPPING.SCOPE_ID = FILTEREDSCOPES.SCOPE_ID LEFT JOIN IDN_CLAIM ON IDN_CLAIM.ID = IDN_OIDC_SCOPE_CLAIM_MAPPING.EXTERNAL_CLAIM_ID LEFT JOIN IDN_CLAIM_DIALECT ON IDN_CLAIM_DIALECT.ID = IDN_CLAIM.DIALECT_ID WHERE FILTEREDSCOPES.TENANT_ID = ? AND (IDN_CLAIM_DIALECT.TENANT_ID = ? AND IDN_CLAIM_DIALECT.DIALECT_URI = ?) OR (IDN_CLAIM_DIALECT.DIALECT_URI IS NULL AND IDN_CLAIM_DIALECT.TENANT_ID IS NULL)|jdbc:mysql://localhost:3306/reg_db_1?useSSL=false
|executeQuery|SELECT MAIN_APP_ID FROM SP_SHARED_APP WHERE SHARED_APP_ID = ?|jdbc:mysql://localhost:3306/reg_db_1?useSSL=false
|executeQuery|SELECT POLICY_ID, SCOPE_NAME FROM AUTHORIZED_API JOIN AUTHORIZED_SCOPE ON AUTHORIZED_API.APP_ID = AUTHORIZED_SCOPE.APP_ID AND AUTHORIZED_API.API_ID = AUTHORIZED_SCOPE.API_ID WHERE AUTHORIZED_API.APP_ID = ?|jdbc:mysql://localhost:3306/reg_db_1?useSSL=false
|executeQuery|SELECT ID, NAME, DISPLAY_NAME, DESCRIPTION, API_ID, TENANT_ID FROM SCOPE WHERE TENANT_ID = ?|jdbc:mysql://localhost:3306/reg_db_1?useSSL=false
|executeQuery|SELECT CONSENTED_SCOPES.SCOPE, CONSENTED_SCOPES.CONSENT FROM IDN_OAUTH2_USER_CONSENT USER_CONSENT, IDN_OAUTH2_USER_CONSENTED_SCOPES CONSENTED_SCOPES WHERE USER_CONSENT.USER_ID = ? AND USER_CONSENT.APP_ID = ? AND USER_CONSENT.TENANT_ID = ? AND USER_CONSENT.CONSENT_ID = CONSENTED_SCOPES.CONSENT_ID|jdbc:mysql://localhost:3306/reg_db_1?useSSL=false
|executeUpdate|INSERT INTO IDN_AUTH_TEMP_SESSION_STORE(SESSION_ID, SESSION_TYPE, OPERATION, SESSION_OBJECT, TIME_CREATED, EXPIRY_TIME, TENANT_ID) VALUES (?,?,?,?,?,?,?)|jdbc:mysql://localhost:3306/reg_db_1?useSSL=false
Perf analysis for https://github.com/wso2-extensions/identity-inbound-auth-oauth/pull/2324
Perf analysis for https://github.com/wso2/carbon-identity-framework/pull/5404
This issue is being closed due to extended inactivity. Please feel free to reopen it if further attention is needed. Thank you for helping us keep the issue list relevant and focused!
Describe the issue:
Testing the following scenarios with Single Node 4 Core and 2 Core, Two Node 4 Core and 2 Core
Publish performance test results in new representation for the selected flows.