New post

Find

Question
· Sep 29, 2024

Response of JSON type

Hi Guys,

I'm using the below simple Get Webservice to return a JSON file, its working but the response is actually of Text type not JSON Type 

ClassMethod cmGetHomes(cnt1, cnt2) As %Status
{    response="{""Land"""_":"_""""_cnt1_""",""Home"""_":"_""""_cnt2_"""}"
 // set dataObj=##class(%DynamicObject).%FromJSON(response.data)
 //set response.data = dataObj
 //W response.%ToJSON()
 //set response.data = {}.%FromJSON(response.data)
 //set response.data = {}.%FromJSON(response.data)
 response
 Quit $$$OK
}

This is the response that I'm getting in Postman

But it says type is text not JSON 

 

Thanks

5 Comments
Discussion (5)1
Log in or sign up to continue
Question
· Sep 29, 2024

Run a routine that was created and compiled with %Routine library

I created and then compiled a routine using the %Routine library 


s routine = ##class(%Routine).%New(fileName_"."_extension)
d routine.Write(parsedRule)
//s status = routine.Save()
s status = routine.SaveStream(,.refresh)
if ($$$ISERR(status)) throw status

Now the routine compiles successfully and as a result it is saved on the database.

I can now use from anywhere:


set r = ##class(%Routine).%New("myGeneratedCode.mac")

w r.SizeGet()

 

and it would output the size.

but for the question: How do i run a method in that file? It is saved on the database and i can't relaly see the path, what class can run this routines methods?

 

EDIT:

I can see the routine saved on ^rMAC("myRoutineName")

how can i run this MAC?

 

2 Comments
Discussion (2)2
Log in or sign up to continue
Article
· Sep 28, 2024 1m read

SMART on FHIR app - Exemplo com exercício com mão na massa / Workshop de Instruções

Baseado num ótimo exemplo e workshop construído por @Luis Angel Pérez Ramos (veja artigos relacionados e o Open Exchange app relacionado), que incluiu um container local InterSystems for Health (e setup desejado), essa amostra apresentada aqui, adaptada do workshop para usar o InterSystems Cloud FHIR Server, e suas definições relacionadas.

O OpenExchange e repositório GitHub relacionados incluíram instruções detalhadas (e prints de tela relacionados) para criar o projeto e fluxo desejados.

Uma série de vídeos curtos também seguem para acompanhar os passos a serem performados.

Basicamente, os passos incluem:

  • Definindo um servidor Cloud FHIR
  • Definindo um servidor OAuth (auth0 por Okta)
    • Criando uma Aplicação
    • Criando uma API
    • Criando um usuário
  • Configurando o Servidor FHIR 
    • Criando um Servidor OAuth 
    • Criando uma Aplicação
  • Adaptando o app (Angular) para apontar para os Servidores FHIR e OAuth
    • Adaptando proxy.config.json
    • Adaptando nginx.conf
    • Adaptando app.module.ts

Aproveite!

Discussion (0)1
Log in or sign up to continue
Question
· Sep 28, 2024

This site can’t be reached - trying out iris-DataViz

I want to try out iris-DataViz app to visualize my own data. I cloned the repo and docker-compose up -d in AWS. IRIS portal works, but on port 8051 I get nothing. I checked my AWS security groups. I reversed IRIS webserver port and 8051 and I can connect to Management portal using port 8051. I don't understand what is refusing connection on port 8051 running in iris-DataViz container.

1 Comment
Discussion (1)1
Log in or sign up to continue
Question
· Sep 27, 2024

Local Ensemble instance clashing with another application's local client

We are doing healthcare interface development.

Developers have Ensemble installed locally on their laptops - code will be developed locally then deployed to integration, test/UAT and ultimately production servers in due course.

One of the other applications we are developing around happens to utilise an Iris desktop client to a remote Iris server. We want to have the application available on the developers laptops alongside the local Ensemble instance.

✅ It appears that if we install their desktop client then install our local Ensemble server, things work.

❌However, if we install a local Ensemble instance then the desktop client, their installation process breaks the local Ensemble instance.

When you do it the correct order the Cache Server Manager shows the local instance, the integration/test/production instances, plus the Iris instance related to the application. When you do it in the "wrong" order Cache Server Manager only shows the Iris instance related to the application. We don't want to have to rely on this ordering - a local Ensemble instance may have multiple namespaces set up, relating to various on-going development we don't want to have to recreate just to install the desktop client for the other application...

We can't figure out where Cache Server Manager stores its list of available instances - filesystem and Registry browsing so far not showing anything obvious!

We are taking it up with the supplier of the application, but in the meantime where might we look to "remind" Cache Server Manager about the local, integration, test and production servers it appears to have "forgotten" about when the application was installed? Developers are on Windows 10 laptops.

3 Comments
Discussion (3)2
Log in or sign up to continue