go to post Brett Saviano · Aug 3 @Hannah Sullivan This is documented in the Server Manager's README. It will be added to the official InterSystems documentation for VS Code at a later date.
go to post Brett Saviano · Jul 26 @Kevin Kindschuh The VS Code Integrated Terminal is an OS shell, so if you want to open an IRIS terminal you need to use a command like "iris terminal <instance>". If that instance is on another machine, you'll have to use SSH. Starting with IRIS 2023.2, VS Code supports a WebSocket-based terminal so that you can launch a terminal on a remote server without needing SSH. The WebSocket terminal is not a full terminal though.
go to post Brett Saviano · Jul 13 @Sam Duncan Here's a simple method to export subclasses. It exports all of the classes in a single XML file and prints that to the console. You can easily modify that behavior by changing the $SYSTEM.OBJ.Export() line to whatever export strategy you want. ClassMethod ExportSubclasses(pSuper As %String) As %Status { #Dim tSC As %Status = $$$OK #Dim tEx As %Exception.AbstractException #Dim tPc As %ProcedureContext #Dim tRs As %SQL.ClassQueryResultSet Try { #; Build a subscripted array of subclasses Set tStmt = ##class(%SQL.Statement).%New() Set tSC = tStmt.%PrepareClassQuery("%Dictionary.ClassDefinitionQuery","SubclassOf") If $$$ISERR(tSC) Quit Set tPc = tStmt.%Execute(pSuper) If tPc.%SQLCODE < 0 { Throw ##class(%Exception.SQL).CreateFromSQLCODE(tPc.%SQLCODE,tPc.%Message) } Set tRs = tPc.%NextResult() While tRs.%Next(.tSC) { Set tSubclasses(tRs.%GetData(1)_".CLS") = "" } If $$$ISOK(tSC), $DATA(tSubclasses) = 10 { #; Export the subclasses Set tSC = $SYSTEM.OBJ.Export(.tSubclasses,,"/nodisplay") } } Catch tEx { Set tSC = tEx.AsStatus() } Quit tSC }
go to post Brett Saviano · Mar 9 @Norman W. Freeman This query will return the names of all non-system and non-generated classes in the current namespace: SELECT Name FROM %Library.RoutineMgr_StudioOpenDialog('*.cls',1,1,0,1,0,0) The documentation for this query and its parameters can be found here.
go to post Brett Saviano · Mar 6 The vscode-objectscript extension now contains a snippet for custom class queries. It was added by pull request #1111 and if you want to try this snippet before the next release you can download the beta version of the extension found here.
go to post Brett Saviano · Feb 6 @Scott Roth Please see our documentation page on server-side editing for directions for setting up your workspace.
go to post Brett Saviano · Oct 5, 2022 Maybe try using 'ck' instead of 'cuk'. The 'u' flag is the one that tells the compiler to not recompile if it doesn't detect a code change.
go to post Brett Saviano · Aug 23, 2022 @Scott Roth The custom metrics code needs to be added to the instances of IRIS that SAM is monitoring, not the SAM Manager IRIS instance itself. The full documentation for adding custom metrics can be found here.
go to post Brett Saviano · Aug 19, 2022 I believe this is the same problem described here. You need to add the --check-caps false command to the iris container in your docker-compose.yml file, like this: ... iris: command: --check-caps false init: true ... The SAM 1.1 distribution should have this done for you but that change must not have made it in. I think you can still enter the SAM 2.0 EAP if you'd like to start with the upcoming version.
go to post Brett Saviano · Aug 19, 2022 The logs are stored in the containers themselves. Using docker you can read them using the docker logs command. According to the podman docs, this is what you would need to run: podman logs sam_iris_1
go to post Brett Saviano · Aug 19, 2022 @Scott Roth SAM or Prometheus alone can be installed on a separate server. They just need network access to the IRIS servers that you want to collect metrics from.
go to post Brett Saviano · Jul 27, 2022 @Michael Davidovich Refreshing the explorer only refreshes the nodes in the tree view. If you have a virtual file open that you opened from the explorer it won't auto-update. You can close it and reopen it and the extension should fetch the new copy. If you have your local copy open, you can export again to get the latest version.
go to post Brett Saviano · Jul 27, 2022 @Michael Davidovich As a first step I suggest you read through our online documentation to familiarize yourself with common workflows. The extension supports a client-side workflow where you export files to the currently open local folder and handle the source control yourself. To edit client-side, you can use the ObjectScript Explorer to export files. You can also use the Export Code From Server command, which uses the objectscript.export configuration settings to determine what to export. Our extension does not support VS Code's "Download" menu option. Since the disp class is generated from the spec class you probably don't want to store it in source control but if you still want to export it, you can have the Explorer show generated files before you export a package or if you're using the command you can set the objectscript.export.generatedto true.
go to post Brett Saviano · Apr 15, 2022 @Jonathan Lent Starting in IRIS 2020.1.2, 2021.1.1 and 2021.2 you can directly drill down into objects and see all of their properties during debugging. If a variable is an object, you will see its class name in grey next to it and an arrow to expand it like you would a folder in the VS Code file explorer view. This new feature is shown around timestamp 3:30 in this Learning Services produced video on debugging using VS Code.
go to post Brett Saviano · Apr 6, 2022 @Kari Vatjus-Anttila Can you please download and install the version of the extension found here and check if that fixes the issue? To install it you can drag it from your downloads folder into the extensions view in your VS Code window.
go to post Brett Saviano · Mar 10, 2022 @Peter Steiwer If you're working server-side, you can add the "generated=1" query parameter to your folder URI to see generated files: https://intersystems-community.github.io/vscode-objectscript/serverside/...
go to post Brett Saviano · Feb 8, 2022 @Jeffrey Drumm Sorry, I assumed you were asking this in the context of CI. AFAIK the only way to do this is what I described. If you would like a way to do this using server-side editing, please file an enhancement request issue in the GitHub repo.
go to post Brett Saviano · Feb 8, 2022 @Jeffrey Drumm VS Code isn't a CI/CD tool so it wasn't specifically designed for this but it is doable if you're working client-side. You can export files from one namespace, change the namespace in your settings.json file and then import and compile.
go to post Brett Saviano · Feb 1, 2022 You should install the InterSystems ObjectScript Extension Pack to get full support for ObjectScript in VS Code. The InterSystems Language Server provides formatting support. You can view our documentation here and the Language Server README here.
go to post Brett Saviano · Dec 8, 2021 Before SAM, there was no way to monitor Cache or IRIS using Prometheus out of the box. You had to implement the metrics exporter API yourself or use a community implementation like the one you linked. Since 2020.1, the /api/monitor API is provided by InterSystems out of the box. SAM uses this API to collect metrics and alerts from servers.