build your own ui, refere to your own data by storing e.g. a reference in the jbpm tables or the other way around, store a reference to the process instances in your own table
It's best to decouple the bpm data from your domain data. I prefer to use jBPM or any BPM engine variables for process management and process management only. I hold domain related data in separate tables.
I agree that you don't want to be using the jBPM tables in your domain, I'd encourage you to look at either writing converters OR switching to jBPM 3.1.
You can write converters in either version, allowing you to reference full domain objects in the process (including in scripts via the context) while storing said objects in your own domain tables.
In 3.1 this is transparent and quite wonderful assuming your object is "hibernatable". That is, if the hibernate configuration tells the engine that it knows how to persist your type, you can use it as a variable in your process and jBPM via hibernate will handle persisting the object and loading it when you reference it. I'm pretty sure there are some boundaries related to the use of complex keys etc, but for most things with a "standard" single field primary key jBPM will handle this for you.
That said, I'm not aware of this feature in 3.0 - please correct me if I'm wrong, but 3.0 IIRC wanted you to supply converters (tiny little things really), but 3.1 just makes things cleaner.
Short of that - the standard jBPM<-> UI responses apply - write one :)
yeah, so everything was working fine with the unit tests (transactions are not being simulated perfectly apparently), as in the actual web app there is a problem with the jBPM perfectly recognizing the "hibernateable" types and doing the right thing.
Long story short, my domain class is serializable, so there is a problem as hibernate updates the serialized instance, not the instance in the domain model. As I work through this I'll post an update... seee the reference guide 10.6 for more information... I'm working with customizing the variable instance mapping to get the engine to correctly recognize my type and "do the right thing", where the "right thing" is what is intuitive...
more on this one later - and yes, I'm going to dig into the source to figure out what's going on.
That is one thing about jBPM - the source is nice and clean - easy to get set up in eclipse and get a debugger going quite quickly so it's easy to figure out what's going on at the very least :)
Can anybody give me a sample code to do this?