-----------------------------------------------------------

New Message on BDOTNET

-----------------------------------------------------------
From: ArunNAndU
Message 1 in Discussion


Hi Raghvendra.
 
    There was a time when 
serialization was the term used to mean saving the object to disk as a 
byte/binary file. But today we have more fine grain control as to what the 
output format should be. So there are Object Serialization, XML Serialization etc. 
generally clubbed under the name Object Persistence. Serialization is also done 
for none storage purposes like network transfers.
 
Can't serialization be used to speed up data 
access?  Yes 
definitely. That is what happens most of the time behind the scenes of a network 
call or save of object to disk. More appropriately Object Serialization. But 
limited to a language say Unmanaged C++ or IL. Each language defines the layout 
of its class or object in memory. Hence within the language like all .NET 
languages via IL or all C++ objects there is an easy or sometimes transparent 
serialization process employed. But cross language it could be 
challenging.
 


Can we serialize/de-serialize an object 
to/from a stream of bytes and store it? ... Shoud it be always written in a 
formatted file like xml... is there any other way?
Agreed, 
frequent XML Parsing could be taxing. Hence XML Serialization is not 
readily suited for disparate objects or any 
object. But a proper object model could really benefit from a one time parse and 
load concept. Furthermore. With pull parsing we have further optimized the 
parsing business. Did you know MSXML parser is the fastest in the industry 
:)
 
Having said that. Most of 
the times it really is not a choice of developers to say "Come what may, I will 
use XML Serialization" or something like that, it is purely requirement driven. 
So evaluate your requirements and options carefully before making a 
choice.
 
XML Serialization could 
help over Object Serialization in object transfer across environments. But when 
the requirement is object transfer within a language or environment, then we are 
better off with object serialization. 
 
Hope I have not confused 
you more :). 
 
Cheers!!!

Arun

  
  -----Original Message-----
