The Importance of Reproducers
So you think you've found a bug. What next? Create a support ticket, right? Wrong!
So you think you've found a bug. What next? Create a support ticket, right? Wrong!
At Engage 2022 Volt MX Go was announced including features like Volt Formula, a JavaScript-based fusion of Notes formula syntax and Open Formula, and VoltScript, a derivative from LotusScript, and inspired by many modern implementations of BASIC, which will run in Foundry, Volt MX Go's middleware layer. Already at Engage we demonstrated live running code of VoltScript with Try/Catch/Finally, an alternative declaration keyword "Def" for "Dim" and deprecation of GoSub; which let’s be honest is Satan’s spawn. These are the first changes to the core LotusScript language keywords in over 30 years. In addition, we showed live demos of code running triggered from Foundry as well as standalone VoltScript outside of HCL Notes or Domino, for the first time since the end of life of Lotus 1-2-3. We also showed a number of new extensions (LSXs / VSXs) that will obviously be required, as well as developer productivity tooling like unit testing, mocking and a POC of dependency management.
LotusScript agent profiling is not new, but there are still some developers who are not aware of it. It's something I blogged about more than ten years ago. At that time talking about the relative performance of specific API calls, in that case the relative performance of checking .count was greater than zero vs getting the first entry and checking if it was nothing. On other occasions it's also identified mistakes in my code, because it demonstrated more API calls than I expected or needed.
But sometimes it's not a single API call that affects performance, sometimes it's a combination. That's the scenario I came across recently.
Docker has been a significant development tool for me for some time. The ease of spinning up a clean, standalone development environment for applications is a great benefit. The ability to switch seamlessly between different versions is a big benefit when testing. Another benefit is the ability to create demo environments for conference sessions and share them via GitHub for others to easily deploy samples.
But when Docker announced new licensing terms last year, it shook up the desktop development landscape. Rancher, who have a long history of expertise with Kubernetes, stepped into the desktop game by announcing Rancher Desktop. I was aware of the open source project last year, but when Daniel Nashed pointed out to me that 1.0 had recently been released, I decided it was time to give it a try.
Whether it's Docker or Kubernetes (or some flavour thereof), running microservices in containers is a powerful option. It can make it easy to deploy development or test systems, ensuring consistency across your development team. But when you move from consuming to building, particularly when you're building less out-of-the-box containers, there are some deeper elements that you need to be aware of.
Three years ago I presented at IBM Think I presented a session called Domino and JavaScript Development Masterclass with John Jardin. In that session I talked about the various REST options for Domino and used the term "API gateway". Particularly at this time it makes sense to expand more on what was in the slides.
How can you get a "Type Mismatch" error in a Forall loop in LotusScript?
This was the question a few of us hit with a recent bit of coding. You can't declare the forall variable, and if you're iterating over a variant containing only strings, surely this shouldn't happen. The loop was quite basic:
Over the weekend we lost another long-standing member of the Domino community, Nathan T Freeman. Nathan was outgoing, often controversial, but passionate about open source and helping others. Everyone who met him will have stories about him. But I know he is one of the individuals I have to thank for being where I am today.
In my last blog post I talked about challenges we had to overcome as a team with regard to caching of constants. But a bigger challenge we hit was caching of design elements.
Part of the solution we built required copying design elements from one database to another. Part of the beauty of Domino is that everything is a Note - including design elements. Design elements are just Notes with a special flag. So just as you can copy a document from one database to another by getting a handle on the note, you can also copy a design element from one database to another by getting a handle on the design note. The API is exactly the same - Call NotesDocument.copyToDatabase(targetDb).
Recently I've been involved in a project with a lot of LotusScript. As a team our approach has been to structure the code according to best practices and leveraging what we've learned from other languages. Standards are always good, but there are always peculiarities that impact what you do. The crucial skill is to be able to work out what is happening when the standard ways don't produce expected results. And most importantly, work out how to work around them.