Why connection draw behind group?

There is two places you’d need to look into:

  • Ensure that the diagram is imported in the correct manner
  • Ensure that the connection is rendered / recognized in the correct order, cf. BpmnOrderingProvider that implements this for message flows (always rendered on top),.