go to post Timothy Leavitt · Jan 24, 2022 I've updated my original post with a bit of performance analysis as well (couldn't resist) - I'm curious if anyone has ideas for getting an embedded SQL approach even closer to raw global refs. :)
go to post Timothy Leavitt · Jan 24, 2022 Just had time to do a more detailed writeup here: https://community.intersystems.com/post/listing-all-properties-class-and...
go to post Timothy Leavitt · Jan 21, 2022 I'd run a query against %Dictionary.CompiledProperty where parent = (the classname)
go to post Timothy Leavitt · Jan 21, 2022 I'm not aware of any JSON schema capability. %Dictionary has two sets of classes: *Definition and Compiled*. If you want to see inherited members you need to look at Compiled* (e.g., CompiledClass / CompiledProperty). If you want to know from which class, there's an "Origin" property.
go to post Timothy Leavitt · Jan 20, 2022 Per message from @Stefan Cronje the issue was a missing coverage.list. I've filed https://github.com/intersystems/TestCoverage/issues/11 to cover an enhancement to fail early and descriptively in this case rather than just doing nothing.
go to post Timothy Leavitt · Jan 19, 2022 It's also possible that %objlasterror is leaking without that error being the root cause of any issues. I'd start by looking at how you're saying which units of code to measure coverage for - e.g., via coverage.list or an explicit list passed in to the CoverageClasses/CoverageRoutines parameter as described at https://github.com/intersystems/TestCoverage
go to post Timothy Leavitt · Jan 19, 2022 @Stefan Cronje I've sent you a message. The discussion at https://github.com/intersystems/TestCoverage/issues/10 is relevant but I think your root cause may be different.Basic troubleshooting steps / things to think about:* Is the line-by-line monitor running? (do ^%SYS.MONLBL and see what it says)* Do you have .int code for the classes for which you're measuring coverage? (compile with the "k" flag to keep this around)* Did you say what classes/routines you wanted to measure coverage of? (see instructions at https://github.com/intersystems/TestCoverage) Given that two people have run into this now I think there's something that should be changed to help avoid the situation. Perhaps forcing the line-by-line monitor/PERFMON to stop (if it's running) prior to starting it for a test coverage run and/or identifying possible causes of the issue.
go to post Timothy Leavitt · Jan 13, 2022 Right - at this point I'd say set Server to apisidra.ibge.gov.br instead of api.sidra.ibge.gov.br and see if that fixes it.
go to post Timothy Leavitt · Jan 11, 2022 It looks like there might be an issue with the service you're trying to use - at https://apisidra.ibge.gov.br/ , pasting in "/t/1612/n2/all/v/all/p/last/c81/2702/f/u" as "Parâmetros/valores da API:" then clicking "Consultar" I get an alert saying "A solicitação de conexão com pools sofreu timeout". I also see this from ObjectScript with Server set to apisidra.ibge.gov.br instead of api.sidra.ibge.gov.br
go to post Timothy Leavitt · Jan 11, 2022 I'd recommend looking at what (other than valid JSON) is in result.HttpResponse.Data. Also worth looking at result.HttpResponse.StatusCode - is it 400 or 404?
go to post Timothy Leavitt · Dec 15, 2021 This is awesome!! Clarifying question - re: "special tables that only support row-based sampling", would this be tables with custom/non-default storage definitions?
go to post Timothy Leavitt · Dec 14, 2021 Thanks - simple example is: do ##class(%SQL.Statement).%ExecDirect(,"select top 10 'foo'").%DisplayFormatted("CSV",,,.filesUsed) do ##class(%Stream.FileCharacter).%OpenId(filesUsed(1)).OutputToDevice()
go to post Timothy Leavitt · Dec 13, 2021 @Steve Pisani I like the idea of this being configurable. You might want to chime in at https://github.com/intersystems/git-source-control/discussions/78 with your view on how this should work.
go to post Timothy Leavitt · Dec 8, 2021 Note, this also assumes default global names - if you have customized these, you'll want to just get all globals. Also, replace 'C:\InterSystems\IRIS20\mgr\user' with the appropriate database directory for your instance.
go to post Timothy Leavitt · Dec 8, 2021 Here's a full example relating global size back to related classes/tables, expanding on @Vitaliy.Serdtsev's example: select sdef.parent "Class", class.SqlSchemaName||'.'||class.SqlTableName "Table", LIST(sdef.Location) "Globals", SUM(s."Allocated MB") "Allocated MB", SUM(s."Used MB") "Used MB" from %SYS.GlobalQuery_Size('C:\InterSystems\IRIS20\mgr\user','','*D,*S,*I',0,0,1) s join ( select parent,DataLocation as Location from %Dictionary.StorageDefinition where not parent %STARTSWITH '%' union all select parent,StreamLocation from %Dictionary.StorageDefinition where not parent %STARTSWITH '%' union all select parent,IndexLocation from %Dictionary.StorageDefinition where not parent %STARTSWITH '%' ) sdef on sdef.Location = '^'||s.Name join %Dictionary.CompiledClass class on class.Name = sdef.parent group by sdef.parent Note that if you use inheritance with persistent classes sharing an extent this'll be a little bit off (since the same global is used for multiple classes and will be double counted).
go to post Timothy Leavitt · Dec 2, 2021 I feel like a broken record, but InterSystems Support is pretty awesome and probably a better place to start for deeper HealthShare issues than the Developer Community. (And at first glance this seems like a deeper HealthShare issue.) Though it would be great if you could circle back and say what the solution was once you have one in case someone else runs into this!
go to post Timothy Leavitt · Dec 1, 2021 Clarifying: I really enjoy the coding challenges and would highly recommend them, but competing for a top spot is a level of intensity beyond what I'd do. (Even if I wasn't an InterSystems employee and was eligible for prizes other than clout. )
go to post Timothy Leavitt · Dec 1, 2021 Just installed Docker on my machine for the first time (had just used it for GitHub Actions/Travis CI before). I feel a little bit like an old dog trying to learn new tricks... AOC 2021 is a good excuse for it!