hope you give me a little hint about my demand

Aug 6, 2014 at 2:30 AM
Now I want to realize this function:
Now We have ClientA,ClientB,clientC,and ServerD.
I need ClientA send a message to ServerD(Just like the first demo:QuickStart.Shuttle),
and then I need ServerD send this message to ClientB and ClientC(Just like the demo:Pub/Sub).

So I have to put this two demos together.Now I have no thought about how to do this.Can you give me a little hint?
Thanks,my friends.
Aug 6, 2014 at 5:00 AM

You use 'send' when working with commands. They go to 1 endpoint and they must have an endpoint.

You use 'publish' when something interesting has happened that other endpoints may be interested in. There can be 0 to N subscribers.

In your scenario I would 'send' a command from ClientA to ServerD. Then ClientB and ClientC need to subscribe to an event that you 'publish' from ServerD after the processing.

Of course ClientB and ClientC will need handlers for the given event.

In the pub/sub video (https://www.youtube.com/watch?v=_q7yu_9ZVo0) this scenario is illustrated, but instead of the client subscribing one would have your other two clients subscribing.

Aug 6, 2014 at 10:19 AM
Hello,Today I've tryed it to put these two demos together.But it still has some bugs.
Such as:
 No treatment MissingMethodException
 Not found Method:"System.String Shuttle.Core.Infrastructure.ExecptionExtensions.AllMessages(System.Exception)"
I've already Checked my codes for many times,but I still can't solve the problem.
According to this error message,I guess maybe it's the Version's problem.
do you think so?
Aug 6, 2014 at 2:17 PM

Yes, it is definitely a version problem. The shuttle-core was updated and it now contains the AllMessages() extension method. So it seems as though you have newer shuttle-esb with older shuttle-core.

Perhaps try to a nuget "update-package".

Aug 7, 2014 at 3:11 AM

I've already download the newest source code,but it still has the same problem.Through the internet,some guy said to me "this is because the problem of .NET FrameWork's version".My develop environment is .NET FrameWork4 ,and the source code is .NET FrameWork 3.5,Does it even matter a lot?

thank you for your help all the time.
Aug 7, 2014 at 5:13 AM

What source code are you referring to?

In your own code you will be using the binaries. The nuget packages have binaries for 3.5, 4.0, and 4.5. It isn't a framework version issue but rather an issue between the versions of shuttle-core and shuttle-esb.

Have you tried the nuget 'update-package' command? Well, that will only work if you have included your references from nuget.

Aug 8, 2014 at 4:09 AM
Edited Aug 8, 2014 at 4:26 AM

Thanks you for your help my friends.It's OK now.But there are still some problems.
I hope you can help me again.Such as the following quesions.

1、It sometimes send this wrong message.
  No queue factory has been registered for scheme 'msmq'.

2、Do you remebmer the ClientA,ClientB,clientC,and ServerD demo that I told you before?I still can't realize it.My thought just like that:
ClientA send a message to ServerD(Just like the first demo:QuickStart.Shuttle),
Then ClientB and ClientC  subscribe to an event that you 'publish' from ServerD after the processing(pub/sub Demo).
I want to put QuickStart.Shuttle.Server(from demo QuickStart.Shuttle) and PublishSubscribe.Client(from Demo pub/sub)  together.But I didn't know how to do it.Could you tell me a easy way to do this?

3、sorry,I still have the third question.
 Now I find the Subscriber can send message to Publicer in the pub/sub demo.So I have a thought to realize my function.I can use one of the Subscriber send message to the Publicer,and then the Publicer send it to others.But I really don't think that is a good idea.What do you think?
Aug 8, 2014 at 5:22 AM

When a service bus instance starts up the QueueManager finds all queue factories. Each factory is associated with a uri scheme. So when you get this message it means that shuttle has not found your msmq queue factory implementation. Ensure that it is in the binary folder.

What you describe in point 3 is exactly how you should solve your point 2 problem. When you have multiple messages involved in performing some process you'll find that your command endpoint typically raise events or send more commands to get the job done. For instance, let's say you register an order by sending a RegisterOrderCommand message. When that is processed on the Order.Server endpoint it may raise event OrderRegisteredEvent. In addition to this you need to, say, send an e-mail. To do this you send a command called SendEMailCommand to the EMail.Server endpoint. So not only is it perfectly valid but you will find yourself doing this all the time. When working with arbitrary sample names the conepts may not be quite as apparent :)