357 Lotus blogs updated hourly. Who will post next? Home | Downloads | Events | Pods | Blogs | Search | myPL | About 
 
Latest 7 Posts
Quick Tip: Use Dojo Content Panes for Speedier Initial Page Loads
Mon, Aug 18th 2014 73
My Sessions at MWLUG This Year
Mon, Aug 18th 2014 69
Domino SSL and Reverse Proxies
Mon, Aug 18th 2014 185
Quicker Tip: Lowering XPage Build Overhead When Using Jars
Thu, Aug 14th 2014 129
Be a Better Programmer, Part 4
Thu, Aug 14th 2014 174
Quick Tip: facetName-less Callbacks in XPages
Wed, Aug 13th 2014 129
How I Learned to Stop Worrying and Love C Structs
Mon, Aug 4th 2014 152
Top 10
"Build Automatically", "Refresh automatically", and "Team Development"
Thu, Jan 23rd 2014 436
So it goes.
Mon, May 12th 2014 409
An XPage As A Tree: Implications
Wed, Apr 16th 2014 387
The Trouble With Developing on Domino
Tue, Jul 8th 2014 382
SNTT: Reconstructing DateRanges
Thu, Feb 27th 2014 381
My Current Model Framework, Part 2: An Example
Fri, Feb 21st 2014 361
Couchbase StateManager for XPages, Part 2
Fri, Feb 21st 2014 345
Be a Better Programmer, Part 1
Thu, May 15th 2014 339
Swift
Wed, Jun 4th 2014 311
Better Living Through Reverse Proxies
Thu, May 30th 2013 309


Moving From Ruby-in-XPages to Polyglot
Jesse Gallagher    

