Announcement

Collapse

NextGen (Mirth) Connect 3.10.0 Released!

NextGen (Mirth) Connect 3.10.0 is now available as an appliance update and on our GitHub page. This release includes better SQL Server database support, security improvements through fixes and library updates, and improvements for the Advanced Clustering plugin with a focus on improving performance of many of the tasks that are carried out on a frequent interval. See the release notes for the list of fixes and updates.

Download | See What's New | Upgrade Guide | Release Notes

For discussion on this release, see this thread.
See more
See less

problem with edi message

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • problem with edi message

    Hello,



    We need to work with messages EDI and to map it to XML messages. When we load the example message at the incoming data at the Edit Channel, we don't know how indicate if our EDI message have multiples optional segments. Is it any documentation to use this option?



    Later we define the XML message at the Outgoing data and we try to map the message but when we receive the EDI message at the HTTP Listener Input Channel, we receive a XML message and not the EDI that we have defined. So the map doesn't run.



    Can you help us with any documentation?

  • #2
    Reroblem with edi message

    SerializerFactory.getEDISerializer('~','*', ':').toXML(message);
    default xml namespace = new Namespace('urn:mirthproject-org:edi:xml');

    it doesn't get element.

    can you help me.?

    Comment


    • #3
      Reroblem with edi message

      this is my channel
      <com.webreach.mirth.model.Channel>
      <id>0da3b301-f845-40ee-acfa-b7113ee38e34</id>
      <name>prueba edi</name>
      <description></description>
      <enabled>true</enabled>
      <version>1.4.0</version>
      <revision>35</revision>
      <sourceConnector>
      <name>sourceConnector</name>
      <properties>
      <property name="ackIP">...</property>
      <property name="ackOnNewConnection">0</property>
      <property name="keepSendSocketOpen">1</property>
      <property name="bufferSize">65536</property>
      <property name="port">6661</property>
      <property name="ackPort"></property>
      <property name="DataType">TCP Listener</property>
      <property name="receiveTimeout">5000</property>
      <property name="charsetEncoding">DEFAULT_ENCODING</property>
      <property name="host">127.0.0.1</property>
      <property name="responseValue">None</property>
      </properties>
      <transformer>
      <steps>
      <com.webreach.mirth.model.Step>
      <sequenceNumber>0</sequenceNumber>
      <name>New Step</name>
      <script>SerializerFactory.getEDISerializer(&apos;~ &apos;,&apos;*&apos;, &apos;:&apos.toXML(message);
      default xml namespace = new Namespace(&apos;urn:mirthproject-org:edi:xml&apos;</script>
      <type>JavaScript</type>
      <data class="map">
      <entry>
      <string>Script</string>
      <string>SerializerFactory.getEDISerializer(&apos;~ &apos;,&apos;*&apos;, &apos;:&apos.toXML(message);
      default xml namespace = new Namespace(&apos;urn:mirthproject-org:edi:xml&apos;</string>
      </entry>
      </data>
      </com.webreach.mirth.model.Step>
      </steps>
      <inboundTemplate>DatosQ* CuerpoZ</inboundTemplate>
      <outboundTemplate></outboundTemplate>
      <inboundProtocol>EDI</inboundProtocol>
      <outboundProtocol>XML</outboundProtocol>
      <inboundProperties>
      <property name="elementDelimiter">*</property>
      <property name="subelementDelimiter">:</property>
      <property name="segmentDelimiter">~</property>
      </inboundProperties>
      <outboundProperties/>
      </transformer>
      <filter>
      <rules/>
      </filter>
      <transportName>TCP Listener</transportName>
      <mode>SOURCE</mode>
      </sourceConnector>
      <destinationConnectors>
      <com.webreach.mirth.model.Connector>
      <name>Destination 1</name>
      <properties>
      <property name="charsetEncoding">DEFAULT_ENCODING</property>
      <property name="outputAppend">1</property>
      <property name="DataType">File Writer</property>
      <property name="outputPattern">edi.xml</property>
      <property name="template">${message.transformedData}
      ${message.encodedData}
      ${message.source}</property>
      <property name="host">C:/Documents and Settings/Medicalis/Escritorio/medicalis_espe/software/mirth-1.3.2/mensaje</property>
      <property name="binary">0</property>
      </properties>
      <transformer>
      <steps/>
      <inboundTemplate></inboundTemplate>
      <outboundTemplate></outboundTemplate>
      <inboundProtocol>XML</inboundProtocol>
      <outboundProtocol>XML</outboundProtocol>
      <inboundProperties/>
      <outboundProperties/>
      </transformer>
      <filter>
      <rules/>
      </filter>
      <transportName>File Writer</transportName>
      <mode>DESTINATION</mode>
      </com.webreach.mirth.model.Connector>
      </destinationConnectors>
      <properties>
      <property name="initialState">started</property>
      <property name="synchronous">true</property>
      <property name="store_messages">true</property>
      <property name="encryptData">false</property>
      <property name="transactional">false</property>
      <property name="max_message_age">-1</property>
      <property name="dont_store_filtered">false</property>
      <property name="error_messages_only">false</property>
      </properties>
      <preprocessingScript>// Modify the message variable below to pre process data&#x0D;
      return message;
      </preprocessingScript>
      </com.webreach.mirth.model.Channel>

      Comment


      • #4
        Reroblem with edi message

        and this is the error
        ERROR-301: Transformer conversion error
        ERROR MESSAGE: Error adapting message
        org.xml.sax.SAXParseException: Content is not allowed in prolog.
        at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
        at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(U nknown Source)
        at com.webreach.mirth.server.mule.adaptors.XMLAdaptor .populateMessage(XMLAdaptor.java:23)
        at com.webreach.mirth.server.mule.adaptors.Adaptor.co nvertMessage(Adaptor.java:53)
        at com.webreach.mirth.server.mule.transformers.JavaSc riptTransformer.transform(JavaScriptTransformer.ja va:208)
        at org.mule.transformers.AbstractEventAwareTransforme r.doTransform(AbstractEventAwareTransformer.java:4 8)
        at org.mule.transformers.AbstractTransformer.transfor m(AbstractTransformer.java:197)
        at org.mule.impl.MuleEvent.getTransformedMessage(Mule Event.java:251)
        at com.webreach.mirth.server.controllers.MessageObjec tController.getMessageObjectFromEvent(MessageObjec tController.java:276)
        at com.webreach.mirth.server.mule.providers.file.File MessageDispatcher.doDispatch(FileMessageDispatcher .java:71)
        at com.webreach.mirth.server.mule.providers.file.File MessageDispatcher.doSend(FileMessageDispatcher.jav a:203)
        at org.mule.providers.AbstractMessageDispatcher.send( AbstractMessageDispatcher.java:166)
        at org.mule.impl.MuleSession.sendEvent(MuleSession.ja va:191)
        at org.mule.impl.MuleSession.sendEvent(MuleSession.ja va:130)
        at org.mule.routing.outbound.AbstractOutboundRouter.s end(AbstractOutboundRouter.java:85)
        at org.mule.routing.outbound.FilteringMulticastingRou ter.route(FilteringMulticastingRouter.java:89)
        at org.mule.routing.outbound.OutboundMessageRouter$1. doInTransaction(OutboundMessageRouter.java:78)
        at org.mule.transaction.TransactionTemplate.execute(T ransactionTemplate.java:48)
        at org.mule.routing.outbound.OutboundMessageRouter.ro ute(OutboundMessageRouter.java:82)
        at org.mule.impl.model.DefaultMuleProxy.onCall(Defaul tMuleProxy.java:247)
        at org.mule.impl.model.seda.SedaComponent.doSend(Seda Component.java:209)
        at org.mule.impl.model.AbstractComponent.sendEvent(Ab stractComponent.java:277)
        at org.mule.impl.MuleSession.sendEvent(MuleSession.ja va:201)
        at org.mule.routing.inbound.InboundMessageRouter.send (InboundMessageRouter.java:161)
        at org.mule.routing.inbound.InboundMessageRouter.rout e(InboundMessageRouter.java:128)
        at org.mule.providers.AbstractMessageReceiver$Default InternalMessageListener.onMessage(AbstractMessageR eceiver.java:492)
        at org.mule.providers.AbstractMessageReceiver.routeMe ssage(AbstractMessageReceiver.java:271)
        at org.mule.providers.AbstractMessageReceiver.routeMe ssage(AbstractMessageReceiver.java:243)
        at com.webreach.mirth.server.mule.providers.tcp.TcpMe ssageReceiver$TcpWorker.processData(TcpMessageRece iver.java:278)
        at com.webreach.mirth.server.mule.providers.tcp.TcpMe ssageReceiver$TcpWorker.run(TcpMessageReceiver.jav a:250)
        at org.mule.impl.work.WorkerContext.run(WorkerContext .java:290)
        at edu.emory.mathcs.backport.java.util.concurrent.Thr eadPoolExecutor$Worker.runTask(ThreadPoolExecutor. java:650)
        at edu.emory.mathcs.backport.java.util.concurrent.Thr eadPoolExecutor$Worker.run(ThreadPoolExecutor.java :675)
        at java.lang.Thread.run(Unknown Source)

        Comment


        • #5
          Reroblem with edi message

          Not that to put in the javascript or which is the failure, you can help me?

          Comment

          Working...
          X