Keywords

1 Introduction

Renew is a continuously developed extensible modeling and execution environment for Petri nets with various formalisms and other modeling techniques. The main formalism of Renew is the Reference net formalism [10], which combines the concept of nets-within-nets [15] with a reference semantics and the expressive power of object-oriented programming in the form of Java. Reference nets in Renew can handle Java objects as tokens and Java expressions in transition inscriptions to execute Java code during the simulation. With the nets-within-nets concept, it is possible to build dynamic hierarchies of arbitrary height. Multiple nets can communicate using synchronous channels, which enable the bidirectional exchange of information. The formalism is, thus, well-suited for the implementation of concurrent software systems. Renew is written in Java and is available for multiple platforms (including Windows, Linux and Mac). An experimental version of the simulator for Android exists. The current version 2.5 is available for downloadFootnote 1 free of charge including the source code [11].

This contribution presents the Renew environment with its objectives and history (Sect. 2), a selection of features and improvements over the recent years of continuous development (Sect. 3) and a brief overview of the plugin architecture (Sect. 4). The paper is summarized in Sect. 5.

2 Objectives

Up to today the objectives of the Renew tool and its various plugins have been widely extended. The following section gives a brief summary of the evolution of Renew over the past recent years. This section is followed by some information about current research topics in the context of Renew development.

Fig. 1.
figure 1

Renew 1.0 GUI, Debian 8/Java 7 together with a four seasons example (pattern and instance) featuring a simple Java inscription.

2.1 History

The first official version of Renew was released in 1999. Since then it has continuously been developed as a Petri net IDE by the TGI GroupFootnote 2. Figure 1 shows the user interface of the first release of Renew, which offers the drawing of Petri net models and the starting and stopping of the simulation. Although other formalisms than Reference nets are available, the user interface offers no means of control to switch compilers.

The continuous development resulted in many improvements and bugfixes as well as feature enhancements. One major task has been the decoupling of editor and simulator, which started with the introduction of the separation layer in Renew 1.6. The plugin system, introduced with the major release 2.0 in 2004 [12], enabled the extension of Renew into various directions. Renew was extensively applied and extended to perform agent-oriented software engineering (see following sections) and was furthermore utilized to provide a workflow management engine and clients. Besides using Renew primarily for modeling Petri nets, plugins provide support for various modeling techniques, e.g. diagrams from UML or BPMN. Over the years Renew evolved increasingly more into an IDE for software engineering with high-level Petri nets.

2.2 Implementing Petri Net-Based Applications

One main focus of Renew is the execution/simulation of Reference nets. With the full support of that formalism, Renew serves as an execution engine for net-based Java applications. Figure 2 shows a simple example net that uses Java objects, which could be part of a graphical application. In the net a frame and a button are created concurrently. After that the button is added to the frame and the frame is resized (again concurrently). When these two steps are finished the frame is displayed and in a next step disposed. This simple example gives a first impression on how to implement Petri net-based applications. With the possibility to structure multiple nets using the nets-within-nets concept, it is possible to implement even complex software systems (e.g. with the Paose approach, see Sect. 2.3).

Fig. 2.
figure 2

Example net using Java objects.

2.3 Petri Net-Based, Agent-Oriented Software Engineering

The Petri Net-Based agent-oriented software engineering (Paose, [2]) is an approach to software development with an emphasis on distribution and concurrency. With the Mulan framework (multi-agent nets, [14]) Reference nets are applied as implementation artifacts for the development of multi-agent applications (MAA). To this end Renew serves as an IDE for the development of MAA by providing the editing, debugging and simulation facilities. With its support for abstract modeling languages and the use of generative techniques to translate them into Reference nets Renew supports the Paose development process in every single step from requirements engineering to system execution. Renew is applied in the context of Paose as a tool for teaching and research in the field of agent-oriented software engineering.

Fig. 3.
figure 3

Renew 2.5 execution of a multi-agent system.

Figure 3 shows the current version of the Renew GUI together with several views on the system provided by various tools. The whole structure of the simulated Paose system can be inspected and navigated with the MulanViewer [3], displayed beneath the main GUI. In the structure tree the developers may inspect the agents with their sub-components. In the image the transformation decision component (DC) of the WebGateway agent is selected and details about this artifact can be inspected in the detail view (to the right of the structure tree, partly hidden). In the center/lower part a fraction of the artifact itself – the transformation DC – is displayed featuring one selected transition (ARM – asynchronous request message) and a marked place (REQ). The simulation has been halted for inspection after the transition ARM has fired through a preset local simulation breakpoint. This transition was involved in the firing step 1956 as can be inspected in the simulation log window depicted in the right. The selection of the transition in the Petri net has been done from the simulation log by using the context menu, which has been activated again for the presentation. The single token depicted as 1 on the place REQ can be inspected either by changing the representation directly in the net instance to a token bag view showing the string representation of the object or through a UML-like deep inspection of the object shown in the window located in the lower left corner of the screenshot. The token is a WebMessge, which contains the login data of a user that has clicked on the login button in the Web interface shown in the upper right corner of the screenshot. The deep inspection window is provided by the Feature Structure plugin.

