public interface MtkTestService
Modifier and Type | Method and Description |
---|---|
TestIdData |
downloadTestFilesForATest(String testId)
Downloads all information associated with the testing of a Message Type,
based on the Test Id.
|
String[] |
getMatchingTestIds(String testId)
Searches the Test Ids matching the given pattern.If no match is found, a
zero length array is returned.
|
String |
getTestStatus(String testId)
Gets step by step description of status of the processing a Message Type
testing.
|
void |
removeTestFilesForATest(String testId)
Removes permanently all information associated with a Test Id.
|
String |
testCustomMessageType(SchemaInformation[] schemaInformation,
String testDesc,
boolean generateReport)
The API provides a mechanism for the user to test a custom RMIM.
|
String testCustomMessageType(SchemaInformation[] schemaInformation, String testDesc, boolean generateReport) throws HDRRimException
The API provides a mechanism for the user to test a custom RMIM. The user
can create a new custom RMIM or modify an existing RMIM and save it as a
new RMIM. After RMIM is developed, XSD and MIF are generated using HL7
ITS Tooling and cmetinfo.core mif file is updated for new CMETs. After
XSD and MIFs are generated successfully, user should invoke the API with
following information to test the RMIM.
The API creates a folder in the test server and writes all XSDs/MIFs and test files into the folder. The folder is available at the location $CTB_TOP/oracle/apps/ctb/message/defs/customSchema/{TestId}. TestId is generated as following, TestId = MessageTypeId_UserId_YYYYMMDD_HHMMSS.
If the testing is successful, the API returns the Test ID. In case of any
failure, the testing does not stop in the middle, the
HDRRimException
is thrown after
passing all the steps. The exception instance contains the Test Id value
in parameter "TEST_ID". Following code snippet demonstrates how to
retrieve the TestId from the
HDRRimException
instance.
String testId = (String)ctbException.getParameter("TEST_ID")};
All the test data loaded into the test server are rolled back from data base, irrespective of whether the test is successful or unsuccessful. However, the test directory and test files will be available in the server. Use the following APIs to fetch the test files and remove the test files.
To fetch the test files:
oracle.hsgbu.hdr.hl7.message.mtk.TestIdData
testIdData = mtkTestService.downloadTestFilesForATest(testId)
;
To remove the test files:
mtkTestService.removeTestFilesForATest(testId)
;
The step by step processing of the testing is as following:
Getting input parameters
String status = mtkTestService.getTestStatus(testId)
;
schemaInformation
- oracle.hsgbu.hdr.hl7.message.mtk.SchemaInformation
list of XSD and MIF
of Payload, MIF and XSD of CMETS associated with the Payload and
cmetinfo.coremif.testDesc
- Comments about the test created by the user.generateReport
- Flag, indicating whether the configuration report
files should be generated for this testing. If the fag is set to true,
then all configuration report files will be generated. Else, no
configuration report files will be generated.HDRRimException
- This exception is thrown if,
oracle.hsgbu.hdr.hl7.message.mtk.SchemaInformation
, have same name as
the Oracle Artifacts.oracle.hsgbu.hdr.hl7.message.mtk.SchemaInformation
list.oracle.hsgbu.hdr.hl7.message.mtk.SchemaInformation
list.oracle.hsgbu.hdr.hl7.message.mtk.SchemaInformation
list, if one or
more CMETs are passed in the input list.void removeTestFilesForATest(String testId) throws HDRRimException
testId
- Test Id returned while testing a Message Type.HDRRimException
- This exception is thrown if
TestIdData downloadTestFilesForATest(String testId) throws HDRRimException
oracle.hsgbu.hdr.hl7.message.mtk.TestIdData
) object contains the
following data:
oracle.hsgbu.hdr.hl7.message.mtk.TestMessage
(s). Each
oracle.hsgbu.hdr.hl7.message.mtk.TestMessage
has a pair of Test
Message and Generated Message. testId
- Test Id returned while testing a Message Typeoracle.hsgbu.hdr.hl7.message.mtk.TestIdData
, with the test
files, including
HDRRimException
- This exception is thrown if
String[] getMatchingTestIds(String testId) throws HDRRimException
Searches the Test Ids matching the given pattern.If no match is found, a
zero length array is returned. The search pattern is case-insensitive.
The search pattern can contain Oracle wildcards('%'symbol).
Example:
testId
- Test Id returned while testing a Message Type.HDRRimException
- This exception is thrown if,
String getTestStatus(String testId) throws HDRRimException
Payload Id : PRTS_MT000010TK01
Test
Id :
PRTS_MT000010TK01_SYSADMIN_20080317_070223
Payload Type :
ACT
Validating Artifacts -
started
Validating input
parameters..
successful
Adding
artifacts into server..
Adding artifacts
into server successful
Extracting metadata from
MIFs..
successful
Validating payload
schema..
successful
Validating
Artifacts - completed
Generating configuration
reports - started
Generating MasterCatalog configuration report ..
successful(oracle/apps/ctb/message/defs/customSchema/PRTS_MT000010TK01_SYSADMIN_20080317_070223/results/MastercatalogReport.csv)
Generating SideEffect configuration report..
successful
(oracle/apps/ctb/message/defs/customSchema/PRTS_MT000010TK01_SYSADMIN_20080317_070223/results/SideEffectReport.csv)
Generating Act Concept configuration
report..
successful
(oracle/apps/ctb/message/defs/customSchema/PRTS_MT000010TK01_SYSADMIN_20080317_070223/results/AmbiguousComplexTypeReport.csv)
Generating
configuration reports -
completed
Test Message Generation - started
Generating message
successful
(oracle/apps/ctb/message/defs/customSchema/PRTS_MT000010TK01_SYSADMIN_20080317_070223/PRTS_MT000010TK01.ObservationGeneralIMP0.xml)
Generating message
successful
(oracle/apps/ctb/message/defs/customSchema/PRTS_MT000010TK01_SYSADMIN_20080317_070223/PRTS_MT000010TK01.ObservationGeneralIMP1.xml)
Generating message
successful
(oracle/apps/ctb/message/defs/customSchema/PRTS_MT000010TK01_SYSADMIN_20080317_070223/PRTS_MT000010TK01.ObservationGeneralIMP2.xml)
Test
Message Generation - completed
Testing all Test Messages - started
Testing Message - started
(PRTS_MT000010TK01.ObservationGeneralIMP1.xml)
Configuring - started
Trigger
Event : CON-X2787564 (POXX_TE000003/HTB
Supplemental)
Configuring
Interaction..
successful
Configuring
MasterCatalogs..
successful
Configuring Sender and
SideEffects..
successful
Configuring Act
Concepts..
successful
Configuring - completed
Persisting message using IMP
..
successful
Persisted ControlAct:
1.2.3/2157037451
Generating message using
OMP..
successful
Generated
Message :
oracle/apps/ctb/message/defs/customSchema/PRTS_MT000010TK01_SYSADMIN_20080317_070223/results/PRTS_MT000010TK01.ObservationGeneralOMP1.xml
Validating generated message against schema..
successful
Testing
Message - completed
(PRTS_MT000010TK01.ObservationGeneralIMP1.xml)
Testing Message - started
(PRTS_MT000010TK01.ObservationGeneralIMP0.xml)
Configuring - started
Trigger
Event : CON-X2787564 (POXX_TE000003/HTB
Supplemental)
Configuring
Interaction..
successful
Configuring
MasterCatalogs..
successful
Configuring Sender and
SideEffects..
successful
Configuring Act
Concepts..
successful
Configuring - completed
Persisting message using IMP
..
successful
Persisted ControlAct:
9.989898.5/2157039451
Generating message using
OMP..
successful
Generated
Message :
oracle/apps/ctb/message/defs/customSchema/PRTS_MT000010TK01_SYSADMIN_20080317_070223/results/PRTS_MT000010TK01.ObservationGeneralOMP0.xml
Validating generated message against schema..
successful
Testing
Message - completed
(PRTS_MT000010TK01.ObservationGeneralIMP0.xml)
Testing Message - started
(PRTS_MT000010TK01.ObservationGeneralIMP2.xml)
Configuring - started
Trigger
Event : CON-X2787564 (POXX_TE000003/HTB
Supplemental)
Configuring
Interaction..
successful
Configuring
MasterCatalogs..
successful
Configuring Sender and
SideEffects..
successful
Configuring Act
Concepts..
successful
Configuring - completed
Persisting message using IMP
..
successful
Persisted ControlAct:
9.989898.5/2157039851
Generating message using
OMP..
successful
Generated
Message :
oracle/apps/ctb/message/defs/customSchema/PRTS_MT000010TK01_SYSADMIN_20080317_070223/results/PRTS_MT000010TK01.ObservationGeneralOMP2.xml
Validating generated message against schema..
successful
Testing
Message - completed
(PRTS_MT000010TK01.ObservationGeneralIMP2.xml)
Testing all Test Messages - completed
Rolling Back all test data..
TESTING SUCCESSFUL
2. Sample Status file content, when the testing has failed.
Parsing payload information from payload Mif.. successful
Payload Id : POXX_MT110000TK03
Test
Id :
POXX_MT110000TK03_SYSADMIN_20080319_224053
Payload Type :
ACT
Validating Artifacts -
started
Validating input
parameters..
successful
Adding
artifacts into server..
Warning !!! a cmet
name from cmetinfo.coremif referes to different cmet id in production
environment
CMET_NAME : A_AccountPayeeUniversal EXISTING_CMET_ID
:COCT_MT110200HT01 NEW_CMET_ID :COCT_MT110200TK01
Warning !!! a
cmet name from cmetinfo.coremif referes to different cmet id in
production environment
CMET_NAME : A_AccountPayorUniversal
EXISTING_CMET_ID :COCT_MT110100HT01 NEW_CMET_ID
:COCT_MT110100TK01
Warning !!! a cmet name from cmetinfo.coremif
referes to different cmet id in production environment
CMET_NAME : A_ActMinimal EXISTING_CMET_ID :COCT_MT000110HT01
NEW_CMET_ID :COCT_MT000110TK01
Warning !!! a cmet name
from cmetinfo.coremif referes to different cmet id in production
environment
CMET_NAME : R_SupplyItemUniversal EXISTING_CMET_ID
:COCT_MT940010HT02 NEW_CMET_ID :COCT_MT940010TK02
Adding
artifacts into server successful
Extracting metadata from
MIFs..
successful
Validating payload
schema..
successful
Validating
Artifacts - completed
Generating configuration
reports -
started
Generating MasterCatalog configuration report ..
successful
(oracle/apps/ctb/message/defs/customSchema/POXX_MT110000TK03_SYSADMIN_20080319_224053/results/MastercatalogReport.csv)
Generating SideEffect configuration report..
successful
(oracle/apps/ctb/message/defs/customSchema/POXX_MT110000TK03_SYSADMIN_20080319_224053/results/SideEffectReport.csv)
Generating Act Concept configuration
report..
successful
(oracle/apps/ctb/message/defs/customSchema/POXX_MT110000TK03_SYSADMIN_20080319_224053/results/AmbiguousComplexTypeReport.csv)
Generating
configuration reports -
completed
Test Message Generation - started
Generating message
successful
(oracle/apps/ctb/message/defs/customSchema/POXX_MT110000TK03_SYSADMIN_20080319_224053/POXX_MT110000TK03.ObservationEventIMP0.xml)
Generating message
successful
(oracle/apps/ctb/message/defs/customSchema/POXX_MT110000TK03_SYSADMIN_20080319_224053/POXX_MT110000TK03.ObservationEventIMP1.xml)
Generating message
successful
(oracle/apps/ctb/message/defs/customSchema/POXX_MT110000TK03_SYSADMIN_20080319_224053/POXX_MT110000TK03.ObservationEventIMP2.xml)
Generating message
successful
(oracle/apps/ctb/message/defs/customSchema/POXX_MT110000TK03_SYSADMIN_20080319_224053/POXX_MT110000TK03.ObservationEventIMP3.xml)
Test
Message Generation - completed
Testing all Test Messages - started
Testing Message - started
(POXX_MT110000TK03.ObservationEventIMP0.xml)
Configuring - started
Trigger
Event : CON-X2787188 (EncounterStatus/HTB
Supplemental)
Configuring
Interaction..
successful
Configuring
MasterCatalogs..
successful
Configuring Sender and
SideEffects..
successful
Configuring Act
Concepts..
successful
Configuring - completed
Persisting message using IMP
..
successful
Persisted ControlAct:
9.989898.5/286893102
Generating message using
OMP..
successful
Generated
Message :
oracle/apps/ctb/message/defs/customSchema/POXX_MT110000TK03_SYSADMIN_20080319_224053/results/POXX_MT110000TK03.ObservationEventOMP0.xml
Validating generated message against schema..
failed
Testing
Message - failed.
(POXX_MT110000TK03.ObservationEventIMP0.xml)
ERROR: CTB_MTK_MS_SCM_VALIDATN_FAIL:CTB_MTK_MS_SCM_VALIDATN_FAIL: Message generated by OMP failed to validate against the schema. CAUSE: Element 'center' not expected.
Testing Message - started
(POXX_MT110000TK03.ObservationEventIMP2.xml)
Configuring - started
Trigger
Event : CON-X2787188 (EncounterStatus/HTB
Supplemental)
Configuring
Interaction..
successful
Configuring
MasterCatalogs..
successful
Configuring Sender and
SideEffects..
successful
Configuring Act
Concepts..
successful
Configuring - completed
Persisting message using IMP
..
successful
Persisted ControlAct:
9.989898.5/286902502
Generating message using
OMP..
successful
Generated
Message :
oracle/apps/ctb/message/defs/customSchema/POXX_MT110000TK03_SYSADMIN_20080319_224053/results/POXX_MT110000TK03.ObservationEventOMP2.xml
Validating generated message against schema..
failed
Testing
Message - failed.
(POXX_MT110000TK03.ObservationEventIMP2.xml)
ERROR: CTB_MTK_MS_SCM_VALIDATN_FAIL:CTB_MTK_MS_SCM_VALIDATN_FAIL: Message generated by OMP failed to validate against the schema. CAUSE: Element 'center' not expected.
Testing Message - started
(POXX_MT110000TK03.ObservationEventIMP1.xml)
Configuring - started
Trigger
Event : CON-X2787188 (EncounterStatus/HTB
Supplemental)
Configuring
Interaction..
successful
Configuring
MasterCatalogs..
successful
Configuring Sender and
SideEffects..
successful
Configuring Act
Concepts..
successful
Configuring - completed
Persisting message using IMP
..
successful
Persisted ControlAct:
1.2.3/286882702
Generating message using
OMP..
successful
Generated
Message :
oracle/apps/ctb/message/defs/customSchema/POXX_MT110000TK03_SYSADMIN_20080319_224053/results/POXX_MT110000TK03.ObservationEventOMP1.xml
Validating generated message against schema..
failed
Testing
Message - failed.
(POXX_MT110000TK03.ObservationEventIMP1.xml)
ERROR: CTB_MTK_MS_SCM_VALIDATN_FAIL:CTB_MTK_MS_SCM_VALIDATN_FAIL: Message generated by OMP failed to validate against the schema. CAUSE: Element 'center' not expected.
Testing Message - started
(POXX_MT110000TK03.ObservationEventIMP3.xml)
Configuring - started
Trigger
Event : CON-X2787188 (EncounterStatus/HTB
Supplemental)
Configuring
Interaction..
successful
Configuring
MasterCatalogs..
successful
Configuring Sender and
SideEffects..
successful
Configuring Act
Concepts..
successful
Configuring - completed
Persisting message using IMP
..
successful
Persisted ControlAct:
9.989898.5/286920602
Generating message using
OMP..
successful
Generated
Message :
oracle/apps/ctb/message/defs/customSchema/POXX_MT110000TK03_SYSADMIN_20080319_224053/results/POXX_MT110000TK03.ObservationEventOMP3.xml
Validating generated message against schema..
failed
Testing
Message - failed.
(POXX_MT110000TK03.ObservationEventIMP3.xml)
ERROR: CTB_MTK_MS_SCM_VALIDATN_FAIL:CTB_MTK_MS_SCM_VALIDATN_FAIL: Message generated by OMP failed to validate against the schema. CAUSE: Element 'center' not expected.
Testing all Test Messages - failed
Rolling Back all test data..
TESTING FAILED
testId
- - Test Id returned while testing a Message TypeHDRRimException
- This exception is thrown if
HDR Glossary HDR Concept Lists HDR Exceptions HDR Programmer's Guide HDR Implementation Guide HDR Profile Options
Copyright © 2016, 2018, Oracle. All rights reserved