InterSystems IRIS를 사용한 COVID-19 분석
Johns Hopkins University는 매일 코로나바이러스 COVID-19 팬데믹 상태에 대한 새로운 데이터를 발표합니다.
질병 발생의 주요 척도를 보여주는 GCP Kubernetes에 배포된 도커에서 InterSystems IRIS Community Edition을 사용하여 simple InterSystems IRIS Analytics dashboard을 빌드했습니다.
이 대시보드는 IRIS Analytics로 CSV의 정보를 분석하고 InterSystems IRIS Community Edition의 형태로 GCP Kubernetes에 배포하는 방법의 예입니다.
interactive map of the USA을 추가했습니다.
next dashboard shows the timeline :
국가별로 필터링할 수 있습니다. 예를 들어 여기는 in the USA:
애플리케이션의 소스 코드는 available on Open Exchange.입니다.
어떻게 작동합니까?
데모는 InterSystems IRIS Community Edition 도커 컨테이너를 사용하여 실행되며 MDX2JSON REST API를 통해 DeepSee 웹 표현 계층을 사용하여 InterSystems IRIS BI 대시보드를 노출합니다. GCP에 배포되고 Google Kubernetes Engine(GKE)을 사용하여 작동합니다.
개발 방법
데이터는 Johns Hopkins repository에서 CSV 형식으로 가져옵니다.
덕분에 Analyzethis 모듈을 통해 클래스, 큐브 및 초기 피벗이 생성되었습니다.
.슈타이어!
가져오기 방법은 @Eduard.Lebedyuk 덕분에 CSVTOCLASS 방법을 사용하여 도입되었습니다!
대시보드는 DeepSee Web (DSW) 모듈로 렌더링됩니다.
IRIS BIartifacts (pivots, dashboards)는 ISC.DEV 모듈에서 내보냈습니다.
IRISAPP> d ##class(dev.code).workdir("/irisdev/app/src") IRISAPP> d ##class(dev.code).export("*.dfi")
The code has been developed using VSCode ObjectScript, thanks .Maslennikov.
Building docker image for development and deployment
All the deployment sits in Dockerfile. With Dockerfile we build an image with data, web apps and modules installed and properly setup and then we deploy the image to GCP Kubernetes.
This Dockerfile is a modified version of this Template Dockerfile which is described very well in this article.
So I will stop only on new parts.
17 COPY data files
here we copy CSV files from data folder to the container
set pfile = "/opt/irisapp/files/covid-"_$tr($zd($h-1),"/","-")_".csv", rc=0 \ do ##class(AnalyzeThis.Generated.covid03162020).Import(,pfile,",", ,1,.rc) \ write "imported records: "_rc \ do ##class(%DeepSee.Utils).%BuildCube("covid03162020") \
This code imports the latest data and builds a cube.
zpm "install dsw" \
Here we install DeepSee Web.
do EnableDeepSee^%SYS.cspServer("/csp/irisapp/") \
This enables IRIS Analytics (DeepSee) for /csp/irisapp web app.
zn "%SYS" \ write "Modify MDX2JSON application security...",! \ set webName = "/mdx2json" \ set webProperties("AutheEnabled") = 64 \ set webProperties("MatchRoles")=":%DB_IRISAPP" \ set sc = ##class(Security.Applications).Modify(webName, .webProperties) \ if sc<1 write $SYSTEM.OBJ.DisplayError(sc)
This code is needed to make the analytics web app be available without credentials.
COPY irisapp.json /usr/irissys/csp/dsw/configs/
And this command helps to set DSW configuration.
Deployment to Kubernetes
The deployment procedure is being processed by Github Actions - and this workflow handles it on every commit to the repository.
Github workflow uses Dockerfile we built on a previous step along with Terraform and Kubernetes settings.
The procedure is identical to the one described in this article by .Khomenko.
How to run and develop it locally
You are very welcome to run, develop and collaborate with this project.
To run it locally using docker do:
Clone/git pull the repo into any local directory
$ git clone https://github.com/intersystems-community/objectscript-docker-template.git
이 디렉토리에서 터미널을 열고 다음을 실행하십시오.
$ docker-compose build
IRIS 컨테이너를 실행합니다.
$ docker-compose up -d
컨테이너가 빌드되고 실행되면 다음에서 애플리케이션을 엽니다.
localhost:yourport/dsw/index.html#!/d/Covid19/Countries.dashboard?ns=IRISAPP
개발 방법
이 리포지토리는 ObjectScript 플러그인을 사용하여 VSCode에서 코딩할 준비가 되었습니다. VSCode , Docker 및 ObjectScript 플러그인을 설치하고 VSCode에서 폴더를 엽니다.
기여하는 방법
포크the repository , 변경하고 풀 요청을 보냅니다.
당신의 기여를 보고 싶습니다!
Reference
이 문제에 관하여(InterSystems IRIS를 사용한 COVID-19 분석), 우리는 이곳에서 더 많은 자료를 발견하고 링크를 클릭하여 보았다 https://dev.to/intersystems/covid-19-analytics-using-intersystems-iris-gej텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
우수한 개발자 콘텐츠 발견에 전념 (Collection and Share based on the CC Protocol.)