-
Notifications
You must be signed in to change notification settings - Fork 157
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Reduce the default min heap size and remove the default max heap size
For historical reasons we were setting the initial heap size to the same value as the max heap size: 4GiB. However, based on experimentation, our memory pool usage is only around 512MB for a lightly used ingestion workload. The cost dynamics of cloud make it more important to set an appropriate initial heap size and memory management in the JVM has gotten better over time. As for the max heap size, OpenJ9 has intelligent defaults when running within a container, and so we should use those instead of guessing at a default of our own: https://www.eclipse.org/openj9/docs/xxusecontainersupport Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
- Loading branch information
Showing
11 changed files
with
167 additions
and
157 deletions.
There are no files selected for viewing
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
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
65 changes: 65 additions & 0 deletions
65
fhir-persistence-schema/src/main/resources/db2/delete_resource_parameters.sql
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,65 @@ | ||
------------------------------------------------------------------------------- | ||
-- (C) Copyright IBM Corp. 2021 | ||
-- | ||
-- SPDX-License-Identifier: Apache-2.0 | ||
------------------------------------------------------------------------------- | ||
|
||
-- ---------------------------------------------------------------------------- | ||
-- Procedure to delete all the search parameters associated with a resource | ||
-- | ||
-- p_logical_resource_id: the id representing the resource for which to delete the parameters | ||
-- ---------------------------------------------------------------------------- | ||
( IN p_resource_type VARCHAR( 36 OCTETS), | ||
IN p_logical_resource_id BIGINT) | ||
LANGUAGE SQL | ||
MODIFIES SQL DATA | ||
BEGIN | ||
-- Declare the variables | ||
DECLARE v_schema_name VARCHAR(128 OCTETS) DEFAULT '{{SCHEMA_NAME}}'; | ||
DECLARE d_stmt STATEMENT; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || p_resource_type || '_str_values WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || p_resource_type || '_number_values WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || p_resource_type || '_date_values WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || p_resource_type || '_latlng_values WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || p_resource_type || '_resource_token_refs WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || p_resource_type || '_quantity_values WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || p_resource_type || '_profiles WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || p_resource_type || '_tags WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || p_resource_type || '_security WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || 'str_values WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || 'date_values WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || 'resource_token_refs WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || 'logical_resource_profiles WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || 'logical_resource_tags WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
|
||
PREPARE d_stmt FROM 'DELETE FROM {{SCHEMA_NAME}}.' || 'logical_resource_security WHERE logical_resource_id = ?'; | ||
EXECUTE d_stmt USING p_logical_resource_id; | ||
END |
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
Oops, something went wrong.