473,403 Members | 2,354 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,403 software developers and data experts.

remoting serialization exception

I've been following a couple remoting tutorials on the web, they are all
pretty much the same.
I've got my different applications built(client, server and remote object
(dll))

The client is able to get a reference to the remote object and that works
fine. When I try to make a call to a remote object's method I get an
exception:
System.Runtime.Serialization.SerializationExceptio n: Cannot find the
assembly ProcessTest, Version=1.0.2021.22452, Culture=neutral,
PublicKeyToken=null.

"ProcessTest" is the client application. Now, pasting all my code would be
a little bit much, so I'm hoping that from this error someone will be able
to give me a clue, if not, I can post what I think is the relevant code.

Thanks,
Steve
Nov 17 '05 #1
3 2847
Just to make sure, you are dealing with 3 separate assemblies? The client,
the server and the remote object? Is the same remote object being referenced
by both projects?

I’ve seen it far too many times in past with my remoting work to have the
client and server using slightly different versions of the remote object
assembly, only to give up and throw a hissy fit because of it.

Brendan
"Steve" wrote:
I've been following a couple remoting tutorials on the web, they are all
pretty much the same.
I've got my different applications built(client, server and remote object
(dll))

The client is able to get a reference to the remote object and that works
fine. When I try to make a call to a remote object's method I get an
exception:
System.Runtime.Serialization.SerializationExceptio n: Cannot find the
assembly ProcessTest, Version=1.0.2021.22452, Culture=neutral,
PublicKeyToken=null.

"ProcessTest" is the client application. Now, pasting all my code would be
a little bit much, so I'm hoping that from this error someone will be able
to give me a clue, if not, I can post what I think is the relevant code.

Thanks,
Steve

Nov 17 '05 #2

"Brendan Grant" <gr****@NOSPAMdahat.com> wrote in message
news:99**********************************@microsof t.com...
Just to make sure, you are dealing with 3 separate assemblies? The client,
the server and the remote object? Is the same remote object being referenced by both projects?

I've seen it far too many times in past with my remoting work to have the
client and server using slightly different versions of the remote object
assembly, only to give up and throw a hissy fit because of it.

Brendan
"Steve" wrote:
I've been following a couple remoting tutorials on the web, they are all
pretty much the same.
I've got my different applications built(client, server and remote object (dll))

The client is able to get a reference to the remote object and that works fine. When I try to make a call to a remote object's method I get an
exception:
System.Runtime.Serialization.SerializationExceptio n: Cannot find the
assembly ProcessTest, Version=1.0.2021.22452, Culture=neutral,
PublicKeyToken=null.

"ProcessTest" is the client application. Now, pasting all my code would be a little bit much, so I'm hoping that from this error someone will be able to give me a clue, if not, I can post what I think is the relevant code.

Thanks,
Steve

Hi Brendan,

Yes, that is a good point and one that could be easily overlooked. I just
rebuilt everything in the following order;
remoteobject
server
client

so the client and server are using the same dll for sure.

I tried running the client again, here is the stack trace that is dumped (it
looks like the exception is happening on the server application?):
Server stack trace:
at
System.Runtime.Serialization.Formatters.Binary.Bin aryAssemblyInfo.GetAssembl
y()
at
System.Runtime.Serialization.Formatters.Binary.Obj ectReader.GetType(BinaryAs
semblyInfo assemblyInfo, String name)
at System.Runtime.Serialization.Formatters.Binary.Obj ectMap..ctor(String
objectName, String[] memberNames, BinaryTypeEnum[] binaryTypeEnumA, Object[]
typeInformationA, Int32[] memberAssemIds, ObjectReader objectReader, Int32
objectId, BinaryAssemblyInfo assemblyInfo, SizedArray
assemIdToAssemblyTable)
at System.Runtime.Serialization.Formatters.Binary.Obj ectMap.Create(String
name, String[] memberNames, BinaryTypeEnum[] binaryTypeEnumA, Object[]
typeInformationA, Int32[] memberAssemIds, ObjectReader objectReader, Int32
objectId, BinaryAssemblyInfo assemblyInfo, SizedArray
assemIdToAssemblyTable)
at
System.Runtime.Serialization.Formatters.Binary.__B inaryParser.ReadObjectWith
MapTyped(BinaryObjectWithMapTyped record)
at
System.Runtime.Serialization.Formatters.Binary.__B inaryParser.ReadObjectWith
MapTyped(BinaryHeaderEnum binaryHeaderEnum)
at System.Runtime.Serialization.Formatters.Binary.__B inaryParser.Run()
at
System.Runtime.Serialization.Formatters.Binary.Obj ectReader.Deserialize(Head
erHandler handler, __BinaryParser serParser, Boolean fCheck,
IMethodCallMessage methodCallMessage)
at
System.Runtime.Serialization.Formatters.Binary.Bin aryFormatter.Deserialize(S
tream serializationStream, HeaderHandler handler, Boolean fCheck,
IMethodCallMessage methodCallMessage)
at
System.Runtime.Remoting.Channels.CoreChannel.Deser ializeBinaryRequestMessage
(String objectUri, Stream inputStream, Boolean bStrictBinding,
TypeFilterLevel securityLevel)
at
System.Runtime.Remoting.Channels.BinaryServerForma tterSink.ProcessMessage(IS
erverChannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
requestHeaders, Stream requestStream, IMessage& responseMsg,
ITransportHeaders& responseHeaders, Stream& responseStream)
Nov 17 '05 #3
Another area I ran into this bug was with events, I would attempt to
subscribe to an event on the reference and things would go to hell... but
given that you are having this issue when you call a method, it may not be
the same.

