INSERT INTO "app_configuration" (id, variable, value) VALUES (30, 'lb_application_configuration_name', 'LBL LB Simulator Responder');
INSERT INTO "app_configuration" (id, variable, value) VALUES (31, 'lb_application_configuration_ip_address', '131.254.209.12');
INSERT INTO "app_configuration" (id, variable, value) VALUES (32, 'lb_application_configuration_port', '1124');
INSERT INTO "app_configuration" (id, variable, value) VALUES (33, 'lb_application_configuration_receivingApplication', 'LBL LB Simulator');
INSERT INTO "app_configuration" (id, variable, value) VALUES (34, 'lb_application_configuration_receivingFacility', 'IHE');
INSERT INTO "app_configuration" (id, variable, value) VALUES (35, 'lb_application_configuration_simulated_actor', 'LB');

INSERT INTO "app_configuration" (id, variable, value) VALUES (40, 'lip_application_configuration_name', 'LBL LIP Simulator Responder');
INSERT INTO "app_configuration" (id, variable, value) VALUES (41, 'lip_application_configuration_ip_address', '131.254.209.12');
INSERT INTO "app_configuration" (id, variable, value) VALUES (42, 'lip_application_configuration_port', '1126');
INSERT INTO "app_configuration" (id, variable, value) VALUES (43, 'lip_application_configuration_receivingApplication', 'LBL LIP Simulator');
INSERT INTO "app_configuration" (id, variable, value) VALUES (44, 'lip_application_configuration_receivingFacility', 'IHE');
INSERT INTO "app_configuration" (id, variable, value) VALUES (45, 'lip_application_configuration_simulated_actor', 'LIP');

INSERT INTO "app_configuration" (id, variable, value) VALUES (50, 'dds_ws_endpoint', 'http://gazelle.ihe.net/DDSWS/DemographicDataServerBean?wsdl');
INSERT INTO "app_configuration" (id, variable, value) VALUES (51, 'lip_assigning_authority', '1.3.6.1.4.1.12559.11.1.4.1.2');


INSERT INTO "app_configuration" (id, variable, value) VALUES (52, 'xsl_location', 'http://sumo.irisa.fr/xsl/hl7Validation/resultStylesheet.xsl');
INSERT INTO "app_configuration" (id, variable, value) VALUES (53, 'url_EVCS_ws', 'http://kujira.irisa.fr:8080/Hl7V2Evs-prod-InriaHL7Validator-ejb/InriaHL7CupWS?wsdl');


INSERT INTO "app_configuration" (id, variable, value) VALUES (60, 'charset_to_send_hl7message', 'UTF-8');

INSERT INTO "app_configuration" (id, variable, value) VALUES (70, 'timeout_for_receiving_messages', '30000');

INSERT INTO "app_configuration" (id, variable, value) VALUES (80, 'charset_to_write_hl7message', 'UNICODE UTF-8');

INSERT INTO "tf_actor" (id, name, keyword) VALUES (1, 'Label Broker', 'LB');
INSERT INTO "tf_actor" (id, name, keyword) VALUES (2, 'Label Information Provider', 'LIP');


INSERT INTO sys_config(id, name, application, facility, ip_address, port, actor_id) VALUES (1, 'LBL LB Simulator Responder', 'LBL LB Simulator', 'IHE', '127.0.0.1', 1124, 1);
INSERT INTO sys_config(id, name, application, facility, ip_address, port, actor_id) VALUES (2, 'INRIA', 'LIP', 'LIP INRIA', '127.0.0.1', 5555, 2);
SELECT pg_catalog.setval('sys_config_id_seq', 2, true);


INSERT INTO "tf_transaction" (id, name, keyword) VALUES (1, 'Label Delivery Request', 'LAB-61');
INSERT INTO "tf_transaction" (id, name, keyword) VALUES (2, 'Query for Label Deliveyr Instruction', 'LAB-62');
INSERT INTO "tf_transaction" (id, name, keyword) VALUES (3, 'Labels and Containers Delivered', 'LAB-63');

INSERT INTO "validation_parameters" (id, message_type,profile_oid,actor_id,transaction_id) VALUES (1, 'OML^O33^OML_O33','1.3.6.1.4.12559.11.1.1.136',2,1);
INSERT INTO "validation_parameters" (id, message_type,profile_oid,actor_id,transaction_id) VALUES (2, 'ORL^O34^ORL_O34','1.3.6.1.4.12559.11.1.1.134',1,1);
INSERT INTO "validation_parameters" (id, message_type,profile_oid,actor_id,transaction_id) VALUES (3, 'QBP^SLI^QBP_Q11','1.3.6.1.4.12559.11.1.1.135',1,2);
INSERT INTO "validation_parameters" (id, message_type,profile_oid,actor_id,transaction_id) VALUES (4, 'RSP^SLI^RSP_K11','1.3.6.1.4.12559.11.1.1.137',2,2);

INSERT INTO hl7_simulator_responder_configuration (id, name, listening_port, simulated_actor_id, transaction_id, affinity_domain_id, accepted_message_type, accepted_trigger_event, ip_address, receiving_application, receiving_facility) VALUES (1, 'LIP', 10072, 2, 2, null, '*', '*', '131.254.209.12', 'LBL LIP Simulator', 'IHE');
INSERT INTO hl7_simulator_responder_configuration (id, name, listening_port, simulated_actor_id, transaction_id, affinity_domain_id, accepted_message_type, accepted_trigger_event, ip_address, receiving_application, receiving_facility) VALUES (2, 'LB', 10052, 1, 1, null, '*', '*', '131.254.209.12', 'LBL LB Simulator', 'IHE');
UPDATE hl7_simulator_responder_configuration SET server_bean_name = 'lbMessageServer' WHERE simulated_actor_id = 1;
UPDATE hl7_simulator_responder_configuration SET server_bean_name = 'lipMessageServer' WHERE simulated_actor_id = 2;
UPDATE hl7_simulator_responder_configuration SET is_running = FALSE;

UPDATE hl7_message SET is_visible = TRUE;
