Data Import with Check-ins Check-outs (Poppy)

Overview

This document contains the results of testing Check-in/Check-out and Data Import for MARC Bibliographic records in the Poppy release.

Ticket: PERF-697 - Getting issue details... STATUS

Summary

There is significant performance improvement for data import in Poppy comparing with Orchid. Durations are closer to Nolana release results. CI/CO response times improved 10% in average with all DI jobs. There's only CI response time degraded in 100k job with 17%.

Comparing Orchid and Poppy releases DI durations in create jobs are up to 10% higher with 5k file and 5% for bigger files with parallel Check-in/Check-out than pure Data import results. DI durations are higher up to 30% in update jobs.

Response times of CI/CO in Poppy release are twice higher with Data Import job with 100k compared with pure CI/CO.

DI create jobs with CI/CO for files 10k, 25k, 50k, 100k perform better in Poppy release and DI update jobs perform better with 25k, 50k, 100k with CI/CO.

No memory leaks are observed.

Average CPU utilization increased for mod-inventory up to 20% comparing with Orchid. So it did not exceed 150% for all the modules. The highest consumption observed from mod-inventory. The rest of services were almost on the same level in the same test in Orchid  Data Import with Check-ins Check-outs Orchid and didn't exceed 60%.

DB needs more connections (in average +20 more) needed for the same tests as in Orchid for all create and update jobs.

Average DB CPU usage is the same as in Orchid - 95%.

Upd: During previous tests on pcp1 and ocp3 there were problems with DI jobs running big files (Create jobs 100k and higher, Update jobs with 25k and higher). The problem was solved after new deployment and updates of 13 modules in scope of ticket  RANCHER-1121 - Getting issue details... STATUS and RANCHER-1114 - Getting issue details... STATUS and the large DI jobs are completing successfully now.


Test Runs 

Test #

Scenario

Load levelComment
1DI MARC Bib Create5K, 10K, 25K, 50K, 100K consequentially (with 5 min pause)
CICO 8 users
2DI MARC Bib Update5K, 10K, 25K, 50K, 100K consequentially (with 5 min pause)
CICO 8 users

Test Results

Data import

Total time for all Data Export jobs - 1 hour 16 minutes 47 seconds.

Profile
MARC File


DI Duration

Poppy (hh:mm:ss)

Check In, Check Out Response time (8 users)

Poppy

CI Average secCO Average sec
DI MARC Bib Create (PTF - Create 2)5K.mrc00:02:530.9011.375
10K.mrc00:04:320.9021.47
25K.mrc00:11:1411.571
50K.mrc00:21:550.9811.46
100K.mrc00:47:021.0181.491
Data Export MARC Bib (Export for Data Import updates)



5K.mrc00:02:090.4950.836
10K.mrc00:04:190.4680.917
25K.mrc00:10:300.4970.935
50K.mrc00:20:110.5090.923
100K.mrc00:39:38

DI MARC Bib Update (PTF - Updates Success - 1)5K.mrc00:03:190.7551.169
10K.mrc00:06:200.751.307
25K.mrc00:14:040.8221.403
50K.mrc00:29:590.8931.424
100K.mrc01:03:030.9081.51

Check-in/Check-out without DI

ScenarioLoad levelRequestResponse time, sec
Poppy
95 percaverage
Circulation Check-in/Check-out (without Data import)8 usersCheck-in0.4890.431
Check-out0.9690.828

Comparison

CICO with DI comparison

ProfileMARC FileDI DurationDeviation, % (compared DI Poppy without CICO and with CICO)DI Delta, (hh:mm:ss) Orchid/PoppyCheck In, Check Out Response time (8 users)Check In, Check Out Response time (8 users)Delta, %

without CI/COwith CI/COOrchidPoppyOrchid/PoppyOrchid/Poppy
Orchid*PoppyOrchid*PoppyCI Average secCO Average secCI Average secCO Average secCICO
DI MARC Bib Create (PTF - Create 2)5K.mrc00:04:3000:02:3900:05:0100:02:53+8.5% / 14 sec - 00:02:080.9611.4420.9011.375-6.24%-4.65%
10K.mrc00:09:2500:05:0000:09:0600:04:32-9.3% / 28 sec- 00:04:351.0581.6240.9021.47-14.74%-9.48%
25K.mrc00:22:1600:11:1500:24:2800:11:14-0.2% / 1 sec- 00:13:141.0561.62111.571-5.30%-3.08%
50K.mrc00:39:2700:22:1600:43:0300:21:55-1.5% / 21 sec- 00:21:090.9361.5190.9811.464.81%-3.88%
100K.mrc01:38:0000:49:5801:35:5000:47:02-5.8% / 2 min 56 sec- 00:48:490.8681.4681.0181.49117.28%1.57%
DI MARC Bib Update (PTF - Updates Success - 1)5K.mrc00:04:0200:02:2800:04:5200:03:19+34% / 51 sec- 00:01:330.8551.3390.7551.169-11.70%-12.70%
10K.mrc00:08:1000:05:3100:09:2200:06:20+15% / 49 sec- 00:03:030.9161.3980.751.307-18.12%-6.51%
25K.mrc00:19:3900:14:5000:24:0200:14:04-5.1% / 46 sec- 00:09:580.9221.4250.8221.403-10.85%-1.54%
50K.mrc00:38:3000:32:5300:47:1300:29:59-8.8% / 2 min 54 sec- 00:17:150.9041.4560.8931.424-1.22%-2.20%
100K.mrc01:33:0001:14:3901:40:2501:03:03-15.5% / 11 min 36 sec- 00:37:230.8381.4150.9081.518.35%6.71%

The following table compares test results of current release (Orchid) to the previous release numbers (Orchid) and to the baselines Poppy results (CICO without DI and DI without CICO).

* Orchid DI and CICO results are taken from Data Import with Check-ins Check-outs Orchid.

*** Completed with errors

Detailed CICO response time comparison

ScenarioLoad levelRequestResponse time, sec
Orchid
Response time, sec
Poppy
95 percaverage95 percaverage
Circulation Check-in/Check-out (without Data import)8 usersCheck-in0.4890.3940.4890.431
Check-out0.7930.7240.9690.828

Detailed CICO response time comparison for CICO with DI in Poppy

Request*Response time (avg, sec)
Pure CICOCICO + 100K MARC BIB CreateCICO + 100K MARC BIB Update
Check-Out Controller0.8281.4911.51
Check-In Controller0.4311.0180.908
POST_circulation/check-out-by-barcode (Submit_barcode_checkout)0.2660.6470.718
POST_circulation/check-in-by-barcode (Submit_barcode_checkin)0.1870.570.477
GET_circulation/loans (Submit_barcode_checkout)0.1280.2330.215
GET_inventory/items (Submit_barcode_checkin)0.0480.1260.118
GET_inventory/items (Submit_barcode_checkout)0.0460.1250.117
GET_note-links (Submit_barcode_checkout)0.0460.0240.024
GET_users (Submit_patron_barcode)0.0370.0410.037
GET_circulation/loans (Submit_patron_barcode)0.0280.030.049
GET_automated-patron-blocks (Submit_patron_barcode)0.0240.0260.024
GET_users (Get_check_in_page)0.0230.0540.051

*Top-10 requests were taken for analysis.

Response time

DI MARC BIB Create + CICO

DI Bib Update + CICO

Service CPU Utilization

Average CPU utilization did not exceed 150% for all the modules. The highest consumption observed from mod-inventory. That is 20% higher than in Orchid release. But the rest of services were almost on the same level in the same test in Orchid  Data Import with Check-ins Check-outs Orchid and didn't exceed 60%.

Spikes of  mod-data-import observed in Data Import jobs with 50k files up to 130%. for jobs  and 320% spike for 100k. For Data Import jobs with 5k, 10k, 25k files CPU utilization didn't exceed 35%

DI MARC BIB Create + CICO

DI MARC BIB Update+ CICO

Service Memory Utilization

There is memory utilization increasing observed which is caused by previous modules restarting (everyday cluster shut down process).

DI MARC BIB Create + CICO

It was observed that during tests mod-source-record-storage grew every 30 minutes with 10% from 38% up to 67% but it's still less than in the same test in Orchid. 

Memory consumption before tests for mod-search was 39% and for mod-inventory - 75%. During test with 100k file mod-search grew up to 75% and mod-inventory up to 91%.

MARC BIB Update + CICO

After 30 minutes of tests start mod-source-record-storage grew from 67% to 75% and didn't change during tests with 50k and 100k. So 75% of memory consumption can be defined as a baseline under load for this service. Mod-inventory grew from 91% to 99%.


DB CPU Utilization

Average DB CPU usage during data import is about 95% The same results if to compare with the same tests in Orchid.

DI MARC BIB Create + CICO

MARC BIB Update + CICO

DB Connections

Average connection count during data import is about 300 connections for create jobs that is 30 connections higher than in Orchid. For update jobs - 280 connections that is higher 

