I'm testing a system that involves XMLs from a JMS queue getting inserted into a database using a JMS trigger (webmethods).

Firstly, I turn off the JMS trigger to let messages accumulate on the queue, then I examine some XML messages. Take a count of them, look for special character such as $ <> ' " in the XMLs. Then I turn the trigger back on and compare some values between the XMLs and the database records and ensure the counts match.

Just wondering if anyone has had any similar experiences regarding how things to look out for or a suitable test approach as I'm new to the subject?

  • 1
    You do not insert the entire XML document into the database; rather, you parse it and insert some of the parsed results into the database. Is that right?
    – user246
    Sep 28 '11 at 13:32
  • correct, there are mappings that say which xpath in the xml should go to which column in the database table
    – toop
    Sep 28 '11 at 13:41
  • Just curious, what is an exploratory aspect of this question?
    – dzieciou
    May 5 '12 at 18:14

I assume for the purposes of your question you are not concerned about testing anything upstream from the JMS queue. You may want to check whether the values in the XML are consistent with any constraints in the databases, e.g. uniqueness or maximum length. Depending on your circumstances, you may also want to test what happens when the values are not consistent with the constraints.


This is basically what suggests user246, but I would list first criteria you want to evaluate in form of questions:

  • Are data from XML inserted correctly to DB for possible combinations of data?
  • How the system responds when XML data are incomplete or incorrect?
  • How the system responds when XML does not respect XML schema? (if this situation can potentially occur in your environment)
  • What happens if a single XML document or single elements of XML document are too large for the system to process, e.g., because of memory, DB schema, etc.?
  • How the system performs when values are too long? Aren't they truncated?
  • etc.

I would start first from preparing XML documents representing above cases and then try the system on them.

Additionally, if this is more like an test of integration between message procedure and consumer, I would ask if there are any constrains regarding their communication:

  • How fast XML messages must be processed?
  • How many XML messages may be in the queue?
  • Is the system able to process those messages in requested time?
  • Is this external queue? If so, what happens to the system when the queue is down and up again? Does system should and handles in fact such situations?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.