Service

Polarion Scripting & Custom Development

Polarion scripting extends what configuration alone can do. Corbinsoft writes Polarion Velocity scripts for LiveReports and LiveDoc widgets, Polarion workflow scripts for conditions and functions, save hooks, GraalJS and Groovy automation, and Java extensions, each one documented and tested for use in regulated environments.

Velocity Workflow Scripts GraalJS Groovy Java REST API
Talk to a Polarion Developer
VELOCITY GRAALJS GROOVY JAVA 1 2 3 4 5 6 7 ## Requirements table #foreach($wi in $requirements) <tr> <td>$wi.getId()</td> <td>$wi.getTitle()</td> </tr> #end LIVEREPORT WIDGET RENDER.VM

Where configuration ends,
scripting takes over.

Polarion covers a great deal through its administration screens: custom fields, workflows, link roles, document templates and queries. Regulated teams usually need a little more. A report that shows exactly what an auditor asked for. A workflow that blocks approval until every linked test has passed. A nightly job that flags risk items nobody has reviewed since the last design change.

Custom code in a validated system also has to be maintainable. Every script we deliver is version-controlled, reviewed, tested on a staging server and documented, so your administrators and your validation team know what it does and why.

Reports assembled by hand

Traceability and status reports built in spreadsheets go out of date as soon as they are exported.

Rules enforced by memory

Approval rules that live in procedures and not in workflows depend on every user remembering them.

Script engine changes

Nashorn was removed from the JDK in Java 15. Older Polarion scripts written for it often need changes to run on GraalJS.

Undocumented customizations

Scripts without source control or documentation become a risk at every upgrade and every audit.

Polarion scripting and development services

From a single report widget to a packaged Java extension, we pick the lightest technology that meets the requirement.

Velocity LiveReports & Widgets

Polarion Velocity scripts drive custom LiveReport pages and widgets for LiveReports and LiveDocs: traceability matrices, coverage and status tables, release readiness views and document comparisons. We build widgets with parameters, so report authors can reuse them across projects without editing code.

Velocity widget tutorial →

Workflow Conditions & Functions

Polarion workflow scripts enforce your process at each status transition. Conditions block a transition until rules are met, such as required fields, approved parent items or passed linked tests. Functions act when a transition happens, setting fields, creating linked items or recording approval data.

Workflow scripts tutorial →

Save Hooks

Save hooks check or adjust a work item every time it is saved, whatever its workflow status. We use them for field consistency checks, derived values and data-quality rules that must hold at all times. Our upcoming Java 21 Save Hook packages this pattern as a reusable starting point.

Java 21 Save Hook →

GraalJS Scripting & Nashorn Migration

Current Polarion JavaScript runs on GraalJS. We write new scripts in modern JavaScript and migrate older scripts written for Nashorn, replacing patterns GraalJS handles differently, such as access to Java classes through fully qualified names, which becomes Java.type(). Each migrated script is retested before use.

  • Script inventory and compatibility review
  • Rewrites tested on a staging server

Groovy Scheduled Jobs

Groovy scripts on the Polarion scheduler handle recurring work: nightly consistency checks, bulk field updates, report generation and housekeeping. We write jobs to be safe to re-run and to log what they changed, so every automated update leaves a record.

  • Consistency and data-quality checks
  • Bulk updates with change logs

Java Extensions & REST API

For larger needs we build Java extensions on the Polarion SDK, such as custom workflow functions, servlets and widgets, and integrations on the Polarion REST API for CI/CD pipelines, test tools and in-house systems. Our in-house Redline Report Widget is one example of a Polarion add-on we build and maintain.

Redline Report Widget →

How we build Polarion scripts for regulated use

The same practices apply to a twenty-line workflow condition and to a full Java extension.

GIT
Source controlEvery script and extension lives in a Git repository with a reviewed history of changes.
STAGING
Staging firstDevelopment and testing happen on a staging server with a copy of your configuration, never directly in production.
TESTS
Test evidenceScripts ship with test cases and recorded results that your validation team can reuse in OQ-style testing.
SPEC
DocumentationEach customization has a short specification covering purpose, trigger, inputs, outputs and failure behavior.
UPGRADES
Upgrade checksWe review scripts against new Polarion releases and API changes before you upgrade.
HANDOVER
Knowledge transferYour administrators get walkthroughs, and our developer course teaches your team to maintain the code.
Polarion training →

Polarion scripting questions

What is a Polarion Velocity script?

Velocity is the Apache template language Polarion uses for LiveReport pages and widgets. A Polarion Velocity script queries work items, documents and baselines through the Polarion API and renders the result as HTML tables, charts or text inside a report or LiveDoc.

What is the difference between a workflow condition and a workflow function?

A condition decides whether a status transition is allowed. If it fails, the transition is blocked and the user sees a message. A function runs when the transition happens and performs an action, such as setting a field, creating a linked work item or recording a date. Polarion workflow scripts can implement either one.

Our workflow scripts were written for Nashorn. Do they need to change?

Often, yes. Nashorn was removed from the JDK in Java 15, and GraalJS handles some Java interoperability differently, for example by requiring Java.type() to access Java classes. We review existing scripts, update the incompatible parts and test them on a staging server before your upgrade.

Should we use a script or a Java extension?

Scripts suit focused rules and reports that administrators may want to read and adjust. Java extensions suit larger features, heavier processing and code that benefits from compile-time checks and unit tests. We recommend an approach for each requirement and explain the trade-offs.

How do you keep custom code compatible with validation?

Every customization has a specification, a source control history, test cases and recorded results. Changes go through your change control process, and the test evidence can be reused in your validation protocols.

Need a script, a report
or an extension?

Describe the rule or report you need. Our developers will review your configuration and propose an approach.

Request a Consultation