[muscle] Re: signalowner

  • From: "VANHERP Wim" <Wim.VANHERP@xxxxxx>
  • To: <muscle@xxxxxxxxxxxxx>
  • Date: Fri, 3 Jun 2005 18:59:02 +0200

I have a testprogram that sends and receives.  When i modify the
testprogram you submitted to display only received messages i can see
that my program indeed sends messages, so the thread is running.  As i
understand your explanation i see the messages that go to the server but
i do not see no messages arrive from the server. =20
I will isolate some code to show what i am doing.

regards

-----Oorspronkelijk bericht-----
Van: muscle-bounce@xxxxxxxxxxxxx [mailto:muscle-bounce@xxxxxxxxxxxxx]
Namens Jeremy Friesner
Verzonden: vrijdag 3 juni 2005 18:14
Aan: muscle@xxxxxxxxxxxxx
Onderwerp: [muscle] Re: signalowner=20


Hi Win,

> I'm yet a bit further.  I can send messages now , but i don't arrive=20=

> to be signaled when they arrive.

I'm not sure I understand.  Do you mean that SignalOwner() is not called
when a Message arrives from the server=3D3F  What Messages are you
expecting to arrive from the server=3D3F

> I have used a descendant of
> messagetransceiverthread and I have overloaded signalowner(). But when

> a message arrives in the function down here, the function=20
> SignalInternalThread is chosen and not SignalOwner.

SignalInternalThread() is called by SendMessageToInternalThread(), so
that the network I/O thread will wake up and send your outgoing
Message(s) to the server.  That is normal behaviour for Messages that
your program is sending to the server.

SignalOwner() is only called when a Message is received from the server
by the network I/O thread.  The network I/O thread posts the incoming
Message to a Queue, and then calls SignalOwner() to notify your main()
thread that the Message is available for pickup.  That is the expected
behaviour for Messages that your program is receiving from the server.

> How can I fix this =3D3F

It's not clear to me what is broken, if anything.  Can you email me a
short example program that you think should work, but doesn't=3D3F  Then =
I
will understand better what the situation is.

-Jeremy

ps An easy way to test sending and receiving, using a single client, is
to have your client program send a PR=3D5FCOMMAND=3D5FGETPARAMETERS Messa=
ge
to the server.  The server will immediately respond with a
PR=3D5FRESULT=3D5FPARAMETERS reply Message, so you should see SignalOwner=
()
get called a few moments after you send the PR=3D5FCOMMAND=3D5FGETPARAMET=
ERs
Message.



*** Disclaimer ***

Deze e-mail, met eventuele bijlagen, is alleen bestemd voor de persoon of=
 organisatie aan wie hij gericht is en, in voorkomend geval, alleen voor =
het daarin opgegeven doel of gebruik. Hij kan vertrouwelijke informatie b=
evatten en/of persoonlijke standpunten die niet noodzakelijk met die van =
de VRT stroken. Elk gebruik van deze informatie (zoals bewerken, doorstur=
en, geheel of gedeeltelijk reproduceren of verspreiden in welke vorm ook)=
 door anderen dan de geadresseerde, is verboden. Hebt U deze e-mail per v=
ergissing ontvangen, meld dat dan a.u.b. aan de VRT en wis de e-mail.
=20


Other related posts: