This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
I have a TCP/IP based component which is communicating with a c++ based system. In fact it is reading raw bytes from that system and then marshaling those raw bytes in objects and storing it in the DB. This multi-threaded tcp/ip based component is in java and cold be deployed on a dual core or quad core processor (not sure if its important for my question but nevertheless a detail i am giving). Now i have a few questions:
1. How can i scale this tcp/ip based component. This component is deployed on an server and is listening on a port. In future if there's more data that is envisaged at this point that comes from the C++ system we should be able to scale this java component.
2. What about security. One thing which i can probably do is employ this communication on secure sockets or probably get encrypted data (any particular encryption that i could use here??). Any other way to take care of security?
3. There is also a requirement of high availability to be satisfied. How do i handle that? How could i possible have redundancy here?
Yes, we are working on the system architecture of a product and therefore, i was wondering if some experienced architect or designer could help me please
1. varies on your design, there are a lot of ways to do this. My suggestion is to use ApacheMina on your tcp/ip communication as framework. check out http://mina.apache.org/ I would also suggest separating your tcp-ip component(different JVM if possible) with other components in charge of , for example, marshaling/marshaling of message, this is to isolate any error that could occur on such intricate process. also you get to have the freedom on how to handle your tcp component such as auto restarting etc etc.
2. see no. 1.
3. in terms of HA, there are a lot of products in the market that can provide you HA clustering (prime cluster, oracle, red hat etc etc) implementation for each varies.
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
subject: Scaling a TCP/IP based system and ensuring high availability