February 13th, 2009 — 11:08 am
I have seen this question in Stackoverflow.com, and I want to answer it here:
Greetings readers! So I am trying to develop a client server system.. Since I have not designed a client server system before, I thought that I would post a question and see what the experts here have to say.
Requirements: .NET 3.5 WCF minimum of 2 computers, Master and Slave.
The use case is a testing environment, where the slave runs tests at the request of the master.
Questions: I would prefer that the slaves locate and connect to the master, and then the master takes control and is the one that initiates the tests to be run. The slave also makes progress reports: new test data, unexpected events, etc.
The part that I am confused about is that if the slave initiates contact with the master, doesn’t that make him the master?
Does this mean that I need servicehosts on both slave and master so that they can initiate activity?
Most channels in WCF are basically a one-way communication, in a sense only one side (WCF Client) can initiate requests - the other side (WCF Service) cannot initiate calls, only respond to them.
There are two possible solutions to the problem presented here:
- The tester slave (WCF client) initiates the connection to the tester master (WCF service). Afterwards it polls the tester master periodically to receives a list of tests to run.
- The tester slave (as a WCF client) initiates the connection to the tester master (as a WCF service). In response, the tester master (now as a WCF client) initiates a second connection to the tester client (now as a WCF service). The tester master than sends tests requests to the tester slave.
Both architectural approaches can be implemented regardless of the channel type, MSMQ, Tcp/Ip or otherwise.
2 comments » | Uncategorized
December 17th, 2008 — 02:37 pm
Comment » | Uncategorized
April 30th, 2008 — 11:05 am
Recently a privacy issue concerning web 2.0 was raised, as a new Twitter service called “GroupTweet” caused private messages to be published for everyone to read due to a misunderstanding of the system.
However, I do appreciate the response of Aaron Forgue, the person behind GroupTweet (taken from the site):
- This is NOT a privacy bug with Twitter. I apologize for any negative voodoo I’ve pulled down on them. Their service works great and there are no privacy issues (that I know of). Please direct your hatred at me!
- There are no known bugs or privacy issues with GroupTweet as long as you create a separate Twitter account for your group.
- The reason that a particular GroupTweet users’ direct messages were exposed is because she registered her PERSONAL Twitter account at GroupTweet. The site was doing exactly what it was supposed to: taking direct messages sent to the GROUP account and re-publishing them as tweets. When the personal account was registered here, direct messages sent to the account were republished. Unfortunately, these were not meant to be republished.
- I am 100% at fault for this fiasco because I did a poor job of explaining the steps one needs to take to use GroupTweet. I sincerely apologize
- I WILL BE DISABLING ALL GROUPTWEET ACCOUNTS. The only way I can ensure that this doesn’t happen to anyone else is to disable all accounts. If you are sure that you are using GroupTweet correctly and would like your group re-activated, simply email me or re-register (once I turn the form back on)
So what did we see here?
- Clearing Twitter’s name (originally Twitter toom the blame).
- Taking a complete responsibility.
- Disabling the service until further “accidents” may be prevented. (the site is back now)
How many companies / people do you know who would have behaved this way in Aaron’s place?
Comment » | Uncategorized
April 21st, 2008 — 07:20 am
Four reasons to use Twitter:
- Meeting new people
- Finding new sites and resources
- Promoting your blog
- Nice to “hang out” with virtual friends when you have spare time
Four reasons to avoid Twitter:
- Spending time on Twitter-related issues: the way your Twitter page looks, Twitter utilities, Twitter statistics (as if your blog didn’t consume enough time already)
- Increased cell-phone bill (because you can’t find Wifi everywhere)
- Great temptation to “Hang out” when you DON’T have spare time
- Great way to procrastinate
Comment » | Uncategorized
November 10th, 2007 — 11:09 pm
Just did some searching and found
this site, which sells T-shirts with the tagline: “Programming is an art form that fights back” (which I “stole” from Chad Z. Hower, aka
Kudzu)
Comment » | Uncategorized
November 8th, 2007 — 12:20 pm
I was lucky to be invited to the official press conference of announcement of the new Live service from Microsoft.
It looks very promising, and would give Google (and Picasa) a tough competition.
Here are some interesting points from the presentation:
- Microsoft global market status: According to the speaker there are 280 million MS Messenger users worldwide, and the number of Hotmail users is three times the number of GMail users. If these numbers are correct, Microsoft can still hurt Google badly.
- The new mail service (Windows live mail) allows integration with Messenger - you can see your friends online while typing a message to them and start a chat. (Additional interesting features - contacts lists, RSS support). I was also told the spam prevention mechanism (a major problem for Hotmail users) was improved - I intend to check that.
- MS Messenger itself had an improved integration with mobile devices - you can leave voice messages to friends online.
- In the photos department Microsoft is in direct competition with Picasa, which had the advantage so for for being a “one stop shop” for all photo related applications. The new Live client application allows you to send photos to friends, with the mail containing only small thumbnails and a photo sharing site is generated automatically that allows viewing/downloading of the original photos. Additional features include embedding photos in a blog post, and creating an event-dedicated shared site, in which participants can upload photos and share them with each other.
- All of these applications come wrapped up in a single installer which allows you to select the desired installed features. It’s a serious upgrade for Outlook Express users and Messenger users, and I recommend installing Windows live photo gallery application.
- All of these services are aimed at the personal user - for organizations Microsoft has Office Communicator and a beta version of calendar sharing site.
- In the future there will be an integration between MS Live and Media center, allowing you to read and manage blogs, photos and contacts using the TV screen.
- You can register to the new service and receive a brand new mail address (you name may still be available!). Us users are directed to the Live.com domain, while users in other countries (depending on the first language in the browser’s languages configuration) may choose other domains.
Here are some pictures I took which are hosted in the new Live space I created:
Comment » | Uncategorized
October 17th, 2007 — 08:15 am
Thread 1:
lock (a)
{
lock (b)
{
lock (c)
{
//some code
}
}
}
Thread 2:
lock (d)
{
lock (c)
{
lock (b)
{
//some code
}
}
}
Main thread:
lock (a)
{
//important code
}
Comment » | Uncategorized