Several implementations based on Mulan are available on the Paose Web pageFootnote 3. These include some demos, a distributed implementation of a multi-player game, and an export and diffing Web service for Renew-compatible diagrams. The latter is presented through a stand-alone Web interface as well as integrated into the Redmine project management environment.

2.4 PAOSE Meta-Modeling

During its evolution over the years Renew’s capabilities for providing modeling support were extended beyond the initial focus on Petri nets. A great number of the additional modeling techniques are applied within the Paose approach. As mentioned in the previous section Renew supports each step of the Paose development process from requirements engineering, over system design and specification to implementation and execution with appropriate modeling techniques [2]: we use Concept Diagrams to model agent ontologies, Use-Case Diagrams to capture the overall structure and a variant of Sequence Diagrams to model agent behavior in conversations. The latter are used to generate Reference nets, which can be executed as protocols in agent interactions. With the plugin from Haustermann [8], BPMN models can also be applied for this purpose. In our current research we are working on the Renew Modeling and Transformation framework (RMT [13]), a framework for model-driven development of domain specific modeling languages and tools based on Renew.

3 Highlights and Improvements

Renew offers a wide range of features for the creation, the editing and manipulation of models as well as for execution, debugging and deployment of the designed systems. We present a selection that – to our opinion – describes best the nature of the tool set. Although many of the presented features can not be put into one category we present the highlights as functional feature, as usability feature or as IDE related feature.

3.1 Functional Features

Multiple Formalisms. The simulator is capable of handling different formalisms. The main formalism is the Java Reference net formalism, for which different extensions exist, such as inhibitor, reset and timed arcs. The workflow net formalism, provided by an optional plugin, adds a task transition, which can be canceled during execution, so that its effect on the net can be reverted. Other formalisms provide simulation of P/T nets, feature structure nets and bool nets. Simulation is available in different modes. In the interactive simulation mode the user may control the simulation by choosing the transitions to fire and inspect each single step. The automatic simulation mode is usable for system execution and can be run with and without graphical feedback (operation as server).

Net Loading and Class Loading. Renew features dynamic loading of nets on demand from the netpath or from the GUI. Nets may be available in the Renew editor’s format (rnw), which permits direct inspection, or as pre-compiled net system without graphical information (shadow net system), which allows a silent execution. The configurable class reinit mode allows to quickly develop models that combine nets and Java classes. Classes that are recompiled are reloaded at simulation start, allowing nets and Java classes to be quickly developed, tested and debugged without any restart of the environment.

Logging and Remote Monitoring. Logging in Renew is provided through log4j. It is configurable and allows to log tool behavior and simulation events. Several plugins, which provide general or special purpose monitoring facilities may also be used for the inspection of local or remote simulations.

Graphical Editor. Renew provides an easy to use graphical editor for Petri net models and other types of models and a simulation engine, which is seamlessly integrated into this editor. It has a plugin architecture, which makes it easily extensible. The core plugins are provided as part of the Renew distribution. Many advanced features are supplied as optional plugins.

FreeHep Graphical Export. Since version 2.2 the graphical export relies on the FreeHepFootnote 4 libraries, which provide a wider range of formats including SVG and a high quality of output.

3.2 Usability Features

Drag & Drop. Drag and drop support for Renew and the navigator eases the usability by providing means to opening files or project folders directly within the editor’s GUI. Additionally, images can now be added to a drawing by dropping them on the canvas.

Interaction Enhancements. The quick-draw mode has been improved to even faster draw Petri net models. Also configurable shortcuts for drawing tools and layout manipulation are available in order to combine tool selection by keyboard and positioning of net elements by the mouse.

Several drawing elements react to modifier keys during direct manipulation, so that ratios of height and width can be preserved or unified. This is for example useful when re-sizing an image.

Target Text Tool. The target text tool allows to add hyperlinks to graphical elements of a model. By this means models may be inter-linked, in order to offer simplified navigation between related models. Additionally, the usual schemes are supported through the desktop integration as well, allowing to link to Web pages (e.g. documentation/wikis) or other source code.

3.3 IDE Features

The editor has been improved over the last years and received many small usability enhancements and has evolved into an integrated development environment (IDE) for net-based software development. It contains a syntax check during editing and debugging tools, such as breakpoints or manual transitions. Furthermore the editor features desktop integration, a file navigator and image export to various formats.

Fig. 4.
figure 4

Renew Editor GUI featuring the navigator and the quick-fix functionality.

Net/Diagram Diff. The net diff feature – for the first time presented in 2008 – has been added as ImageNetDiff [5, 6] plugin to the optional plugins in version 2.3 and has been further enhanced for effectiveness and efficiency. It provides the functionality of diffing Petri net models and other diagrams directly within Renew or as a Web serviceFootnote 5, which is used and integrated to offer this for the integrated project-management environment Redmine [1].

Quick-Fix. Syntax error notification dialogues are now enhanced to suggest possible solutions to the syntax errors, such as available methods, fields or constructors. The user can interactively choose from the provided solutions and apply the changes to the model in a quick-fix manner. Also undeclared variables are semi-automatically added to the declaration node. In Fig. 4 the variable net (compare with the declaration node) is not yet declared, which results in a syntax exception. The exception presents several solutions, of which the first one is currently selected. By clicking on the apply button (or double-clicking on the proposal) the variable will be added to the declaration node.

