Article Sean Connelly · Sep 10, 2019 18m read Creating a OData API Adapter for InterSystems IRIS In this article, we will explore the development of an IRIS client for consuming RESTful API services that have been developed to the OData API standard.We will be exploring a number of built-in IRIS libraries for making HTTP requests, reading and writing to JSON payloads, and seeing how we can use them in combination to build a generic client adaptor for OData. We will also explore the new JSON adapter for deserializing JSON into persistent objects. #REST API #Caché #InterSystems IRIS Open Exchange app 4 3 3 1.1K
Article Sean Connelly · Nov 19, 2018 2m read Language features that you really should know from day 1 Here's a fun test to see how well you know ObjectScript.What will each of the following statements output? #ObjectScript #Caché 7 13 2 1.1K
Article Sean Connelly · May 8, 2018 5m read Roll your own Node.JS to Caché adaptor If your looking to develop a Node.JS to Caché library then you might want to consider using a pure TCP connection with a custom message transport protocol. This bypasses the native Caché connector libraries that can get stale with a new release. Node.JS is very good at non blocking code development, so building a performant solution isn't that complex. #Caché #Node.js 5 0 2 838
Article Sean Connelly · Dec 9, 2017 1m read A List Of Public Caché Projects I've collated a list of public Caché Projects that I've been able to find through GitHub topics and various other searches, let me know if I have missed any and I will add them to the list.The full list is here...https://github.com/SeanConnelly/Public-Cache-Projects/blob/master/README.md #Caché #ObjectScript 6 7 0 842
Article Sean Connelly · Aug 21, 2017 3m read Handling images with Caché & JSON, and why 57 is a magic number If you want to dynamically serve images as a property of JSON then there is no perfect encoding solution. One method used frequently is to Base64 encode the image. Whilst there are some negatives to doing this, such as data inflation, there are some positives to working with Base64 images inside the browser.Let's say you have an image placeholder on a web page... #JSON #Object Data Model #Caché 6 4 1 1.8K
Article Sean Connelly · Aug 21, 2017 2m read Warning: Stale Persistent Objects created by $THIS tl;dr I have discovered that using $THIS in a very specific way will make persistent objects go stale.I found that it only happens when using $get on an array that contains the OID reference of $THIS. I assume that this is an unwanted feature and have raised a WRC. The problem can be recreated following the steps below, I have also posted the workaround that I am currently testing and looks to be working fine.1. Create a persistent class... #Object Data Model #Terminal #Caché 0 7 0 400
Article Sean Connelly · Jun 7, 2017 1m read Cogs.JsonClass 1.0 The Cogs.JsonClass library is now available in the Cogs project on GitHub.https://github.com/SeanConnelly/CogsPlease see the README and the /docs folder on how to use the class.Overview #Caché #JSON #ObjectScript #Release 5 5 0 633
Article Sean Connelly · May 31, 2017 28m read Cogs Library Cogs Library Over the next few months I will be releasing a number of open source libraries and tools to the Caché community. Most of the code has evolved from previous production grade solutions over the years and I am collating it together under a single overarching library package that I am calling Cogs. #JSON #Object Data Model #Caché 17 38 4 1.5K
Article Sean Connelly · May 15, 2017 2m read Security Alerts Wanna CryMost of you should be aware that the Wanna Cry virus is massively infecting un-patched windows machines all around the world. It's particularly affecting the NHS, one of my main clients. Wanna Cry is one of a line of Viruses that exploit SMBv1 over ports 135 and 445.A kill switch has been enabled, but this won't protect machines sitting behind http proxies, and there are already reports of new versions without a kill switch.All windows machines should be isolated and updated a.s.a.p. #Caché #Security 3 1 0 787
Article Sean Connelly · Apr 27, 2017 7m read Level up your XDATA XDATA is used for a whole host of ISC libraries to store things like Zen pages, BPL logic and DTL transformations.XDATA is the equivalent of XML config files of the JAVA world and JSON config files of the JavaScript / NPM world.Whilst Atelier looks to shift source code to the disk, XDATA will remain a key component to source control our projects config / meta data. #Object Data Model #ObjectScript #XML #Caché 3 4 0 1.2K
Article Sean Connelly · Apr 18, 2017 1m read TIP: Beautify XML in two lines of COS If your handling XML then it can often be unformatted for human display.Using a little bit of XSLT magic you can format the XML in just two lines of code... #XML #ObjectScript #Caché 6 1 0 655
Article Sean Connelly · Apr 13, 2017 3m read Compilation gotchas and a request for change On the back of my recent post on writing bug-less code I wanted to raise a few suggestions (to ISC) that would help prevent certain types of bugs at compile time. I've probably missed a few, but these are the main ones in my mind. Please contribute more suggestions.Btw, these also serve as potential gotchas for new COS developers. #Compiler #ObjectScript #Caché 4 24 0 1.1K
Article Sean Connelly · Apr 12, 2017 5m read Bug killing development tips Does anyone NOT use a debugger? I can't remember the last time I did. It's not because I don't dislike them, I just don't need to use them. The main reason for this is because I have a certain development methodology that either produces less bugs, catches them at a unit test level, or makes tracking them down much easier. Here are my tips... 1. Write your own COS cheat-sheet. #Best Practices #Tips & Tricks #Caché 19 17 6 1.6K
Article Sean Connelly · Mar 28, 2017 2m read Map, Reduce and Filter Collections Inspired by the article "Declarative development in Caché" that's still trending on the dev com. The OP explored a functional style of iterating over a collection. A comment today suggested "Caché would need syntax support for anonymous functions". With Macros you can kind of get anonymous like syntax using dot notation. This is not production code, but it does work. First the macros... #Caché #Code Snippet #ObjectScript #Mapping #Tips & Tricks 2 15 0 724