× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



The easiest option I can think of is to submit a job for each host.
Write a small new program that reads the data queue data and duplicates
the data to a physical file.  Change your socket program to read data
from this file instead of the data queue.  

Example:
Let say your original socket program is SOCPGM that read from dataq
SOCPGMQ.
- Create a new program (SOCSPAWN) that simply reads from SOCPGMQ data
queue and write the data to a file (SOCPGMPF) that is key by host ip.
- Change the SOCPGM to accept host ip as a parm and reading data from
SOCPGMPF by ip and process it.

=> You'll probably need to create a host control file and a driver job
that submits the SOCPGM program for each host that setup in this file.
This file will also be used by SOCSPAWN to determine how many host
records to duplicate.  




-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of
mgarton@xxxxxxxxxxxxxxx
Sent: Monday, July 24, 2006 10:27 AM
To: midrange-l@xxxxxxxxxxxx
Subject: Socket Application Question

I have a socket application that receives messages from a data queue and
send the message to a remote host via sockets.  Currently the
application uses a single persistent socket connection.  However, the
application needs to be changed so that sends messages to four different
hosts for redundancy.  I am not sure the best way to switch between
sockets.  The easiest way to change the application would be to just
switch between sockets but each time I send a message it would have to
wait to receive a reply before processing a new message.  That doesn't
seem to be very efficient.  I would like to be able to send/receive
messages on all four socket connections at the same time but I don't
know how to do this.  I have very little socket programming experience
so any help would be appreciated. 


Mark Garton

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at http://archive.midrange.com/midrange-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.