Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

value object serialization

 
vijay kumarg
Ranch Hand
Posts: 105
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If we use a value object ,is it must that it should be serialized for robust design?
If I am not wrong , we use value object to pass data between different tiers of the application. What is the impact of serialization in this context?
 
Prabhu Venkatachalam
Ranch Hand
Posts: 502
Java jQuery Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In my opinion,

Is that Value Object contains one time values, then you can go for serialization.

If values changes frequently, then you should not.
 
Jaikiran Pai
Marshal
Pie
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If I am not wrong , we use value object to pass data between different tiers of the application. What is the impact of serialization in this context?


If the object is being passed across tiers, it might mean that the object will have to be passed across the wire. In such a case you will have to have the object as Serializable.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic