요약
Host Integration Server에는 HIS 런타임의 다양한 구성 요소에서 백 엔드 시스템과 통신하는 데 사용되는 .hidx 파일을 만들 수 있도록 하는 Visual Studio Designer 포함되어 있습니다. Studio Designer 통해 .hidx 파일을 만드는 것은 엄격히 수동 작업입니다. 그러나 PowerShell을 통해 .hidx 파일 생성을 자동화하면 프로젝트 수명 동안 시간을 절약할 수 있습니다. 누적 업데이트 2를 사용하면 PowerShell을 통해 .hidx 파일을 만들고 수정할 수 있습니다.
32비트 Visual Studio Designer 구성 요소가 호출되므로 32비트 버전의 PowerShell을 사용해야 합니다. 64비트 버전의 PowerShell을 사용하는 경우 다음과 유사한 오류 메시지가 기록됩니다.
참고
'Microsoft.HostIntegration.Importer.PowerShell.NewHisWipHidxFile'의 형식 이니셜라이저에서 예외가 발생했습니다.
추가 정보
이 업데이트는 Host Integration Server 2016의 누적 업데이트 2에 포함되어 있습니다.
다음은 Visual Studio에서 만들 수 있는 호스트 통합 프로젝트의 종류입니다.
- BizTalk 파이프라인 변환
- 호스트 애플리케이션
- 호스트 파일
- 메시지 큐
이 업데이트 롤업이 설치되면 PowerShell을 통해 이러한 각 프로젝트 유형에 대한 .hidx 파일을 만들 수 있습니다. PowerShell을 사용하여 파일을 만들기 전에 Visual Studio Designer 통해 .hidx 파일을 빌드한 경험이 있는 것이 좋습니다.
PowerShell을 사용하려면 32비트 Windows PowerShell ISE(x86)를 연 다음 보기 메뉴에서 명령 추가 기능 표시를 선택합니다. 명령 탭에서 Microsoft.HostIntegration.Importer.PowerShell 모듈을 선택하여 사용 가능한 PowerShell 명령 목록을 표시합니다.
예제
다음 작업을 수동으로 수행하려면 다음 단계를 수행합니다.
- WIP hidx 개체를 만듭니다.
- GetAccounts라는 메서드를 추가합니다.
- CustomerName이라는 입력 30자 문자열 매개 변수를 추가합니다.
- AccountNum이라는 입력 6자 문자열 매개 변수를 추가합니다.
- PIC S9(7)V99인 Balance 라는 출력 10진수 매개 변수를 추가합니다.
- WIP hidx 개체를 파일로 저장합니다. hidx 파일은 C:\Lab에 저장됩니다. $WIPhidx 개체를 만들 수 있으려면 폴더가 있어야 합니다.
이러한 작업을 자동화하려면 PowerShell에서 다음 스크립트를 실행합니다.
$WIPhidx = New-HisWipHidxFile -ElmUserData -Name MyNamespace -Interface IMyInterface -
Description "My Description" -File C:\Lab\WIPSample.hidx
$WIPMethod = Add-HisHidxElement -InputObject $WIPhidx -Method -Name GetAccounts
$NameParameter = $WIPMethod | Add-HisHidxParameter -Name CustomerName -Atomic
$NameParameter.Direction = "In"
$NameParameter.DataType = "String"
$NameParameter.ConversionInformation.Size = 30
$AccountParameter = $WIPMethod | Add-HisHidxParameter -Name AccountNum -Atomic
$AccountParameter.Direction = "In"
$AccountParameter.DataType = "String"
$AccountParameter.ConversionInformation.Size = 6
$BalanceParameter = $WIPMethod | Add-HisHidxParameter -Name Balance -Atomic
$BalanceParameter.Direction = "Out"
$BalanceParameter.DataType = "Decimal"
$BalanceParameter.ConversionInformation.HostDataType = "PIC S9(n)V9(n) COMP-3"
$BalanceParameter.ConversionInformation.Precision = 7
$BalanceParameter.ConversionInformation.Scale = 2
$WIPhidx.Save()
참고 추가 예제 PowerShell 스크립트는 GitHub에서 사용할 수 있습니다.
참조 자료
Microsoft에서 소프트웨어 업데이트를 설명하는 데 사용하는 용어 에 대해 알아봅니다.