From: Raghavendra S 
  Naik [mailto:[EMAIL PROTECTED] 
Sent: Monday, October 06, 
  2003 3:15 PM
To: Arun N. Kumar
Subject: RE: Serialization 
  across Virtual Machines


  Hi Arun,
             
  Thanx for your insight. I do think that encrypting the data stored is a better 
  way of doing things than changing the way things are stored. I did post 
  this question on BDOTNET. Could you kindly let me know where can i get 
  more info about your sessions on "XML Serialization".
   
  There is some aspects that is not clear to 
  me ...
   
  Can't serialization be used to speed up data 
  access? 
  i.e. If we use a memory image (binary byte 
  stream) of an object for storing data instead of reading from files with 
  formating (like in XML), which when read back, need parsing thus 
  increasing the time needed and also resources ... won't it be a better idea to 
  read back a binary byte stream and re-create an object? thus making it faster 
  (undermining the need to represent it in a standard format ... like 
  xml)?
   
  Can we serialize/de-serialize an object 
  to/from a stream of bytes and store it? ... Shoud it be always written in 
  a formatted file like xml... is there any other way?
  The main thing is that frequent xml parsing could be 
  very taxing.
   
   
  Regards,
  Raghavendra S Naik


  >>> "Arun N. Kumar" <[EMAIL PROTECTED]> 10/06/03 12:58PM 
  >>>

  Hi Raghavendra,
   
   
      Yes, I had done a 
  couple of sessions on "XML DataBinding or XML Serialization ". But I would like to 
add one more note. 
   
      In XML Serialization 
  the objects are converted to and from XML and the Sample used XML as the wire 
  format. Similar to SOAP. Since your requirement is not to use XML. I dont 
  think XML Serialization will help you directly. 
  
   
      Understanding "Object" 
  Serialization and Parsing them back into Java is possible but unadvisable, as 
  it is an internal representation and changes to either technologies breaks 
  your code.
   
      There are many ways a 
  .NET app could talk to Java App. The best approach would be via XML and/or 
  SOAP due to advantages like simplicity, feasibility and availability of 
  tools to get this done quicker. 
   
      One solution to your 
  problem to stop snoopy eyes could be to encrypt the content. I feel this 
  approach would be better as it is foolproof. If you override the serialization 
  process or the ToString method and generate the same still you are vulnerable 
  to snoopers as your data is not secure.
   
      Hope this helps. Would 
  be glad to help more. Post this on BDOTNET so others could also 
  benefit.
   
  Cheers!!!
  _____________________________
Arun N 
  Kumar<o:p></o:p>
  
  
  
Software 
  Architect
ZapApp India Private 
  Limited
Level G & 1, 
  <st1:place><st1:PlaceName>Explorer</st1:PlaceName> 
  <st1:PlaceType>Building</st1:PlaceType></st1:place>,
International 
  TechPark, <st1:address><st1:Street>Whitefield 
  Road</st1:Street>,
<st1:City>Bangalore</st1:City></st1:address> - 560 066. 
  <st1:country-region><st1:place>INDIA</st1:place></st1:country-region>
91-80- 
  5115 6050 extn. 4070 (phone)
91-80- 841 1858 (fax)
[EMAIL PROTECTED]<o:p></o:p>
  
<o:p> </o:p>
  
    
    -----Original Message-----
From: Raghavendra S 
    Naik [mailto:[EMAIL PROTECTED] 
Sent: Monday, October 06, 
    2003 12:02 PM
To: Arun N. Kumar
Subject: Serialization 
    across Virtual Machines


    
hi,<o:p></o:p>
    
   
    I was referred to you by a colleague of mine who is also a member 
    of the BDOTNET group. I hope you could help me in figuring out a way to 
    "serialize an 
    object in .NET and de-serialize it in JAVA". <o:p></o:p>
    
 <o:p></o:p>
    
The 
    catch is, XML/SOAP format 
    is not to be used. The serialized object 
    should be written in binary format. This is necessary to 
    avoid cognizance of the serialized data by an unauthorized person, which is 
    possible if the data is written in XML/SOAP format.<o:p></o:p>
    
<o:p></o:p>
     
    Some methods that i could think of 
were:
    
        Use the existing .NET serialization mechanism to 
      write objects. Create a parser which de-serializes serialized 
      data written by .NET (for this, i need to know the exact method/format in 
      which .NET writes serialized objects 
      ... Help needed!!!)
    
        Override the way/format in which .NET serializes 
      objects ... so that the format of the serialized data is a custom format. 
      (can this be done?)
    Your suggestions will be awaited.
     
    Regards,
    Raghu__________________________________________________
************** 
    Confidentiality Notice ************

Proprietary/Confidential 
    Information belonging to 
CGI may be contained in this message. If you 
    are 
not a recipient indicated or intended in this 
message (or 
    responsible for delivery of this 
message to such person), or you think 
    for any 
reason that this message may have been addressed 
to you in 
    error, you may not use or copy or deliver 
this message to anyone else. 
    In such case, you 
should destroy this message and kindly notify the 
    
sender by reply 
    email.
___________________________________________________
__________________________________________________
************** 
  Confidentiality Notice ************

Proprietary/Confidential 
  Information belonging to 
CGI may be contained in this message. If you are 
  
not a recipient indicated or intended in this 
message (or responsible 
  for delivery of this 
message to such person), or you think for any 
  
reason that this message may have been addressed 
to you in error, you 
  may not use or copy or deliver 
this message to anyone else. In such case, 
  you 
should destroy this message and kindly notify the 
sender by reply 
  email.
___________________________________________________


-----------------------------------------------------------

To stop getting this e-mail, or change how often it arrives, go to your E-mail 
Settings.
http://groups.msn.com/BDotNet/_emailsettings.msnw

Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help

For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact

If you do not want to receive future e-mail from this MSN group, or if you received 
this message by mistake, please click the "Remove" link below. On the pre-addressed 
e-mail message that opens, simply click "Send". Your e-mail address will be deleted 
from this group's mailing list.
mailto:[EMAIL PROTECTED]

Reply via email to