logo

NJP

Jelly: Deep Dive Series...

Import · Nov 30, 2011 · article

A few weeks ago, a friend and colleague asked me to do a series of posts on Jelly, because he knew that many people found it quite mystifying — not only how to use it, but even simply what it was.

The first time I ran into Jelly, I didn't have a camera around — but I think my face must have looked something like the fellow at right. I'll let you fill in the internal dialog image

But, in fact, Jelly really isn't that hard to understand. It's definitely different, but truly it's not terribly difficult.

So this is the first post in a series on Jelly, and I'll start from a high-level view and work down into the teensy little details...

What is Jelly, anyway? It's an open source technology (from the Apache Foundation) that the ServiceNow instance uses to render (i.e., produce HTML) web pages. ServiceNow has enhanced standard Jelly to add even more capabilities.

Ok, but what does Jelly actually do? The end product of Jelly is HTML (i.e., the contents of a web page), plain and simple. That's the easy part! Jelly produces HTML by interpreting a Jelly template, which is itself an XML document. Jelly templates have their own very specific set of XML tags and syntax, but they also directly incorporate the HTML tags that will be produced as output. The special Jelly tags do all sorts of handy things, including some things that look a lot like a more conventional programming language, the ability to use data from the ServiceNow instance, ways to execute JavaScript (on either the web browser or the ServiceNow instance), and much more.

[imageThis is shown graphically at right (click to enlarge the diagram). The process works like this, conceptually (don't worry about the details at the moment):

View original source

https://www.servicenow.com/community/in-other-news/jelly-deep-dive-series/ba-p/2267612