We have a case where some fields on a running ruote process need to be
updated. The use case is simply applying new or updated values to
specified workitem fields - no need to advance or alter the workflow
further than that.
The StorageParticipant#update(workitem) looked like it would do exactly
what was needed, but it results in an object being nil error.
I was able to reproduce the error in a test which follows the basic steps
of how I was trying to apply an update.
Error:
1) Error:
test_update_workitem_alt(FtStorageParticipantTest):
NoMethodError: undefined method `[]' for nil:NilClass
/Users/doug/src/ruote/lib/ruote/storage/hash_storage.rb:98:in `block in
get'
Test (add to ft_20_storage_participant.rb to quickly test):
def test_update_workitem_alt
@dashboard.register_participant 'alpha', Ruote::StorageParticipant
wfid = @dashboard.launch(Ruote.process_definition { alpha })
wait_for(:alpha)
wi = @dashboard.process(wfid).workitems.first
alpha = @dashboard.participant(wi.participant_name)
wi.set_field('my_field', 'abc123')
alpha.update(wi)
assert_equal 'abc123',
@dashboard.process(wfid).workitems.first.fields['my_field']
end
--
--
you received this message because you are subscribed to the "ruote users" group.
to post : send email to [email protected]
to unsubscribe : send email to [email protected]
more options : http://groups.google.com/group/openwferu-users?hl=en
---
You received this message because you are subscribed to the Google Groups
"ruote" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.