Multiple sockets - many client one server

I have multiple clients (a handfull) that will be sending a lot of messages per second. I have one server that I want to handle all of those methods. From what I've seen, there are some good multi-threading examples out there. I have seen one or two things about using socketchannels. what is the best approach to this problem, and how does it work?

jobocop17 wrote:
I have multiple clients (a handfull) that will be sending a lot of messages per second. What is a "lot"?
10 or 10,000?
Is that the sustained rate or the burst rate?
What is the size of each message?
What processing must occur for each message?
Must every message succeed? Must it succeed the first time?
I have one server that I want to handle all of those methodsSimply might not be possible depending on the answers to the above. Or might be trivially simple.

Similar Messages

  • Multiple users logged into one server, each users printer has a different name, application needs ONE name to print to.

    Multiple users logged into one server, each users printer has a different name, application needs ONE name to print to. 
    I'm NOT in any way a Terminal Services expert and I need help trying to get an application program working in a multi-user environment.
    The issue is that the printer changes for every user that is logged in. The application needs to print NOT to the default printer, but to a "special" printer which is selected in the application... let's call it a label printer to simplify the explanation.
    You have your default regular printer, easy for the application to find that one, and then you have a special printer that labels get printed onto. The application needs to know what printer is the label printer. So we allow the user to select that in the
    application and the selection is stored in a config file in 
    C:\ProgramData\mfgr\prog\setting files
    I don't have access to the application so I can't change how this works.  
    In the "regular" world, selecting the label printer driver to use should be per machine, NOT per user. When a new user logs into a machine, the physical printer doesn't go "poof" and a new printer suddenly appear. Same printer for all
    users.
    Yet in terminal services, the physical machine is "merged" with the virtual machine on the server. And there can be many users logged in at the same time. So each users real machine (and real printer) is injected into the "fake" terminal
    services machine. The name of the printers is made unique for each user. So the printers DO go "poof" and change names depending on the user logged into terminal services.
    So user "A" logs in and sets up the application to print to "LabelPrinterForUserA" (or whatever the name of the printer happens to be), that setting is stored in the ProgramData subfolder, and all is well. Later, user "B" logs
    in, and when they print, the application tries to print to "LabelPrinterForUserA" which doesn't exist for user B or is only accessible by user A. If user B re-configures, that breaks it for user A. 
    SOLUTION 1: The way that /should/ work (in my mind) is that you define one "generic" printer in Terminal Services... call it "Virtual Label printer" and when the user wants to print to it, the print job gets re-directed back to whatever
    physical printer is actually connected to their local workstation. There is a map of virtual printer to actual printer depending on the current user. The application is told once to print to "Virtual Label Printer" for all users.
    SOLUTION 2: Or... there should be some way to make the ProgramData sub folders separate per user. E.g. when user "A" tries to access:
    C:\ProgramData\mfgr\prog\setting files
    they actually get 
    C:\UserData\UserA\AppData\mfgr\prog\setting files
    and user "B" gets
    C:\UserData\UserB\AppData\mfgr\prog\setting files
    So the question I have is: Does either of those solutions exist hidden somewhere in the setup of terminal server? Or is there another way around this issue that I don't know?

    I don't really have a "for sure" answer to this, but because people here can't seem to deal with a question that hasn't been answered I'll provide the best answer I did receive from ServerFault.com user Nathan:
    I can feel your pain with using old software on terminal servers ...the solution I've come up with definitely won't scale as it requires some manual configuration, but I've gotten this method to work with our label printers (which require to be
    printed to an LPT port...yep, that old).
    Share your USB-connected printers to the network on each machine. Then, have the user log in on aunique session for each of them
    (a TS account cannot be shared among computers for this to work) and install a network printer pointing to the USB one they shared. Try to use a DNS name to account for possible DHCP movements.
    After, it should work. Each user can do this since display names can be identical as long as the ports are different (which they are).
    This was clarified by the following series of comments:
    I think you are on to something here, and I originally advised the admin to do this. The problem he ran into is that it setup the printer names in the TS as "printer on usersworkstation"
    and he could not rename it except to change the "printer" to whatever. E.g. the "on userworkstation" remained. I believe there is another way of installing the printer which avoids this, but I can't find it. Ages ago, one used to do NET
    USE LPT2 \\computer\printer password /USER:domain\user /PERSISTENT:YES and then tell the driver to print to LPT2 –  James
    Newton Mar
    17 at 16:21   
    @JamesNewton That's actually the exact method we used. The way around the "network printer" part is to install it as local printer and map it to a TCP/IP port that way. –  Nathan
    C Mar
    17 at 16:28
    You mean in the case where the printers are TCP/IP connected and not local USB / LPT to the users workstation? That makes sense. Wonder if this will work for USB connected printers... –  James
    NewtonMar
    17 at 16:35   
    @JamesNewton You'd share the local printer on the client's PC then on the server connect via TCP/IP to it. You'd need static addresses or use DNS names if DHCP, though. –  Nathan
    C Mar
    17 at 16:51
    Ah. Yes. I see. Looks like the LPT thing should work even with a USB connected printer:superuser.com/questions/182655/… –  James
    Newton Mar
    17 at 17:09   

  • How do I install multiple KMS keys on one server?

    I currently am working at Phelps County Regional Medical Center in Rolla, MO and my question is: How do I install multiple KMS keys onto one server? This is very urgent and I have the KMS activating Windows 7 but, I also need all my Office keys, Windows
    8, and Windows 8.1  to be activated via KMS. the current KMS is a Windows Server 2008 R2 server. Please help me out and thank you for your time! :)

    you need to apply the following update (http://support.microsoft.com/kb/2885698)to your KMS server so you can license up to Windows 8.1.  From there your key for 8.1/2012R2 will license everything
    downwards and then you can also install your Office KMS key without issue.  If its Office 2013 then you need to download the files here (http://www.microsoft.com/en-us/download/details.aspx?id=35584) 
    Be kind and Mark as Answer if I helped.

  • RE: How to have multiple application running under one server

              I have one server
              I have many application
              Question: Is it possible for me to have a weblogic properties file under each
              of this application.
              

    If your question is whether you can run multiple instances of WebLogic
              (or multiple applications) on one server, the answer is yes. The only
              problem is, you must have a unique port for each of the servers to run
              on. I.e., they can not all run under port 80 which has obvious
              internet/network implications.
              This also means you have multiple weblogic.properties files etc. for
              each instance.
              We do this with WL5.1 on a Linux 2.4 kernel in developement to allow
              multiple developers run their own instance on one box.
              Dano
              Mettu Kumar <[email protected]> wrote in message news:<[email protected]>...
              > No if you are running single instance of wls.
              >
              > Kumar.
              >
              > Sonny wrote:
              >
              > > I have one server
              > > I have many application
              > > Question: Is it possible for me to have a weblogic properties file under each
              > > of this application.
              

  • How to send multiple objects from Client to Server

    Hi
    I have a simple Client - Server architecture. I am trying to send 5 objects from Client to the Server which the server would operate on.
    In the past I've used PrintWriter to pass Strings from Client to Server but now when I am dealing with multiple Objects and PrintWriter not allowing sending of Arrays or ArrayList, how can I send these from the Client to the Server? What would be a good writer to use for this purpose?
    Thanks!

    Thanks, I am looking into ObjectOutputStream but from the API it appears I can only send 1 object at a time. I need to send 5 objects per transaction and then send the next group of 5 objects for another transaction.
    Could you clarify some more on how to put these objects together as a single Object perhaps?
    Thanks

  • Multiple email address with one server account

    Why can't Mail have multiple email addresses on one email account? Like Thunderbird calls them Identities. As I remember, Outlook also supports this. I like Mail but it seems rather dated and clunky in this respect.
    I am using mainly IMAP so maybe I should switch to Thunderbird but I do still have some old messages in pop accounts in Mail.

    You can have multiple accounts, but only one "identity." Configure new mail accounts for all the different email addresses you may have. They can each have different configurations, different servers, etc. as well as be individually made active or inactive. All incoming mail will funnel into a single Inbox, but you can use rules to transfer incoming mail to separate mailboxes based on the account.
    What you cannot have are distinct "personalities."
    Bear in mind that Mail is intended for a single user and the vast number of single users only have one email account. I actually have four different email addresses but three of them are set to forward mail to the account I use with Mail. Mail works quite well with IMAP, POP, and Outlook mail accounts.

  • Multiple database instance on one server

    Hi experts
    We are planning to implement ERP, BI, Solman, CRM and MDSD on windows/oracle platform. There is an idea about system landscape that all database instance of production systems are installed on one server and central instances of each system are installed on separate servers. Is there any performance or maintenance risk about this scenario? What is the advanteges and disadvantages of this landscape? Shall we prefer central system installation?
    I'm waiting for your recommandation.
    Best Regards...

    Hi,
    From experience one disadvantage in having an Oracle farm, is if the server plays up
    or needs a reboot you of course lose all the systems databases.
    Also getting all customers to aggree a maintenance slot together can be a pain.
    Failover needs to be considered, DR also.
    IMHO separate servers, but that is my preference I'm sure there are advantages.
    Mark

  • Multiple sockets connected to one port

    Hello I am running a LabVIEW VI that is based on the Labview TCPServer example. I am wondering what the best way to deal with multiple connections to a single port would be. For example I have a device(could be thought of as the same thing as the TCPClient vi) that connects to the server using the port number and the IP address. The communication works fine when there is only one device trying to connect to the server, the problem occurs when two devices try to connect to the server. When the first device connects all data sent shows up fine, when the second device connects, the status on the device indicates a proper connection but none of the data sent shows up on the server side. I assume that I must do something with the connection ID to distinguish between the two connections, but I was wondering if there was an example or something that deals with this issue, or if someone would like to explain how I could get the data to show up properly. Any help is appreciated, thanks!

    I am hoping that there is something similar to the java api where there is some way I can start a new threads to handle multiple connections on the same port. I would assume that if java has it LabVIEW would have something similar. Unfortunately I am not sure how to go about finding out how to do such a thing in LabVIEW.
    The way that I assume the TCPListen.vi works is that there is some mechanism polling the specified port and ip address waiting for a request for a connection. Once a request is received the VI creates a connection ID so that the other subvi's can perform operations on the specific connection. It also looks as though the TCPListen.vi continues to listen for new connections, because the clients indicate a connection when more then one of them are run trying to connect to the same port and IP.
    So my question is either, how to start a parallel process to handle the new connections, or where can I find the new connection ID (because the indicator only shows the connection id of the first client to connect). Basically I am having trouble distinguishing between the multiple connections on the same port.I would like to keep all of the clients sending data through the same port if possible.Each client identifies itself in its data message so keeping the data organized is not a problem. 
    I also looked at the data socket examples, mainly because the Java examples I was looking at used "Sockets". I ran into similar troubles finding a way to create distinguishable connections using DS's as well. Anyways, any help is appreciated. Thanks.

  • Multiple Apex Listeners on one server trouble with apex-config.xml

    I'm using 0C4J to deploy apex on a windows server. I want to be able to have multiple instances of OC4J running pointing to different databases. I've read through documentation and forum posts and this looks simple enough.
    I've got one instance running at E:\OC4J and working fine. I've to added a second OC4J instance at E:\OC4J2. I've rebuilt and redeployed the apex.war file after editing web.xml to specify a new location for apex-config.xml. I'm trying to specify the config directory as E:\OC4J2\config but can't seem to get the syntax right, because it keeps picking up the default file the first OC4J instance is using.
    <context-param>
    <param-name>config.dir</param-name>
    <param-value>E:\oc4j2\config</param-value>
    </context-param>
    I've tried multiple versions of the path E:\oc4j2\config, E:/oc4j2/config, /oc4j2/config, \oc4j2\config but none seem to work.
    Could anybody confirm the proper syntax for specifying the path to apex-config.xml in web.xml on a windows server?
    Thanks in advance

    Got it working
    Had the syntax right.
    <context-param>
    <param-name>config.dir</param-name>
    <param-value>E:\oc4j2\config</param-value>
    </context-param>
    Issue seems to be if there is an apex-config.xml file at C:\Users\username\AppData\Local\Temp\apex it picks up on it first.
    Once I had both web.xml files specified to different directories for the config file and I deleted the one at C:\Users\username\AppData\Local\Temp\apex things worked as expected.
    Thanks

  • Multiple broker instances on one server

    We are running multiple OpenMQ 4.4u1 broker instances on a single server (two different environments, one development and one staging). It appears as though the RC file I installed in /etc/init.d on our RHEL server is designed to manage one and only one broker instance (using the $IMQ_ETCHOME/imqbrokerd.conf file).
    Is there an elegant way to have the single RC script manage multiple instances, or should I just create a second RC file and a second $IMQ_ETCHOME/imqbrokerd.conf file to manage the second instance?
    Thanks,
    Bill

    Yes, the MQ RC script is for 1 broker instance only. On Solaris, it's possible to use SMF to manage multiple processes/services. You may want to look for something similar on RHEL or clone/customize the RC script, imqbrokerd.conf and relevant links in rc?.d for each instance

  • Moving multiple reporting servers to one server

    Our current environment consists of several 2008 r2 native reporting servers that have there own reporting database.
    Our new environment will be a load balanced 2012 native report server that will use one 1 SQL 2012 reporting database.  How would I go about migrating all the 2008 R2 databases into 1 central database.  I have read up about some migration tools
    that are available but I'm not sure if the tool(s) will allow the option for specifying a specific database, which will allow all the content to moved.
    Any advice would be appreciated.
    Thanks!

    check this thread it might help you
    http://social.msdn.microsoft.com/Forums/sqlserver/en-US/ef79afea-320f-466b-a333-dc3547da7e37/merging-multiple-report-server-instances-into-one?forum=sqlreportingservices
    Regards, Ashwin Menon My Blog - http:\\sqllearnings.com

  • Deploying Multiple interacting applications in one server

    I have sub application A deployed and have created an ear and deployed it . Similarly i have main application B and have created an ear and deployed it in the same server .I want to now call some methods in application B from application A. What are the steps that i need to follow to do the same ? And how would it work. ?

    Tom Kyte has an excellent discussion about his opinion on the matter (he's a strong proponent of one database with multiple schemas).
    http://asktom.oracle.com/pls/ask/f?p=4950:8:::::F4950_P8_DISPLAYID:4347545437371
    The only downside I see to having multiple schemas is that all the applications would need to be on the same version of Oracle, so they'd have to upgrade in lock step. For custom applications, this is generally doable, but for third party apps, it may not be. If vendor A demands Oracle 9.2 and vendor B still hasn't certified on Oracle 9, you may have some problems.
    Justin
    Distributed Database Consulting, Inc.
    www.ddbcinc.com

  • Multiples web pages in one server and one ip

    please help me,
    i need a web server with multiples web pages,
    one for each person. but i only have one ip.
    how could i do this. I need to program some kind of dns server?. or what.
    i have heared that this is called dns dinamic or redirecting.
    please help me!!!!!.
    of course programming in java.
    thank's.

    You can just give the web pages different file names and you will have multiple web pages, but I suppose you mean that you want seperate url's to point to each user?

  • Netbooting - how many clients per server?

    Hello,
    I am looking in to having mac mini server (current version/dec 2012) to host about 60 clients, majority as netbooters, also maybe with a couple of extra remote VPN clients.
    However besides gigabit ethernet connection defined here as the requirement, there is no note of how many servers would I need for netbooting the clients?
    Does anyone have experience with this kind of setup? (similar to a kiosk environment)
    Thanks in advance.

    I would be concerned if more than 20 clients were trying to netboot at the same time.  Theoretically, you'd be okay with perhaps 200 clients as long as you could be sure that wasn't going to happen.
    Under normal conditions, ignoring maintenance and other unusual occasions ... are these clients booting
    once a day every morning, roughly at the same time as each other
    twice a day, but a random unsynchronised times, no more than 5 at a time
    only when power has been disconnected (rare)
    I gave three examples, but if you want to describe your situation more closely that may prompt someone familiar with that kind of setup.

  • Multiple websites on one server

    I've been trying to create multiple (two) websites on one server, with little luck. One sight works fine. I've tried creating a DNS entry for the new one, but I'm not sure what to set the IP to. I've tried many configurations of IP/hostname but nothing seems to work. Occasionally, the logs just disappear from the logs window.
    I've read on here that it's possible to run multiple sites off of one IP, so I feel like that is not the problem. Ideally, I'd like to have one of the sites not exist in the System/WebServer folder. If I place the site folder outside of that folder, do I have to add its folder as a share point and/or modify its permissions?
    Server version is 10.6.3

    I'm going to distinguish the web browser (client), the web server, and the DNS server here, and will treat these as running on three separate computers. You might have one or more of those co-located on one box, adjust these references to your configuration as necessary.
    The DNS translations are applicable only on the client; on the host box that is running with the web browser. The web server doesn't care about the DNS translation. The client needs the DNS to get the IP address of the web server, and it's off to the races from there.
    Again, DNS translations are not relevant the web server. The particular web server that gets selected (Apache Virtual Host, what Apple calls a "Site") based on some information that is passed within the http (don't start working with https quite yet) connection from the web browser into the web server.
    As for your DNS question, you'll probably want a CNAME (alias) entered in DNS database for the virtual hosts, even if you're awash with IP addresses. That alias must then match the name of the web server "Site". For testing, you can enter what amounts to CNAMES into /etc/hosts on the client, depending on your local set-up and your DNS server.
    By default, the connections to all virtual hosts are via port 80. Stay there for now.
    The web server selections are sensitive to the order of the "Sites" in the listing in Server Admin, too; you'll want the wildcard site (if you have that) at the end of the list.
    Here are some of the basics: [Apache Tips: One Web Server, Multiple Distinct Web Sites|http://labs.hoffmanlabs.com/node/1282]. Comments on that are welcome.

Maybe you are looking for