AWS Security ChangesHomeSearch

AWS code-library documentation change

Service: code-library · 2025-03-23 · Documentation low

File: code-library/latest/ug/sap-abap_1_sagemaker_code_examples.md

Summary

Updated ABAP code examples to use newer object instantiation syntax (NEW operator instead of CREATE OBJECT)

Security assessment

Changes are purely syntactic improvements to ABAP code samples (modernizing object creation syntax). No security-related parameters, configurations, or warnings were added/modified.

Diff

diff --git a/code-library/latest/ug/sap-abap_1_sagemaker_code_examples.md b/code-library/latest/ug/sap-abap_1_sagemaker_code_examples.md
index 6e9ce00b7..2c85e0526 100644
--- a/code-library/latest/ug/sap-abap_1_sagemaker_code_examples.md
+++ b/code-library/latest/ug/sap-abap_1_sagemaker_code_examples.md
@@ -44,3 +44 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_production_variants
-          EXPORTING
-            iv_variantname          = iv_variant_name
+        lo_production_variants = NEW #( iv_variantname = iv_variant_name
@@ -49 +47 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-            iv_instancetype         = iv_instance_type.
+                                        iv_instancetype = iv_instance_type ).
@@ -57,2 +55 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-              it_productionvariants = lt_production_variants
-            ).
+              it_productionvariants = lt_production_variants ).
@@ -68,2 +65 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-                iv_endpointname = iv_endpoint_name
-            ).
+                iv_endpointname = iv_endpoint_name ).
@@ -96,4 +92,2 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_primarycontainer
-          EXPORTING
-            iv_image        = iv_container_image
-            iv_modeldataurl = iv_model_data_url.
+        lo_primarycontainer = NEW #( iv_image = iv_container_image
+                                     iv_modeldataurl = iv_model_data_url ).
@@ -106,2 +100 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-              io_primarycontainer = lo_primarycontainer
-            ).
+              io_primarycontainer = lo_primarycontainer ).
@@ -146 +139 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_hyperparameters_w EXPORTING iv_value = iv_hp_max_depth.
+        lo_hyperparameters_w = NEW #( iv_value = iv_hp_max_depth ).
@@ -149 +142 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_hyperparameters_w EXPORTING iv_value = iv_hp_eta.
+        lo_hyperparameters_w = NEW #( iv_value = iv_hp_eta ).
@@ -152 +145 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_hyperparameters_w EXPORTING iv_value = iv_hp_eval_metric.
+        lo_hyperparameters_w = NEW #( iv_value = iv_hp_eval_metric ).
@@ -155 +148 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_hyperparameters_w EXPORTING iv_value = iv_hp_scale_pos_weight.
+        lo_hyperparameters_w = NEW #( iv_value = iv_hp_scale_pos_weight ).
@@ -158 +151 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_hyperparameters_w EXPORTING iv_value = iv_hp_subsample.
+        lo_hyperparameters_w = NEW #( iv_value = iv_hp_subsample ).
@@ -161 +154 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_hyperparameters_w EXPORTING iv_value = iv_hp_objective.
+        lo_hyperparameters_w = NEW #( iv_value = iv_hp_objective ).
@@ -164 +157 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_hyperparameters_w EXPORTING iv_value = iv_hp_num_round.
+        lo_hyperparameters_w = NEW #( iv_value = iv_hp_num_round ).
@@ -168,3 +161 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_trn_s3datasource
-          EXPORTING
-            iv_s3datatype             = iv_trn_data_s3datatype
+        lo_trn_s3datasource = NEW #( iv_s3datatype = iv_trn_data_s3datatype
@@ -172 +163 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-            iv_s3uri                  = iv_trn_data_s3uri.
+                                     iv_s3uri = iv_trn_data_s3uri ).
@@ -174,3 +165 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_trn_datasource
-          EXPORTING
-            io_s3datasource = lo_trn_s3datasource.
+        lo_trn_datasource = NEW #( io_s3datasource = lo_trn_s3datasource ).
@@ -178,3 +167 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_trn_channel
-          EXPORTING
-            iv_channelname     = 'train'
+        lo_trn_channel = NEW #( iv_channelname = 'train'
@@ -183 +170 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-            iv_contenttype     = iv_trn_data_contenttype.
+                                iv_contenttype = iv_trn_data_contenttype ).
@@ -188,3 +175 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_val_s3datasource
-          EXPORTING
-            iv_s3datatype             = iv_val_data_s3datatype
+        lo_val_s3datasource = NEW #( iv_s3datatype = iv_val_data_s3datatype
@@ -192 +177 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-            iv_s3uri                  = iv_val_data_s3uri.
+                                     iv_s3uri = iv_val_data_s3uri ).
@@ -194,3 +179 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_val_datasource
-          EXPORTING
-            io_s3datasource = lo_val_s3datasource.
+        lo_val_datasource = NEW #( io_s3datasource = lo_val_s3datasource ).
@@ -198,3 +181 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_val_channel
-          EXPORTING
-            iv_channelname     = 'validation'
+        lo_val_channel = NEW #( iv_channelname = 'validation'
@@ -203 +184 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-            iv_contenttype     = iv_val_data_contenttype.
+                                iv_contenttype = iv_val_data_contenttype ).
@@ -208,4 +189,2 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_algorithm_specification
-          EXPORTING
-            iv_trainingimage     = iv_training_image
-            iv_traininginputmode = iv_training_input_mode.
+        lo_algorithm_specification = NEW #( iv_trainingimage = iv_training_image
+                                            iv_traininginputmode = iv_training_input_mode ).
@@ -214,3 +193 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_resource_config
-          EXPORTING
-            iv_instancecount  = iv_instance_count
+        lo_resource_config = NEW #( iv_instancecount = iv_instance_count
@@ -218 +195 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-            iv_volumesizeingb = iv_volume_sizeingb.
+                                    iv_volumesizeingb = iv_volume_sizeingb ).
@@ -221,3 +198 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_output_data_config
-          EXPORTING
-            iv_s3outputpath = iv_s3_output_path.
+        lo_output_data_config = NEW #( iv_s3outputpath = iv_s3_output_path ).
@@ -226,3 +201 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_stopping_condition
-          EXPORTING
-            iv_maxruntimeinseconds = iv_max_runtime_in_seconds.
+        lo_stopping_condition = NEW #( iv_maxruntimeinseconds = iv_max_runtime_in_seconds ).
@@ -240,2 +213 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-              io_stoppingcondition         = lo_stopping_condition
-            ).
+              io_stoppingcondition         = lo_stopping_condition ).
@@ -275,4 +247,2 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_s3datasource
-          EXPORTING
-            iv_s3uri      = iv_tf_data_s3uri
-            iv_s3datatype = iv_tf_data_s3datatype.
+        lo_s3datasource = NEW #( iv_s3uri = iv_tf_data_s3uri
+                                 iv_s3datatype = iv_tf_data_s3datatype ).
@@ -281,3 +251 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_datasource
-          EXPORTING
-            io_s3datasource = lo_s3datasource.
+        lo_datasource = NEW #( io_s3datasource = lo_s3datasource ).
@@ -286,3 +254 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_transforminput
-          EXPORTING
-            io_datasource      = lo_datasource
+        lo_transforminput = NEW #( io_datasource = lo_datasource
@@ -290 +256 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-            iv_compressiontype = iv_tf_data_compressiontype.
+                                   iv_compressiontype = iv_tf_data_compressiontype ).
@@ -293,4 +259,2 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_transformresources
-          EXPORTING
-            iv_instancecount = iv_instance_count
-            iv_instancetype  = iv_instance_type.
+        lo_transformresources = NEW #( iv_instancecount = iv_instance_count
+                                       iv_instancetype = iv_instance_type ).
@@ -299,3 +263 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_transformoutput
-          EXPORTING
-            iv_s3outputpath = iv_s3_output_path.
+        lo_transformoutput = NEW #( iv_s3outputpath = iv_s3_output_path ).
@@ -310,2 +272 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-                io_transformresources = lo_transformresources
-            ).
+                io_transformresources = lo_transformresources ).
@@ -341,2 +302 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-                iv_endpointname = iv_endpoint_name
-            ).
+                iv_endpointname = iv_endpoint_name ).
@@ -352,2 +312 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-              iv_endpointconfigname = iv_endpoint_config_name
-            ).
+              iv_endpointconfigname = iv_endpoint_config_name ).
@@ -379,2 +338 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-                      iv_modelname = iv_model_name
-                    ).
+                      iv_modelname = iv_model_name ).
@@ -406,2 +364 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-              iv_trainingjobname = iv_training_job_name
-            ).
+              iv_trainingjobname = iv_training_job_name ).
@@ -433,2 +390 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-              iv_namecontains = iv_name_contains
-            ).
+              iv_namecontains = iv_name_contains ).
@@ -460,2 +416 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-              iv_namecontains = iv_name_contains
-            ).
+              iv_namecontains = iv_name_contains ).
@@ -487,2 +442 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-              iv_namecontains = iv_name_contains
-            ).
+              iv_namecontains = iv_name_contains ).
@@ -515,2 +469 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-              iv_maxresults = iv_max_results
-            ).
+              iv_maxresults = iv_max_results ).
@@ -575 +528 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_hyperparameters_w EXPORTING iv_value = iv_hp_max_depth.
+        lo_hyperparameters_w = NEW #( iv_value = iv_hp_max_depth ).
@@ -578 +531 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_hyperparameters_w EXPORTING iv_value = iv_hp_eta.
+        lo_hyperparameters_w = NEW #( iv_value = iv_hp_eta ).
@@ -581 +534 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
-        CREATE OBJECT lo_hyperparameters_w EXPORTING iv_value = iv_hp_eval_metric.
+        lo_hyperparameters_w = NEW #( iv_value = iv_hp_eval_metric ).