A couple of years back I wrote a WPF application and used Prism Event aggregation for notifying my submodules (both visual and non visual) for changes. It worked fine and I kind of liked it.
Now I'm about to write a Net 6 (Core) application and I was wondering what you guys suggest that I use for event aggregation in my application.
(If I'm not mistaken Prism Event Aggregator is for .Net 4.x)
King regards
Magnus
You can use Prism's event aggregator independent from the wpf- or xamarin.forms- or whatever features. I've included it in a xamarin-native app where it's literally the only class from Prism used.
Nothing wrong with just including the Prism.Core nuget and using the event aggregator.
Just make sure to register it as a singleton from the main thread, if you want to use ThreadOption.UIThread.
I'm using Caliburn micro with a WinRT application and it looks like that there's no StorageManager class, anyone has suggestions about how to persist application/ViewModels state in this case.
TIA
This is not related to Caliburn.Micro but rather a general issue. You can either use Serialization but then you will have to pay attention to versioning and changes in your view model or you could save the fields you are interested in to a file using the normal IO methods or even store your view models in the database if you wish (although i think this might be a bit extreme).
Edit: Caliburn.Micro isn't a business application framework and there have been no library that tried to integrate business functionality with CM as far as i know, so this leaves you with serialization as your best option but as i said ser/des comes with some nightmares you have to manage such as version changes, class changes, etc.
There's another project called Catel which is a business application framework that contains an MVVM framework, anyway Catel uses a nice object called DataObjectBase ( actually now it is called ModelBase) which solves all problems of serialization and there is an article for that on code project if you want to read it and see how they have done it.
If you wish you can use the Catel.Core module which is a library with a lot of features for data handling (it contains the ModelBase class) or you can take a look at the source code and see how they have solved the issue with ser/des and implement that with Caliburn.Micro in your project.
I am developing some composite activity those consist of several code activities and WF framework activities.
When I drop it on workflow service (xmalx), it is viewed as a single activity. I want to show complete this custom activity with all child activities on workflow service.
Here is a link to an MSDN post where a developer has a version of a custom activity designer that will do this. You may have to make some modifications but I bet with a little effort you can get it to work for you.
http://social.msdn.microsoft.com/Forums/nl/wfprerelease/thread/6bd297b8-23e4-402b-9e1b-56b816dacf42
I am exploring if Workflow Foundation 4.0 is stable enough to start developing on it but the documentations I've seen so far are mysteriously silent about why there are no built-in Transaction & SQL Tracking services! They were available in WF 3.5 and seemed to be reasonably stable. Any clues? Was there no time for MS to release WF 4.0 on schedule or the whole concept was broken in 3.5 that they decided to scrap them? I know there are lot of links and hints pointing to writing a custom (SQL) tracking participant, but then what is the point of a "framework"? Moreover there's no way to query the tracked data. And nothing about Transaction service! So how do we keep the WF persistence data & application data consistent? Am i missing something here?
Some unsatisfactory answers on "missing" SQL tracking in WF4:
- http://social.msdn.microsoft.com/Forums/en-US/wfprerelease/thread/8cfe598a-a400-4804-92ad-d68aa444d8f3
[got a few more links, but couldn't post them here bcoz new users can post only one hyperlink per question :( ]
Any help will be greatly appreciated :)
SQL tracking is missing however the AppFabric does include tracking if you go the workflow services route.
Transactions are supported. There is the TransactionScope activity for short running transactions an a CompensatableTransaction for doing long running transactions. There is also the option of creating activity extensions based upon PersistenceIOParticipant where you can save extra data durin THE transaction used to save THE workflow.
According to MSDN, the SQLTrackingService is still supported (see the bottom of the below article):
http://msdn.microsoft.com/en-us/library/system.workflow.runtime.tracking.sqltrackingservice.aspx
You will have to add references to System.Workflow.Runtime.dll (and probably System.Workflow.ComponentModel.dll) to your project. Make sure you are targeting the full .net 4 framework in your project properties (i.e. not the client .net 4 framework). Both dlls can be found in the v4 framework directory.
I've been using WWF for a while as part of an internal call center application (ASP.NET), and while learning it was a good practice in understanding how a state machine based workflow system should work, I am definitely not in love with WWF itself. In my opinion it is:
Overly complex, especially for use within web apps (all that threaded runtime stuff)
Immature (ever worked with that horrible designer?)
Anemic in its current feature set
Does anyone have a suggestion for a better .NET based workflow framework? Specifically, I am looking for the following features:
State machine based (mapping states to available actions)
A focus on user permissions (controlling who has access to what actions)
The ability to run workflows as timed background tasks (for example, to send out reminders for items that have been sitting in a certain state for x days)
That's really all I need. I don't need to be able to "drag and drop" any activities or visually design the flow. I am perfectly comfortable writing actual code once a particular action is triggered.
You could try Simple State Machine. You would have to implement access control and background timers yourself, but that shouldn't be a big deal. SSM was also built out of frustration with WF. There are some other state machine implementations on Codeplex as well. If one of them doesn't fit he bill out of the box, they are open source and should get you close enough.
I wholeheartedly agree with you about state machines in WF - they aren't testable, are too complicated, the threading model is peculiar and hard to follow, and I'm not sure a visual designer could have been more poorly conceived for designing state machines graphically. I think this may be because the state machine concept feels tacked onto the WF runtime, which was designed for sequential state machines, something WF does a much better job with, in my opinion. The problem is that state machines are really not the same animal as a sequential work flow, and should have been given a first class implementation of their own, because the warping of WF to make it seem to support them turned out to be more or less unsupportable, if not actually unusable.
I would stay away from Drools.Net since it's last SVN commit was in September 2007. Looks nice but it seems a bit too risky to make such a big library part of your project when you know it doesn't get any attention anymore.
Try Drools.NET
Have a look at Workflow Engine. It is a lightweight workflow framework for .NET and Java solutions. It has an HTML5 visual designer, version control, a decent UI and supports a wide range of databases.
Do you have the option to consider BizTalk Server?
I quite enjoyed working with Oracle BPEL Process Manager. It's part of JDeveloper.
http://www.oracle.com/technology/bpel/index.html
http://gemsres.com/story/dec06/313602/jellema-fig1.jpg
You may want to take a look at Jazz - http://jazz.codeplex.com/
Try WF4.5. It was completely redesigned since .NET4.0.
First of all you should look for a engine supporting BPMN. BPMN is a standard in Workflow and Process management and well supported from a lot of projects.
Second you should think about the requirements to thus an engine.
When you look for a BPMN Engine, there are two different approaches:
Task-Orientated
These engines (e.g. JBoss BPM - jbpm) are designed to process an input data by a well defined process model. Each task in the model gives the control to a piece of code - either a standard or an individual implementation. The process ends when the process-token reaches the end of the process model (End-Event). This kind of processing takes milliseconds. The engine can be used for batch jobs or processing data with a complex process orientated flow.
Event-Driven
Human-Centric workflow engines are event driven (e.g. Imixs-Workflow). This is a kind of state machine but offers typically much more functionality. You can start a new processinstance by assigning your business object with the initial task (defined by the start event). Than the workflow engine allows you to trigger events assigned to each task, defined in your model. Each event (Intermediate CatchEvent) triggers the workflow engine to transfer the running processinstance to the next task (state). Until no new event is triggered, the processinstance 'waits' in the current task (state). An approval process is an typical example for this kind of human-centric workflow.
You can find a list of engines here.