Refactoring. The renaming of variables in a Petri net drawing and changing of synchronous channels in net systems is now supported through the Refactoring plugin. However, these features are still under development and are still experimental.

Project Navigator. The Navigator – first introduced in version 2.3 – has been further improved. Due to a complete redesign, it provides a quicker update strategy, persistence and a filter functionality. The Navigator GUI is now extendable by plugins. On the right hand side of Fig. 4 the new Navigator GUI is displayed. The top level of buttons provides control over the content of the Navigator’s tree view. The second row provides a filter for the elements in the view. Extensions may add functionality as additional buttons or as context menus. The SVN/Diff Navigator extension provides the diff of two selected Petri nets (or other models) via button and diffs against the document base via context menu. Other SVN related functionality is provided as well.

Console Plugin. The new Console plugin, which utilizes JLineFootnote 6 as library, provides many convenience enhancements for the Renew command line in comparison to the replaced Prompt plugin. The main advantages are editable command lines, tab-based command and argument completions as well as searchable and persistent command history.

Analysis. With the integration of the LoLAFootnote 7 verification tool [9] Renew is also suited for verification tasks during modeling. So far only verification of P/T net models is provided through LoLA.

Net Components. Net components can be provided – and shared among developing teams – in order to ease recurrent modeling tasks and provide a conventionalized modeling style, which improves the readability and maintainability of net models.

Availability and OS-Integration. Renew is available for most common platforms including Linux (and other Unices), Windows and Mac OS X. For all Platforms there exists a GUI integration into the respective Desktop environment. For Linux/X11 we provide an integration for the FreeDesktop standard and experimental debian/ubuntu packages. For Mac OS X we provide a specialized plugin for the desktop integration and an application bundle as well as a specialized installation package (DMG, disk image file).

4 Architecture

The plugin architecture – introduced in release 2.0 of Renew – has already been presented [4, 7, 12]. Figure 5 shows the main parts, such as simulator, graphical framework (JHotDrawFootnote 8), the formalism management and the Petri net IDE core. The latter extends the graphical framework as well as the simulator. On top of these core elements other plugins can be included, such as editor plugins, formalism plugins, tools that extend these formalisms and also applications, which may use Java code and Petri net code in combination.

Fig. 5.
figure 5

Renew’s abstract architecture [7] – components as plugins.

Over the last years many plugins in various stages of maturity have been created by the maintainers or by other developers (e.g. students). Some of these extend the Renew environment, while others extend the Mulan environment or provide multi-agent applications.

A boost for the development of plugins have been the plugins that allow the creation of plugin source folders. There exists a rather simple version of a Plugin Development Plugin for Renew plugins and a more elaborated version that allows the creation of multi-agent application folders – the Use Case Components PluginFootnote 9. With these plugins it is possible to create a new Renew plugin simply by providing the name and the location of the source folder. The latter must be a valid source code repository in order to be able to compile the plugin. A newly created plugin folder features already all necessary artifacts for the compilation of the plugin. These are the Ant build script, the plugin configuration file (plugin.cfg) as well as the source code folder. Additionally, a valid plugin facade class is generated. The Use Case Components Plugin also generates artifacts for the creation of Mulan applications according to a provided Coarse Design Diagram (CDD, a form of Use Case Diagram). These artifacts comprise the skeletons for agent role declarations, interaction definitions and ontology specification.

Java classes, Renew nets and other artifacts – for instance JavaCC grammars or JavaScript files – can be added to the source code folder. The plugins may be accompanied by third party libraries and test cases.

An application that has been used heavily in the last couple of years is the above mentioned export and diff Web service. The Mulan Export plugin provides an agent (the ExportAgent) that offers the export and diff services to other agents and through the WebGateway also as a Web service to other clients. The backend of the export and diff functionality is provided by the respective Renew plugins (FreeHep Export and ImageNetDiff). Over the last couple of years the service running as a Mulan system in an instance of Renew has been constantly available and used, with up-times of several months. These long lasting running instances of Reference net systems and the high availability of the services show the feasibility and efficiency of the approach. Now several instancesFootnote 10 of the export and diff service are running on several servers.

5 Conclusion

Renew’s development has been ongoing for almost two decades. It has developed from a simulator and editor for a single high-level Petri net formalism to an integrated development environment for Java- and Petri net-based applications. The Reference net formalism and Renew’s simulator have proven themselves in various implementations to provide powerful and efficient means to develop and execute systems that include a strong focus on concurrency. Within the Paose context distributed, concurrency-aware systems have been implemented with the Mulan framework extension. In this environment many objectives, such as support for monitoring or specialized modeling techniques, have been provided on the grounds of the Renew framework and were only possible through Renew’s plugin architecture.

Today Renew exists in various configurations. Since the possibilities are growing constantly we are aiming at a product line architecture in order to ease configuration-intensive work and endorse reliable, feature-complete tool sets for multiple application domains.