I've tweeted about this a couple times, but in some of my spare time lately I've put together a new, cleaner implementation of the generic-scripting-language support I first created back when I did my original work with Ruby. I named the new project "Polyglot" and it has two facets: The aforementioned generic-scripting-language support, done more cleanly and with better capabilities. A method for storing standalone page-generating scripts as documents in the database that are executed in the context of an XPage. Generic Scripting Languages With the usual when-I-get-around-to-it caveat, I plan to use Polyglot to entirely supplant Ruby-in-XPages, since its JSR-223-based features cover JRuby as well. The main thing I need to check on is proper memory usage - the embedding mechanism I originally used provides clear control over the lifetime of the scripting runtime, while JSR 223 does not. That may be fine, since it may properly manage itself, but it makes me a bit nervous. I'll also have to work out proper context variable access (e.g. "database", "currentDocument", etc.). Some languages (Ruby, namely) seem to have gained a magic power since last I checked to access those variables without having to add special support, but I need to figure out if others work the same way or if I need to try an idea for an adapter I had. In addition to the JSR 223 languages, I also just today added support for formula language via #{formula: ... } bindings, since I realized that that was exceedingly easy to do. For that one, I didn't bother binding it to the contextual variables, but instead just have it look for "currentDocument" - if it's present, it passes the lotus.domino.Document from that to the session.evaluate(...) call; if it's not, it forgoes the second parameter. I don't expect I'll use that binding much, but it was fun to add. Standalone Scripts The standalone script support is a little different - the idea is that, rather than working another language into an XPage, you write a script entirely in the other language, much like you might do with, say, PHP (don't use PHP). You can write a script using a basic editor, it's stored in a document in the database, and then you can execute it in the context of a ScriptRunner XPage, meaning you have the same Java environment as usual (with the same caveat as above that I need to sort out variable access). Besides the usual suite of JSR 223 languages, I've also started working on integrating the XSP parser from the XPages Bazaar, both as a way to familiarize myself with the Bazaar and to see if there's any use in a setup where your XSP markup is stored in documents and evaluated at runtime rather than design elements compiled in Designer. Maybe, maybe not, but it's a fun test.   For now, it's still in an "experimental" state, but eventually I hope to cobble it into a proper releasable state and have it supersede Ruby-in-XPages entirely.

---------------------
http://frostillic.us/f.nsf/posts/7BBB53FE9AA1613285257AD2006CB78C
Dec 12, 2012
98 hits



Recent Blog Posts
73


Quick Tip: Use Dojo Content Panes for Speedier Initial Page Loads
Mon, Aug 18th 2014 5:13p   Jesse Gallagher
The XPages Extension Library is full of hidden gems and one I particularly like keeping in my back pocket is the control. It's a fairly unassuming control; like the rest of the components in the "Dojo Layout" category, it takes its name and basic concept from the underlying Dijit. However, you don't have to use it in a full Dojo layout - and, in fact, all of the actual layout types have more-appropriate XSP components. Presumably, its initial use is to load content from a specified UR [read] Keywords: xpages database dojo javascript network properties
69


My Sessions at MWLUG This Year
Mon, Aug 18th 2014 1:13p   Jesse Gallagher
As I mentioned at the end of this morning's post about SSL and reverse proxies, I'm going to be giving a session on using a reverse proxy in front of Domino at this year's MWLUG next week. Specifically, it will be one of two sessions, both on Friday: OS101: Load Balancing, Failover, and More With nginx I'll be discussing the general reasons why you would use a reverse proxy - not just the aforementioned SSL benefit, but also load balancing, failover, multi-app integration, new feature [read] Keywords: domino xpages integration server
185


Domino SSL and Reverse Proxies
Mon, Aug 18th 2014 7:12a   Jesse Gallagher
Domino's SSL stack has been long-in-the-tooth and awkward to deal with for a while. Until recently, this has mostly just resulted in the sort of stilted way you have to set up SSL keychains, using the Server Certificate Admin database initially and then "IKeyMan" more and more (specifically, an old version you need 32-bit Windows XP for, like a barbarian), but the job eventually got done. However, as a post from Steve Pitcher points out, this is becoming rapidly impractical. While I gen [read] Keywords: admin domino ibm database development server smtp websphere
129


Quicker Tip: Lowering XPage Build Overhead When Using Jars
Thu, Aug 14th 2014 1:13p   Jesse Gallagher
(Caveat: I don't actually know if this matters with the Jar design element in 9.0+, since the only times I've needed it are with clients using obsolete versions) If you use Jar files stored in an NSF in your build path with XPages apps, you've likely noticed that it makes your build times interminable, particularly if it's a large library. From what I can tell, Designer seems convinced that it must download the entire Jar file during every build, in order to find out what's inside of [read] Keywords: xpages archive eclipse
174


Be a Better Programmer, Part 4
Thu, Aug 14th 2014 7:12a   Jesse Gallagher
This topic isn't, strictly speaking, in the same vein as the rest of this series; instead, it's more of a meandering "case study" sort of thing. But it has something of a unifying theme, if you'll bear with me: Be Mindful of Your Layer of Abstraction Basically everything about computers has to do with layers of abstraction, but what I have in mind at the moment is how it interacts with web programming. First, I'll dive into a bit of background. The original premise of HTML was that [read] Keywords: domino xpages best practice css desktop development java javascript properties server widgets
129


Quick Tip: facetName-less Callbacks in XPages
Wed, Aug 13th 2014 5:12p   Jesse Gallagher
When you're setting up a Custom Control, you likely know by now that you can set up callback areas to add content to a specified place inside your CC content when it's rendered. They typically look something like this: Content Above Content Below You then drop content in there like so in your XPage: That works fine. However, you can benefit greatly by learning that both properties of the callback are optional. Leaving off the id isn't particularly interesting, [read] Keywords: ibm xpages properties xml
152


How I Learned to Stop Worrying and Love C Structs
Mon, Aug 4th 2014 8:12p   Jesse Gallagher
Since a large amount of on-site client time has put my framework work on hold for a bit, I figured I'd continue my dalliance in the world of raw item data. Specifically, what I've been doing is filling out the collection of structs with Java wrappers, particularly in the "cd" subpackage. For someone like me who has only done bits and pieces of C over the years, this is a fruitful experience, particularly since I'm dealing with just the core concept of the Notes API data structures wit [read] Keywords: domino dxl ibm notes rich text rich-text bug css java
246


Delving Into NSF Raw Item Data
Tue, Jul 29th 2014 11:12a   Jesse Gallagher
For the Design package of the OpenNTF Domino API, one of my goals was to add the ability to access the supporting structures around XPages: file resources, images, CSS, and, crucially, Java classes and the XPages themselves. My weapon of choice for the whole API is DXL, and this covered the job nicely for most of those aspects. DXL has clean representations for the first three in the list: specialized XML formats containing the pertinent metadata and a single BASE64-encoded block of the ac [read] Keywords: agent domino dxl lotus lotusscript notes rich text xpages css java leak openntf xml
144


Building an App with the frostillic.us Framework, Part 6
Wed, Jul 23rd 2014 12:12p   Jesse Gallagher
Define the data model Create the view and add it to an XPage Create the editing page Add validation and translation to the model Add notification to the model Add sorting to the view Basic servlet REST with Angular.js Add sorting to the view This step in the framework example is very similar to the second in that there's nothing particularly Framework-y about it. Technically, the work in the title of this step is already done: I had already enabled click-to-sort and set sortable="true" i [read] Keywords: notes xpages java




202


The Industry's Vileness
Tue, Jul 22nd 2014 9:13p   Jesse Gallagher
Fair warning: this post isn't technical. It's also full of sweeping generalities. When I attended middle and high school, it was as part of the last group of geeks and nerds that should face systemic ostracization. Naturally, high school will still be terrible for most people, just because it's full of high schoolers, but the world at large has seen a near-complete triumph for geeks and nerds generally. And this has had some very positive side effects: because we had to deal with exclu [read] Keywords: community development




Created and Maintained by Yancy Lent - About - Blog Submission - Suggestions - Change Log - Blog Widget - Advertising - Mobile Edition