DI MARC BIB Create + CICO

MARC BIB Update + CICO

DB load

DI MARC BIB Create + CICO

Top SQL-queries:

INSERT INTO fs09000000_mod_source_record_manager.events_processed (handler_id, event_id) VALUES ($1, $2)

UPDATE fs09000000_mod_source_record_manager.job_execution_progress SET succeeded_records_count = succeeded_records_count + $2, error_records_count = error_records_count + $3 WHERE job_execution_id = $1 Returning *

INSERT INTO fs09000000_mod_source_record_manager.journal_records (id, job_execution_id, source_id, source_record_order, entity_type, entity_id, entity_hrid, action_type, action_status, error, action_date, title, instance_id, holdings_id, order_id, permanent_location_id, tenant_id) VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15, $16, $17)

MARC BIB Update + CICO

Top SQL-queries:

INSERT INTO fs09000000_mod_source_record_manager.events_processed (handler_id, event_id) VALUES ($1, $2)

INSERT INTO fs09000000_mod_source_record_manager.journal_records (id, job_execution_id, source_id, source_record_order, entity_type, entity_id, entity_hrid, action_type, action_status, error, action_date, title, instance_id, holdings_id, order_id, permanent_location_id, tenant_id) VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15, $16, $17)

insert into "marc_records_lb" ("id", "content") values (cast($1 as uuid), cast($2 as jsonb)) on conflict ("id") do update set "content" = cast($3 as jsonb)

Appendix

Infrastructure

PTF -environment pcp1

  • 10 m6i.2xlarge EC2 instances located in US East (N. Virginia)us-east-1
  • 2 database  instances, writer/reader

    NameMemory GIBvCPUsmax_connections

    db.r6g.xlarge

    32 GiB4 vCPUs2731
  • MSK tenant
    • 4 m5.2xlarge brokers in 2 zones
    • Apache Kafka version 2.8.0

    • EBS storage volume per broker 300 GiB

    • auto.create.topics.enable=true
    • log.retention.minutes=480
    • default.replication.factor=3


ModuleTask Def. RevisionModule VersionTask CountMem Hard LimitMem Soft limitCPU unitsXmxMetaspaceSizeMaxMetaspaceSizeR/W split enabled
pcp1-pvt

mod-remote-storage103.0.024920447210243960512512FALSE
mod-data-import183.0.71204818442561292384512FALSE
mod-authtoken132.14.121440115251292288128FALSE
mod-configuration95.9.22102489612876888128FALSE
mod-users-bl97.6.021440115251292288128FALSE
mod-inventory-storage1227.0.324096369020483076384512FALSE
mod-circulation-storage1217.1.322880259215361814384512FALSE
mod-source-record-storage155.7.325600500020483500384512FALSE
mod-inventory1120.1.322880259210241814384512FALSE
mod-di-converter-storage152.1.22102489612876888128FALSE
mod-circulation1224.0.822880259215361814384512FALSE
mod-pubsub112.11.22153614401024922384512FALSE
mod-patron-blocks91.9.021024896102476888128FALSE
mod-source-record-manager143.7.425600500020483500384512FALSE
mod-quick-marc95.0.01228821761281664384512FALSE
nginx-okapi92023.06.1421024896128000FALSE
okapi-b115.1.23168414401024922384512FALSE
mod-feesfines1019.0.02102489612876888128FALSE
pub-okapi92023.06.142102489612876800FALSE

Methodology/Approach

DI tests were started from UI with 5 min pauses between the tests.

Additional links

Grafana dashboard:

MARC Bib Create + CICO

http://carrier-io.int.folio.ebsco.com/grafana/d/SqzWB26nk/jmeter-performance-check-in-check-out?orgId=1&from=1700738030629&to=1700749313428&var-percentile=95&var-test_type=baseline&var-test=circulation_checkInCheckOut_Poppy_3&var-env=int&var-grouping=1s&var-low_limit=250&var-high_limit=750&var-db_name=jmeter&var-sampler_type=All

MARC Bib Update + CICO

http://carrier-io.int.folio.ebsco.com/grafana/d/SqzWB26nk/jmeter-performance-check-in-check-out?orgId=1&from=1700755239000&to=1700766759000&var-percentile=95&var-test_type=baseline&var-test=circulation_checkInCheckOut_Poppy_3&var-env=int&var-grouping=1s&var-low_limit=250&var-high_limit=750&var-db_name=jmeter&var-sampler_type=All