Are you using a CAO model for your remoting object(s)?

Take a look at http://www.thecodeproject.com/csharp...ctoryguide.asp for
some info on how CAO works and how to implement it.

Brendan
"Steve" wrote:

"Brendan Grant" <gr****@NOSPAMdahat.com> wrote in message
news:99**********************************@microsof t.com...
Just to make sure, you are dealing with 3 separate assemblies? The client,
the server and the remote object? Is the same remote object being

referenced
by both projects?

I've seen it far too many times in past with my remoting work to have the
client and server using slightly different versions of the remote object
assembly, only to give up and throw a hissy fit because of it.

Brendan
"Steve" wrote:
I've been following a couple remoting tutorials on the web, they are all
pretty much the same.
I've got my different applications built(client, server and remote object (dll))

The client is able to get a reference to the remote object and that works fine. When I try to make a call to a remote object's method I get an
exception:
System.Runtime.Serialization.SerializationExceptio n: Cannot find the
assembly ProcessTest, Version=1.0.2021.22452, Culture=neutral,
PublicKeyToken=null.

"ProcessTest" is the client application. Now, pasting all my code would be a little bit much, so I'm hoping that from this error someone will be able to give me a clue, if not, I can post what I think is the relevant code.

Thanks,
Steve

Hi Brendan,

Yes, that is a good point and one that could be easily overlooked. I just
rebuilt everything in the following order;
remoteobject
server
client

so the client and server are using the same dll for sure.

I tried running the client again, here is the stack trace that is dumped (it
looks like the exception is happening on the server application?):
Server stack trace:
at
System.Runtime.Serialization.Formatters.Binary.Bin aryAssemblyInfo.GetAssembl
y()
at
System.Runtime.Serialization.Formatters.Binary.Obj ectReader.GetType(BinaryAs
semblyInfo assemblyInfo, String name)
at System.Runtime.Serialization.Formatters.Binary.Obj ectMap..ctor(String
objectName, String[] memberNames, BinaryTypeEnum[] binaryTypeEnumA, Object[]
typeInformationA, Int32[] memberAssemIds, ObjectReader objectReader, Int32
objectId, BinaryAssemblyInfo assemblyInfo, SizedArray
assemIdToAssemblyTable)
at System.Runtime.Serialization.Formatters.Binary.Obj ectMap.Create(String
name, String[] memberNames, BinaryTypeEnum[] binaryTypeEnumA, Object[]
typeInformationA, Int32[] memberAssemIds, ObjectReader objectReader, Int32
objectId, BinaryAssemblyInfo assemblyInfo, SizedArray
assemIdToAssemblyTable)
at
System.Runtime.Serialization.Formatters.Binary.__B inaryParser.ReadObjectWith
MapTyped(BinaryObjectWithMapTyped record)
at
System.Runtime.Serialization.Formatters.Binary.__B inaryParser.ReadObjectWith
MapTyped(BinaryHeaderEnum binaryHeaderEnum)
at System.Runtime.Serialization.Formatters.Binary.__B inaryParser.Run()
at
System.Runtime.Serialization.Formatters.Binary.Obj ectReader.Deserialize(Head
erHandler handler, __BinaryParser serParser, Boolean fCheck,
IMethodCallMessage methodCallMessage)
at
System.Runtime.Serialization.Formatters.Binary.Bin aryFormatter.Deserialize(S
tream serializationStream, HeaderHandler handler, Boolean fCheck,
IMethodCallMessage methodCallMessage)
at
System.Runtime.Remoting.Channels.CoreChannel.Deser ializeBinaryRequestMessage
(String objectUri, Stream inputStream, Boolean bStrictBinding,
TypeFilterLevel securityLevel)
at
System.Runtime.Remoting.Channels.BinaryServerForma tterSink.ProcessMessage(IS
erverChannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
requestHeaders, Stream requestStream, IMessage& responseMsg,
ITransportHeaders& responseHeaders, Stream& responseStream)

Nov 17 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: jan v | last post by:
Hi everyone I have a problem with events. When the code reaches communication.SynchronisationServer.UpdateNotificationEvent+=new...
6
by: Uttam | last post by:
Hello, We are at a very crucial decision making stage to select between .Net and Java. Our requirement is to download a class at runtime on the client computer and execute it using remoting or...
3
by: Skip | last post by:
Hi, I'm new to .NET remoting and there's something I'm having real trouble with. Basically, I'd like to create a component that can act as a server and as a client (can send messages and receive...
15
by: Sharon | last post by:
I’m trying to build a generic Publisher-Subscriber that will work over the net, so I’m using the Remoting. I wish that the subscriber user will be notify about the messages sent by the...
4
by: Uchiha Jax | last post by:
Hello everyone, I am a plenty silly person who is trying to learn .NET remoting through trial and error (all articles I read are going over my head at the moment (mostly) so I thought i'd give...
11
by: ajou_king | last post by:
I was running some tests on my Win32 1GHZ processor to see how long it would take to transmit objects numerous times via TCP/IP using C# ..NET Remoting vs the C++ trustworthy method of binary...
1
by: Dan Holmes | last post by:
I traced this all the to the domain boundary. I also but a breakpoint in the server. That was never hit. It happens after it leaves the client but before it calls into the "add" method in the...
2
by: Jayme.Pechan | last post by:
I realize this is a complicated scenerio to explain so hopefully it will make sense. I have an object that I create an instance of on a remote server. I can call functions on this object with no...
3
by: benkial | last post by:
Below is a custom exception class that I created to be shared by my C+ + and C# code. It works fine till I need to pass the exception object through Remoting: every time a FtException is raized in...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.