Archives for Jeff Turner

Auto-linking interesting text in support cases

A lot of technical support work is basically pattern-matching, and memorizing. You see a stacktrace, remember vaguely having seen it before, and hunt around until you find the earlier case. Here is a typical example, with MySQL breaking with a weird "Data too long for column" error: To automate the process of "remembering and looking up" stuff like this, I have hacked together a greasemonkey script, supportlink.user.js, that highlights and links any text that matches a set of patterns. With this

Continue reading »

JIRA Spam update: blacklists, SQL, utilities

For those of you maintaining a public JIRA instance, who are suffering from the recent bout of comment spam.. I've created a Confluence space for collaboration on solutions to this, as well as a Subversion repository for utilities: http://svn.atlassian.com/svn/public/contrib/jira/spamfighting/ Currently this contains: Shell scripts for detecting comment or trackback spam as it happens, and notifying someone. These are intended to be run from a cron job. SQL variants for PostgreSQL and MySQL are

Continue reading »

XSLT using too much memory? Try STX

The JIRA data anonymizer is a little tool which uses XSLT to anonymize potentially sensitive text in XML backups. Unfortunately it uses up lots of memory, as XSLT works on a DOM tree and so has to load the whole XML document into memory. We are solving this properly in 3.7 with a built-in anonymizer, but since a customer needed a solution now, I rewrote the anonymizer in STX, an XSLT-like language that is built on a streaming parser (SAX I imagine) instead of DOM. The STX template looks like this: <?xml

Continue reading »