RMI Server that can host many client services

Hi there! Good day! I'm currently working on an RMI Project.
I have two RMI servers:
Payment Interface Server:
public class CU_PAY_COMPINTFC_Server {
   public CU_PAY_COMPINTFC_Server() {
     try {
       CU_PAY_COMPINTFC c = new CU_PAY_COMPINTFC_Impl();
       Naming.rebind("rmi://localhost:1099/CU_PAY_COMPINTFC_Service", c);
     } catch (Exception e) {
       System.out.println("Trouble: " + e);
   public static void main(String args[]) {
     System.out.println("...Server is waiting for connections...");
        new CU_PAY_COMPINTFC_Server();
Payment Interface Client:
I access the server by:
CU_PAY_COMPINTFC c = (CU_PAY_COMPINTFC) Naming.lookup("rmi://localhost:1099/CU_PAY_COMPINTFC_Service");
CC Server:
public class CU_CC_Server {
    public CU_CC_Server() {
     try {
         // Provide CU_CC_Service
            CU_CC_INTFC ccInterface = new CU_CC();
            Naming.rebind("rmi://localhost:1099/CU_CC_Service", ccInterface);
         System.out.println("CU_CC_Service Started");
        catch (Exception e) {
            System.out.println("Trouble: " + e);
    public static void main(String args[]) {
     new CU_CC_Server();
CC_Client:
I access the server by:
CU_CC_INTFC ccInterface = (CU_CC_INTFC) Naming.lookup("rmi://localhost:1099/CU_CC_Service");I'm just wandering, can i merge these two servers into one and be able to serve their particular clients? How can i do this? Thank you very much for your help!

hi ejp,
in line with your reply, is this how to do it? Or should I use Naming.bind instead? Thank you very much!
public class CU_MERGED_Server {
   public CU_MERGED_Server() {
     try {
       CU_PAY_COMPINTFC payInterface = new CU_PAY_COMPINTFC_Impl();
       Naming.rebind("rmi://localhost:1099/CU_PAY_COMPINTFC_Service", payInterface);
       CU_CC_INTFC ccInterface = new CU_CC();
       Naming.rebind("rmi://localhost:1099/CU_CC_Service", ccInterface);
     } catch (Exception e) {
       System.out.println("Trouble: " + e);
   public static void main(String args[]) {
     System.out.println("...Server is waiting for connections...");
        new CU_MERGED_Server();
}

Similar Messages

  • Need help with setting up a photolibrary on server that can be accessed/edited by multiple users

    Hi:
    I would like to develop an in-house photolibrary for our graphics department. The goal is to be able to add keywords to all our images so that we could have a more dynamic means of searching through our countless scanned images. Lightroom works great with regards to keywording and searching.
    To make it so all the computers in our office could have access to the images, I created a photolibrary on our server that can be accessed by any of the computers in our graphics dept. However, when one computer adds keywords to an image, that info does not show up on any of the other computers. Perhaps this is an issue with the trial version and we need to get the license? A few other people suggested that it might have something to do with my export settings - I tried to play around with the settings but had little luck...Any Advise?
    Thanks,
    Leo

    Thanks for your thorough reply. Is there a way to have one MASTER computer that could create the keywords and have the other computers access the master computer's catlogues - or something of that sort. We are small graphics dept. with three people so even that would suffice.
    Lightroom is not a networked application, and cannot be set up so that multiple computers can access LR via a network.
    The only real workaround with LR is to put the catalog and photos on an external HD and then physically connect the external HD to the computer of the person wanting to use it. So only one person can use the catalog at one time.
    You can look up Digital Asset Management (DAM) software on Google if you really need to have multi-user access and networked.

  • When attempting to use Firefox with TOR I get "Firefox is configured to use a proxy server that can't be found."even though neither is configured to use a prox

    After installing TOR Browser Bundle 2.2.37-2, I get "Firefox is configured to use a proxy server that can't be found." even though neither is configured to use a proxy

    Hi,
    If the TOR Browser Bundle is installed you would have two versions of Firefox: the original Mozilla Firefox and the customized TOR Firefox. You can try to start the Firefox that was installed by TOR. If you have security software (antivirus, firewall etc.) installed, you can try deleting all existing instances of TOR and TOR Firefox and its related processes/files in all the different configuration areas/modules of the security software like process monitoring, sub/spawned process control, virtualization etc. in addition to the main AV/Firewall module. Instead create new fully allowed/trusted rules for TOR and TOR Firefox + its related processes. Even otherwise some security software may also ask again when TOR/TOR Firefox is started and you can try to allow/trust at that time. Please see [https://support.mozilla.org/en-US/kb/Firewalls this].
    [http://kb.mozillazine.org/Firewalls AV/Firewalls Configuration]
    [https://blog.torproject.org/blog/new-tor-browser-bundles-20 Support]
    You can also try [https://www.mozilla.org/en-US/firefox/new/ updating the original Mozilla Firefox], set '''No Proxy''' in '''Tools''' ('''Alt '''+ '''T''') > '''Options '''> '''Advanced '''> '''Network '''> [https://support.mozilla.org/en-US/kb/Options%20window%20-%20Advanced%20panel?as=u Settings] and check.

  • Your calendar account isn't on a server that can't receive your calendar information securely

    I try to add my gmail calendar account, but this is the message I get: "Your calendar account isn't on a server that can't receive your calendar information securely"  What should I do?

    I assume you are not quoting the message correctly? Should it be "Your calendar account isn't on a server that can receive your calendar information securely"? Try going to the server settings and unchecking 'Use SSL' (if you have an older iCal version it may say 'Use Kerberos K5 for authentication' and this should be unchecked).

  • PS-script that can list all clients in a specific collection and if possible, point out direct members...

    CM2012Sp1Cu1 
    Need a powershell-function that can list all the clients in a specific collection, and then somehow define which of them are direct members. The most important thing for me is to list all the members but it would also be great if I could know which ones are
    direct / query members. 
    Very grateful for all the help I can get!
    TWP

    Here is a very simple example via PowerShell and WMI. It requires your collection id, site code and site server as input. It writes as output the collectionmember plus query, or direct.
    $CollectionId = ""
    $SiteCode = ""
    $SiteServer = ""
    $CollectionMembers = Get-WmiObject -Class SMS_FullCollectionMembership -Namespace root/SMS/site_$($SiteCode) -ComputerName $SiteServer -Filter "CollectionId='$CollectionId'"
    foreach ($Member in $CollectionMembers) {
    if ($Collection.IsDirect -eq "True"){
    $MembershipType = "Direct"
    } else {
    $MembershipType = "Query"
    Write-Host $Member.Name $MembershipType
    My Blog: http://www.petervanderwoude.nl/
    Follow me on twitter: pvanderwoude

  • PureFTP and //server/volume fails with many clients

    OES2 SP2 and Novell FTP/PureFTP
    Remote Browser paths fail with double slash //
    #cd //server/volume/data fails with many clients only Windows/Linux
    Command prompts works. IE and FireFox all fail.
    Works with Windows/Linux command line ftp.
    Thanks

    Originally Posted by DrumDude
    OES2 SP2 and Novell FTP/PureFTP
    Remote Browser paths fail with double slash //
    #cd //server/volume/data fails with many clients only Windows/Linux
    Command prompts works. IE and FireFox all fail.
    Works with Windows/Linux command line ftp.
    Thanks
    I am taking "fails with many clients" to mean that the method fails with "certain clients". (At first I thought maybe you meant, "once you have a lot of clients connected, it fails").
    This is due to limitations of Web Browsers as FTP clients.
    Even within the "standard" FTP world, it is generally accepted that Web Browsers make lousy FTP clients. This is especially true for use of this feature, which is definitely not "standard". Web Browsers make so many assumptions about what to do with a URL that you type in, or how to build the file links to what is found at the destination, that they just cannot make reasonable use of this special feature.
    This FTP "remote server navigation" feature was brought over from NetWare. Web Browsers couldn't make use of it then, either.
    I expect this navigation feature to work on:
    - command line clients
    - GUI FTP clients, *if* they allow you to enter an explicit command so you can enter the "cd" command manually, rather than just click to navigate.

  • Using a NAS as media server that can serve computeres and Apple TV directly

    What is the best configuration (performance/price/robustness) to have one single scalable, “backupable” location to store videos and music that can act as a media server accessible by several mac and pc computers as well as several Apple TV within the same house (knowing that the Apple TV would access the location directly not going through a computer).

    Not quite true. Apple TV can access NAS orginated stream if you share library. I have done this with GForce NAS. The problem is somwhere else. Sharing is limited to streaming music only at 128kbs. You can see all music on your NAS. NAS runs DAAP-MT server (linux based music streaming) for this which you likely need to enable manually (GForce NAS has this)
    Another nasty limitation is that you cannot share stream movies from NAS.
    That is the reason I have just bought Eee Box (PC with Win XP Home) and I hooked up number of USB drives with movies that I stream to Apple TV. This PC is very small and it takes very little power so, it can be placed in some corner (e.g. in kitchen when some appliances make noise anyway or in basement) and run 24x7. It will behave as NAS, but it will provide proper streaming of video (just install iTunes for PC on it). You do not need keyboard, mouse or monitor for this PC. I use Tight VNC to manage it remotely from one of my Mac computers... meaning Tight VNC service is run on Eee Box while Mac has built in VNC viewer that you can invoke from "Go to computer" window using following url:
    vnc://ipaddress_of_eeebox
    (BTW Tight VNC does not need viewer on any mmachine as it has built-in web interface for screen management - you just need to use browser on port 5800)
    To stream to Apple TV you need to enter those keys that are displayed by Apple TV. You do this via VNC.

  • Can I save and read text files on a server that I host?

    Hello everyone,
    I am a java hobbiest. I was wondering if I set up my own server, running out of my house, could I have my applets save to my computer and read from my computer without having to learn JDBC and a DATABASE language. In other words could i just have my applet save and read text files from and to my server?
    I'm trying to set up a sight for my 5th grade class where parents can log into. Thanks for your time.
    Oh yeah, which is easier, learning how to set up a server or learning JDBC and a DATABASE language?
    If you have any other good idease please tell me them
    Thank you, Bryan

    Short answer: This isn't gonna work
    Long answer: For this to work, the first thing you're going to need is a static IP address and a DNS name registered -actually you don't necessarily need #2 but you're probably gonna want it and it's by far the easier of the steps.
    As far as I know to get a fixed IP address you've either gotta be directly attached to a larger network (ie university network) or get a leased line from an ISP.
    Once you've got that done come back to us.

  • We use FMS Server 4.5,how many clients can connect one server (maximum number of connections)?

    As the title

    Jan,
    I do not think that there is a forced limit for as long as your hardware can sustain.
    It also probably depends from MQ vendor to vendor, and their JMS implementations.
    In one of my apps 10,000 subscribers was the practical celing due to the memory limitations. (On Solaris 8, 2 GB shared memory)
    In another that used open source JMS celing was much lower. due to its underlying EJB implementation (Linux).
    I would suggest a clean box test. Benchmarking, stress and load testing you middleware is always a good idea. It will give you a good idea what your app can and can not do.

  • Requirements for Cloud Server that can be access through RDC/RDP.....

    Dear Friends,
    There is a requirements to have some software(Accounting software) need to be access by 3-4 people simultaneously on the same system.
    For this i decided to have one cloud server and through Remote Desktop Connection they can access the same.
    Please suggest me what will be the limitations and cost for this.
    Thanks in Advance
    Deepak

    Thanks for your thorough reply. Is there a way to have one MASTER computer that could create the keywords and have the other computers access the master computer's catlogues - or something of that sort. We are small graphics dept. with three people so even that would suffice.
    Lightroom is not a networked application, and cannot be set up so that multiple computers can access LR via a network.
    The only real workaround with LR is to put the catalog and photos on an external HD and then physically connect the external HD to the computer of the person wanting to use it. So only one person can use the catalog at one time.
    You can look up Digital Asset Management (DAM) software on Google if you really need to have multi-user access and networked.

  • Limiting Applications that can run on clients via WGM

    In the midst of setting up a new primary school server and having some issues with the application filtering in WGM.
    I obviously need to stop the students accessing the utilities folder and various other apps on their 10.5 client machines.
    When ever I add all the apps I don't want them to access into their group prefs in WGM it will ask for a signature for the third party stuff and then on a client machine they cannot login at all (shakes)
    Any thoughts anyone?

    Hiya,
      I kind of doubt this is still a requirement given the age of the post, but please see my recent article :
    [http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/70ed80f3-5964-2e10-90b9-e833ade5e8c5|http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/70ed80f3-5964-2e10-90b9-e833ade5e8c5]
    It gives a step-by-step of getting SAP to talk to Google Desktop Gadgets.
    I think that the Imagineering(?) Team came up with a similar concept.
    All the best
    Patrick

  • What can't client connect to RMI server on same machine?

    I'm trying to get a client to connect to an RMI server that resides on the same machine, but it's not working. When run, I get the following exception:
    java.rmi.ConnectException: Connection refused to host: 121.0.0.55; nested exception is:
    java.net.ConnectException: Connection refused
    java.net.ConnectException: Connection refused
    at java.net.PlainSocketImpl.socketConnect(Native Method)
    at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:320)
    at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:133)
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:120)
    at java.net.Socket.<init>(Socket.java:273)
    at java.net.Socket.<init>(Socket.java:100)
    at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:25)
    The machine in question is a Solaris 8 system running Java 1.3. I've checked all the networking permissions, and they seem to be ok. Any ideas as to what might be causing this?

    Thanks for the reply! Dumb question: How do I start the registry? I see debugging code that indicates that the server is [probably] being started.
    Usually this means that the registry isn't running or
    the server isn't running.

  • How to keep track of client in rmi server

    how can I keep track of a disconnected client in a rmi server ?
    And what logic do I use to disconnect a client fro mthe server ?

    When a RMI client receives a stub to the remote object, RMI client runtime sends a dirty() call to the RMI server runtime which in turn helps the RMI server runtime in updating the client references to the remote object. Client reference is nothing but a unique identification generated by client RMI runtime for that instance of JVM. RMI uses a reference counting algorithm for destroying unreferenced remote objects. Once all references (all clients who are holding the stub to this remote object) to a remote object drops to zero, local garbage collector takes care of freeing this remote object.
    RMI client runtime initiates a TCP connection with the remote object only when a method is invoked on the stub. RMI transport layer uses a simple connection pooling mechanism to use already established TCP connections with server objects in further remote method invocations. Let's say the client is invoking a remote method on the remote object's stub fetched from the registry service. Now RMI transport layer initiates a TCP connection with the remote object (exported at ("host1", 4567)). After completion of the remote method, RMI client's transport layer keeps the connection open for some time (some configurable value) to take the advantage of the already established TCP connection in future remote method invocations on remote objects exported on the same host and port ("Host1", 4567"). RMI transport layer also takes care of closing these connections if the connections are idle more than configured value of connection open time.
    From the RMI server's perspective, once the RMI server runtime receives a remote method invocation request from the RMI client, it creates a new thread and try to dispatch the method on the designated remote object. After returning the results of the remote method to the client, RMI client's transport layer may not end this conservation with this remote object to take the advantage of this TCP connection in future remote method invocations. So the same thread may be used for dispatching another remote method in future. This is actually the side effect of re-using the established TCP connections on the client side.
    RMI server maintains client's reference in the client's reference set of the remote object as long as the client holds a normal reference to remote object's stub in its JVM. Once the client relinquishes the reference to the stub (goes out of the scope or setting it to the null), RMI client automatically sends clean() call to the RMI server runtime to update client reference set of the remote object. There is no public API to lookup or manipulate the client references for a given remote object, but you can always unexport the remote object even some clients are holding stubs to the remote object. Next time when the client invokes the remote method using this stub, client will receive a "connection refused exception" from the server because the remote object is already unexported. Let's say if the RMI server is started again (remote object is exported and registered with registry service), the client once again obtains the stub to the remote object from the registry service instead of using earlier stale stub. (This time remote object may have been exported on different port, so the port details in the old stub may not be valid any more).
    At any point of time there can be more than one established TCP connection with the RMI client. This may be the temporary condition; RMI client's transport layer automatically closes these connections if it does not receive any remote method invocation requests with in a pre-determined interval of time (default: 2 min). You can always find out RMI client's host in a given remote invocation by using getClientHost(), but how can you semantically define a "disconnected client in a rmi server" in your application context ? You can always force all the clients to fetch the stub again in future remote method invocations by unexporting the remote object in RMI server. I hope this information helps ...
    -- Srinath Mandalapu

  • Looking for a client/server that supports multiple protocol and delivery

    Hi all, I don't know if this the right place to ask my question,here it goes.
    I am looking to develop a client-server that supports multiple protocols such as HTTP, HTTPS etc. I am looking for a framework( i don't know if that is correct or I need some kind of web-service (soap etc)) that would manage connection, security etc. I would like to like to devote most of my time in developing business objects with multiple delivery mechanism such as sending serilized java objects, xml message or soap message, or in some case JMS message as well. So I need a client server that can come in via TCP/IP or HTTP or anyother industry standard protocol and I should be able to service him with pub/sub model and also request/response model as well.
    I don't know if I had explained what I need, I would like to know what technologies I should be evaluating and which direction I should be heading... Also the server I'm developing should be free of Java constraints if needed...
    Also this service is not webbased service as now but if need arises I should have a flexibilty to make them web enabled in future. Also I would like to work with open source webservers or appservers if I need

    Inxsible wrote:I installed i3 - along with the i3status - which I still have to figure out. I am liking what I see as of now. It reminds me of wmii -- when I used it way back when. However I do not like the title bar. I would much rather prefer a 1 px border around the focused window.
    "i3 was created because wmii, our favorite window manager at the time, didn't provide some features we wanted (multi-monitor done right, for example), had some bugs, didn't progress since quite some time and wasn't easy to hack at all (source code comments/documentation completely lacking). Still, we think the wmii developers and contributors did a great job. Thank you for inspiring us to create i3. "
    To change the border of the current client, you can use bn to use the normal border (including window title), bp to use a 1-pixel border (no window title) and bb to make the client borderless. There is also bt  which will toggle the different border styles.
    Examples:
    bindsym Mod1+t bn
    bindsym Mod1+y bp
    bindsym Mod1+u bb
    or put in your config file
    new_window bb
    from: http://i3.zekjur.net/docs/userguide.html (you probably already found that by now )

  • RMI Server as a service

    I've have a very simple RMI Server that handles authentication for a Java Web Start app. This server app has been running as a standard console app and now I want to run it as a service on a Windows Server 2003 box.
    I've tried Java Service Wrapper (http://wrapper.tanukisoftware.org/) and the built in tool in Windows for creating services (sc.exe) but no avail.
    I'm becoming desperate and have begun peeking at full fledged application server such as JBoss and Suns application server. Those guys should be a total overkill since my tiny RMI server is as far away from J2EE as you can come.
    Could someone provide me with some hints on this one? All I want is to have my server app run as a service, how hard should this be?

    Dear Sacke,
    Did you find anything on this front? I also need develop an RMI server and deploy it as Service (on Windows) and Daemon on Java. And I particularly dont want to use the Java Service Wrapper as it is not a pure java solution. Please let me know if you found anything on this?
    Thanks,
    Mehul

Maybe you are looking for

  • HT3819 can i add a samsung phone to my itunes account?

    My husband has a Samsung phone and I was wondering if I could add his device to my itunes account so that I can put our child's music on his phone.

  • Archive and Install Question

    I have an old version of Photoshop (7.0). If I upgrade from OS 10.2 to 10.4.6, Adobe tells me I also need to upgrade Photoshop. But if I do an "Archive and Install" Mac upgrade, can I still use the old photoshop on the old system. Thanks - I am not e

  • E mail association for outlook and adobe mail

    Hi, I have been trying to send e-mail via adobe.com {reader} and it says there is no e-mail association for this file type or something like that. I went into default programs and the list comes up, but what file would associate e-mail with outlook e

  • Monthly planned price in KP26

    Hi Experts, Could any of You pls help me how to handle monthly changed price in KP26! I would like to change and set planned activity price 4 times in a Year (per each Q), but If I simply enter the different prices in KP26 - the system calculates a s

  • Is it dangerous to use the IPad if the glass is cracked

    My iPad was dropped and the glass has cracks.  Is it dangerous to use?