communicate changes between csla-apps on different pc's in same network

communicate changes between csla-apps on different pc's in same network

Old forum URL: forums.lhotka.net/forums/t/5469.aspx


Jurjen posted on Thursday, September 25, 2008

I will be developping a planning application for wich it's necessary from multiple users to view and edit the same data, all changes made by one user, must be visible to the other user's more or less immediately. So I'm looking for a mechanism with wich I can notify the 'other' applications of any changes so they can update their 'view'.

In the past I've seen som discussion her about how one could accomplish this, but I couldn't find it here and it was years ago and things have changed since then. so that solution might even be outdated.

maybe someone can help me out or point me in the right direction.

thanks,
Jurjen.

JoeFallon1 replied on Thursday, September 25, 2008

As I recall Petar (Kozul ?) had something called ActiveObjects which could be bolted on to the CSLA framework. I have not heard much about it since CSLA 1.x days. But I thought many people were using it back then. Even if you don't use it "as is", I think some people claimed it helped them implement the Observer pattern for their own frameworks.

Joe

 

Jurjen replied on Thursday, September 25, 2008

Joe,

Thanks for your response, but I am using ActiveObjects and it can't used for communicating with the same (ot other) apps on other pc's in the network. It's designed for use within the application to notify the parent object of changes in child-objects...

Jurjen.

tiago replied on Saturday, September 27, 2008

You need  Rocky's Broadcasting Messages to Multiple Clients http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnadvnet/html/vbnet06082004.asp 

I converted it to C# on VS2005 (Framework 2.0) put a lot of work on testing (unpluging cables, etc). There was some obscure framework lock bug. But now it works.

Regrettably the article is no longer online

Do you care for the article and sources?

Edited: now I remember what was the problem: there is an issue with lock timeout on Framework 2.0. I had to use a custom TimedLock

Jurjen replied on Sunday, September 28, 2008

Tiago,

I would be very interested in the article and source code. I would really appreciate this, you can attach it to your next message of send it to me directly : jurjendegroot at xs4all dot nl

It's a shame articles aren't available on msdn anyome.

many thanks,
Jurjen. 

Jurjen replied on Tuesday, October 07, 2008

Tiago, could you send me the article and if possible the source-code ?

TIA, Jurjen

cash_pat replied on Saturday, November 22, 2008

You can find the article in the MSDN installation

Search for Broadcasting Messages to Multiple Clients in quotes


whelzer replied on Monday, November 24, 2008

Any idea of what version of MSDN.

Can't locate in in our 2008 version.

Thanks

Jurjen replied on Monday, November 24, 2008

whelzer, cash_pat,

Though I haven't implemented it yet, I have found an alternative to this using WCF in a book written by Juval Lowy, 'Programming WCF Services'. The code is part of a framework wich comes with the book (including the source-code). Look for the 'Publish-Subscribe' Service.

I got the example to work just fine in no time at all and will be implementing this in my WinApp in the coming weeks.

Hope this helps.

Regards,
Jurjen.

cash_pat replied on Monday, November 24, 2008

Sorry, VS2005 version of MSDN

tiago replied on Sunday, January 18, 2009

The URI is

http://msdn.microsoft.com/library/en-us/dnadvnet/html/vbnet0608

Since you can't find it, I have some stuff around

http://pwp.netcabo.pt/tfl/Broadcasting/MSDN_Broadcasting_Messages_to_Multiple_Clients_org.pdf - the original text

http://pwp.netcabo.pt/tfl/Broadcasting/MSDN_Broadcasting_Messages_to_Multiple_Clients.pdf - same text but bigger font (increased readability)

 

According to the EULA I can't distribute the original file. I have a derivative in C# that improves on the lock area (this is a well known .NET Framework shortcoming) using TimedLock instead of Lock

http://pwp.netcabo.pt/tfl/Broadcasting/csBroadcast_VS2005.rar

 

You also need a couple of extras all packed up:

http://pwp.netcabo.pt/tfl/Broadcasting/Pack4BroadcastingMessagesToMultipleClients.rar

Patrick replied on Tuesday, November 25, 2008

Hi,

I would be looking into a distributed cache... If you are lucky it might do a lot of the work for you since it can replicate changes to data between multiple nodes...

It's worth to have a lock at e.g. http://www.sharedcache.com/cms/shared_cache_topology.aspx#dis

Hope this helps,
Patrick

Copyright (c) Marimer LLC