148.5. Spring Boot Auto-Configuration

구성 요소는 아래 나열된 5 가지 옵션을 지원합니다.

이름설명기본값유형

camel.dataformat.hl7.content-type-header

데이터 형식이 데이터 형식에서 수행할 수 있는 경우 데이터 형식의 유형으로 Content-Type 헤더를 설정해야 하는지 여부입니다. 예를 들어 데이터 형식을 XML로 마샬링하거나, JSon으로 마샬링되는 데이터 형식에 대한 application/json 등이 있습니다.

false

부울

camel.dataformat.hl7.enabled

hl7 dataformat 사용

true

부울

camel.dataformat.hl7.validate

HL7 메시지의 유효성을 검사할지 여부는 기본적으로 true입니다.

true

부울

camel.language.terser.enabled

터 언어 활성화

true

부울

camel.language.terser.trim

선행 공백과 후행 공백과 줄 바꿈을 제거할 값을 조정할지 여부입니다.

true

부울

ND

  • Mar shal = from Message to byte stream (HL7 MLLP 코덱을 사용하여 응답할 때 사용할 수 있음)
  • unmarshal = from byte stream to Message (HL7 MLLP에서 스트리밍 데이터를 받을 때 사용할 수 있음)

데이터 형식을 사용하려면 인스턴스를 인스턴스화하고 경로 빌더에서 marshal 또는 unmarshal 작업을 호출하면 됩니다.

  DataFormat hl7 = new HL7DataFormat();

  from("direct:hl7in")
    .marshal(hl7)
    .to("jms:queue:hl7out");

위의 샘플에서 HL7은 HAPI Message 개체에서 바이트 스트림으로 마샬링되어 JMS 큐에 배치됩니다.
다음은 그 반대의 예입니다.The following example is the opposite:

  DataFormat hl7 = new HL7DataFormat();

  from("jms:queue:hl7out")
    .unmarshal(hl7)
    .to("patientLookupService");

여기서 우리는 바이트 스트림을 환자 조회 서비스로 전달되는 HAPI Message 객체로 미끄럽습니다.

148.5.1. serializable 메시지

HAPI 2.0( Camel 2.11에서 사용)부터 HL7v2 모델 클래스는 완전히 직렬화할 수 있습니다. 따라서 HL7v2 메시지를 JMS 대기열(즉, marshal() 을 호출하지 않고) 대기열에서 직접 읽고(예: unmarshal() 를 호출하지 않고) 메시지를 직접 읽을 수 있습니다.