Commit 9ca7c4fe authored by József Gyürüsi's avatar József Gyürüsi
Browse files

[aat_ims_load_test_service #1969810] task - TLS for Titansim RESTapi


   ProtoTuple parameter added to f_EPTF_DsRestAPI_start which is then passed to f_IPL4_listen

Change-Id: Id7d2e4d4a92a9bca297815f222325df0dc953041
Signed-off-by: József Gyürüsi's avatarJózsef Gyürüsi <jozsef.gyurusi@ericsson.com>
parent 38244c35
......@@ -23,6 +23,7 @@
// <EPTF_CLL_Logging_Definitions>
// <TCCFileIO_Functions>
// <TCCConversion_Functions>
// <IPL4asp_Types>
//
// Current Owner:
// Tamas Kis (ekistam)
......@@ -51,6 +52,7 @@ import from EPTF_CLL_Logging_Functions all;
import from EPTF_CLL_Variable_Definitions all;
import from TCCFileIO_Functions all;
import from TCCConversion_Functions all;
import from IPL4asp_Types all;
///////////////////////////////////////////////////////////
// Function: f_EPTF_DsRestAPI_init_CT
......@@ -99,6 +101,7 @@ public function f_EPTF_DsRestAPI_init_CT(in charstring pl_selfName) runs on EPTF
// pl_HTTPServer_dir - *in charstring* - the path of HTTP server directory
// pl_customizableApp_dir - *in charstring* - the path of customizableApp directory
// pl_API_dir - *in charstring* - the path of DsRestAPI API directory
// pl_proto - *in <ProtoTuple> - the protocol to be used for IPL4, default: { tcp := {} }. For ssl use: { ssl := {} }
//
// Return Value:
// Integer which represents the success of the function.
......@@ -115,13 +118,14 @@ public function f_EPTF_DsRestAPI_start(
in integer pl_hostPort,
in charstring pl_HTTPServer_dir := "",
in charstring pl_customizableApp_dir := "",
in charstring pl_API_dir := ""
in charstring pl_API_dir := "",
in ProtoTuple pl_proto := { tcp := {} }
) runs on EPTF_DsRestAPI_CT return integer {
var integer vl_result := -1;
if(v_EPTF_DsRestAPI_initialized) {
f_EPTF_DsRestAPI_HTTPServer_setDir(pl_HTTPServer_dir);
f_EPTF_DsRestAPI_createSymlinks(pl_customizableApp_dir, pl_API_dir, pl_HTTPServer_dir);
vl_result := f_EPTF_DsRestAPI_HTTPServer_listen(pl_hostIPAddress, pl_hostPort);
vl_result := f_EPTF_DsRestAPI_HTTPServer_listen(pl_hostIPAddress, pl_hostPort, pl_proto);
if (vl_result == 0) {
v_EPTF_DsRestAPI_started := true;
} else {
......
......@@ -84,10 +84,10 @@ group FriendFunctions {
}
}
friend function f_EPTF_DsRestAPI_HTTPServer_listen(in charstring pl_hostIPAddress, in integer pl_hostPort) runs on EPTF_DsRestAPI_HTTPServer_CT return integer{
friend function f_EPTF_DsRestAPI_HTTPServer_listen(in charstring pl_hostIPAddress, in integer pl_hostPort, in ProtoTuple pl_proto) runs on EPTF_DsRestAPI_HTTPServer_CT return integer{
var integer vl_result := -1;
f_EPTF_Common_user("DsRestAPI HTTP Server is trying to listen on " & pl_hostIPAddress & ":" & int2str(pl_hostPort));
var Result vl_res := f_IPL4_listen(v_DsRestAPI_HTTPServer_IPL4_PCO_PT, pl_hostIPAddress, pl_hostPort, { tcp := {} }, { {reuseAddress := { enable := true } } });
var Result vl_res := f_IPL4_listen(v_DsRestAPI_HTTPServer_IPL4_PCO_PT, pl_hostIPAddress, pl_hostPort, pl_proto, { {reuseAddress := { enable := true } } });
if (vl_res.errorCode == omit) {
vl_result := 0;
v_EPTF_DsRestAPI_HTTPServer_connId := vl_res.connId;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment