Multiple applications on a single JVM

I was looking at some of the disadvantages of running multiple apps on a single JVM and then I came across this sentence which I donot totally comprehend. I guess somebody here would be able to shed some light
JVMs tend not to scale well past four processor configurations, which limits the viability of the single-JVM model on larger machines

It means a single JVM won't take as much advantageof
an 8 CPU system as multiple JVMs will.Yes I understand the lingual meaning of the sentence,
what I am struggling with is its semantic meaning.
Why can't a single JVM take advantage of 8 processor
r CPU? Are there any limitations associated with a
single JVM and in case there are what could they be?If I remember correctly the inherent concurrency limitations of JVM prevent it from fully utilizing the processing power of the machine. There is a limitation to the heap size one JVM can have, no. of thread pools that could be supported so multiple JVMs provide additional heap size, multiple thread pools, each corresponding to the application associated with the JVM, thus enabling to use the extra processing power.

Similar Messages

  • Multiple Applications in a single Project

    I currently have a Flex project that has multiple Applications created within it.
    The first application opens the second application via code as follows:
    var str:String="event_home.html";
    var link:URLRequest = new URLRequest(str);
    var v_selectedEventIDCode:String;
    this globalEventId = dg_event_listing.selectedItem.ID;
    navigateToURL( link, "_blank" );
    My 1st question is, can the 2nd application that I open grab values of variables declared
    within the application that opened it?
    2nd question is, if I have a project with only 1 application defined within it, how can I
    open a 2nd Internet Explorer window with some other Flex page in my project without creating a 2nd
    application in this project?  for example I may have a single Application in this project, and then another
    file in this project that is a Canvas component, the app starts up with the Application page, how do I open
    a 2nd Internet Explorer page with that Canvas component within it?
    Thanks in advance,
    Wes

    > Is it possible to package multiple applications into a single .air file?
    No, Flash Builder (and AIR) does not support that.
    -Anirudh

  • Running multiple java-apps in single JVM?

    We have about 125 Citrix clients running on 5 Citrix Servers. We are investigating a new very big development project which will cover about 10 main projects with 15 Applications each. The complete project will be written in Java.
    Basically, each module will have it's own JVM. BUt, when each client runs a couple of modules, the servers will surely run out of memory...
    I searched for way's to run different modules within 1 single JVM but it seems to be 'not done', because of 'System.exit()', 'Static Variable' probs to name only 2.
    Any idea's on how to implement this?
    thanks.

    thanks for the reply.
    Yes, I assume the server will run out of memory.
    1) Our citrix servers are consuming about 3/4th of their 4Gb memory capacity without any java_application running.
    2) Each of our 5 Citrix servers has 25 users active
    3) Each JVM takes about 20mb memory
    4) Each user will run at least 3 app's simultaneously
    Abouve results in 3*20=60Mb / user * 25= 1,5Gb memory extra needed.
    Can you give me an example of a Thread.sleep(60000) test_pgm?
    and/or an example for a "classloader" program to launch each app in its ow sandbox (in same JVM)?
    (eventually a link to get more info on this)
    thanks

  • Deploying multiple applications to a single collection quickly

    Hi,
    I've been looking for a way to quickly deploy multiple applications to a collection in the SCCM 2012 console. Is there any way to select a group of applications and deploy them all to be available to a collection? I can do them one by one, but I have a ton
    of applications to test and this is going to be very time consuming. If there is a powershell method, I would be open to that as well. Unfortunately, I couldn't find any topics on this on the forums or on the internet.
    Thanks!

    You also might consider to create an super application, and the set all other applications as dependencies to it (but NOT in the same group, only as separate groups). The super application will only modify a registry key or a file as a flag for detection.
    In that case you need to deploy only the super application. But I afraid it's against the best practices. I'm going that for a multi-component application to install all support components.

  • Multiple RMI servers in single JVM

    Hi,
    I have a RMI server listening to requests from internal network as well as external network. RMI returns the hostname as part of the stub. So to ensure that the subsequent RMI calls work fine I need to ensure that jama.rmi.hostname is set to correct value.
    With 2 network IPs on 1 machine (internal & external), one option was to use a domain name as hostname and set it as java.rmi.hostname. Unfortunately, my client is not allowing use of DNS. So the hostname can be set only as an IP address.
    Is there some way I can start 2 RMI servers in single JVM. While starting first one I can set hostname as internal IP and then while starting the other one I set hostname as external IP.
    Problem is I don't know if such a solution can be setup. I read somewhere that from jdk1.4, System.setProperty("java.rmi.server.hostname", "172.25.17.41"); will set hostname dynamically. So all future requests will use the latest hostname.
    Important thing is some way to make sure both networks can connect to my JVM through RMI.

    I get it, you're going down the path I hate. I have undone this so many times ... (essential when deploying RMI Proxies).
    Don't know why your intranet clients can't connect, unless it's the local binding of the server socket.
    If you must explore this horrible kludge around a Sun kludge (and overload the SF mechanism even further), you may as well go the whole hog and have the SSF corresponding to each CSF bind its ServerSocket to the local address that you're going to embed in the CSF. Then you really know who can connect and who can't.
    When writing SFs you need to think about what equality of socket factories really means. It only needs to imply that both socket factories being compared observe the same superimposed protocol (e.g. SSL), or that they both don't superimpose a protocol at all, so outbound or incoming calls really really can share the same port.
    SF equality generally doesn't need to extend as far as whether the embedded host names (in your case - ugh!) are the same, or the port numbers if you want go the whole hog and bypass the stub's remote reference info altogether.

  • Multiple selects() within a single VM

    Is anyone aware of any contention issues when running multiple threads within a VM where each thread has it's own select statement?
    I have an home grown app server that allows me to run multiple applications within a single VM. The applications are unrelated however they sometimes communicate with each other via TCP. All of them are very network intensive ( 500 messages a second where each message is around 200 bytes ). These apps are usually single threaded where the main thread is a select() loop.
    Therefore, each application is a single threaded select() loop but there are multiple applications running within a single VM.
    I am seeing performance issues when two apps running within the same VM try to send messages to one another via TCP. When the two apps are running on different boxes one app can send about 10,000 messages a second to the other app. However, when the apps are running within the same VM ( localhost TCP connection ) I can only transfer about 1000 messages a second.
    Are 2 selectors running within the same VM a problem? Is it synchronized within the VM so that only one select can fire at a time?
    I am running on a dual proc RH3 box with plenty of memory.
    Any ideas?

    Works for me, though I'm trying on Windows. Test program below. I get >10,000 replies and responses per second over loopback with both "java SelectPingPong both" (one VM) and running client and server on separate VMs.
    Does this program get only 1000 messages/s on Linux? What VM version?
    import java.util.*;
    import java.net.*;
    import java.io.*;
    import java.nio.*;
    import java.nio.channels.*;
    public class SelectPingPong
        private static final int MESSAGE_SIZE = 200;
        private String server_name;
        private Selector selector;
        private HashMap clients = new HashMap();
        static class Client
         ByteBuffer buf = ByteBuffer.allocate(MESSAGE_SIZE);
         long connect_time = System.currentTimeMillis();
         int number_of_messages;
        public SelectPingPong(int port, String server_name)
         throws IOException
         this.server_name = server_name;
         selector = Selector.open();
         ServerSocketChannel server_channel = ServerSocketChannel.open();
         server_channel.configureBlocking(false);
         server_channel.socket().bind(new InetSocketAddress(port));
         server_channel.register(selector, SelectionKey.OP_ACCEPT);
        public Socket connect(String host, int port)
         throws IOException
         SocketChannel channel = SocketChannel.open();
         Socket socket = channel.socket();
         socket.connect(new InetSocketAddress(host, port));
         configureSocket(socket);
         channel.configureBlocking(false);
         channel.register(selector, SelectionKey.OP_READ);
         clients.put(channel, new Client());
         return socket;
        private void configureSocket(Socket socket)
         throws IOException
         // Let's say we have a request-reply protocol with modest requirements
         socket.setReceiveBufferSize(1024);
         socket.setSendBufferSize(1024);
        public void mainLoop()
         while (true) {
             try {
              selector.select();
              for (Iterator iter = selector.selectedKeys().iterator(); iter.hasNext(); ) {
                  SelectionKey key = (SelectionKey) iter.next();
                  iter.remove();
                  if (!key.isValid())
                   continue;
                  if (key.isAcceptable())
                   acceptClient(key);
                  if (key.isReadable())
                   readFromClient(key);
             } catch (Exception e) {
              System.out.println(server_name + ": error in selector loop: " + e);
              e.printStackTrace();
        private void acceptClient(SelectionKey key)
         throws IOException
         ServerSocketChannel server_channel = (ServerSocketChannel) key.channel();
         if (server_channel == null)
             return;
         SocketChannel channel = server_channel.accept();
         if (channel == null)
             return;
         configureSocket(channel.socket());
         channel.configureBlocking(false);
         channel.register(selector, SelectionKey.OP_READ);
         clients.put(channel, new Client());
         System.out.println(server_name + ": got a new client; " +
                      clients.size() + " clients");
        private void readFromClient(SelectionKey key)
         throws IOException
         SocketChannel channel = (SocketChannel) key.channel();
         Client client = (Client) clients.get(channel);
         ByteBuffer buf = client.buf;
         int count;
         try {
             count = channel.read(buf);
         } catch (IOException e) {
             System.out.println(server_name + ": error reading, closing connection: " + e);
             clients.remove(channel);
             channel.close();
             return;
         if (count == -1) {
             clients.remove(channel);
             System.out.println(server_name + ": client disconnected; " +
                          clients.size() + " clients");
             channel.close();
             return;
         if (buf.position() == MESSAGE_SIZE) {
             if (++client.number_of_messages % 10000 == 0) {
              long now = System.currentTimeMillis();
              System.out.println(server_name + ": " + client.number_of_messages +
                           " messages in " + (now - client.connect_time) + " ms");
             buf.flip();
             // RFE write without blocking
             writeFully(channel, buf);
             buf.rewind();
        public static void writeFully(SocketChannel channel, ByteBuffer buf)
         throws IOException
         while (buf.remaining() != 0)
             channel.write(buf);
        private static void startClient()
         throws Exception
         SelectPingPong client = new SelectPingPong(6667, "client");
         Socket socket = client.connect("localhost", 6666);
         // Send initial message
         ByteBuffer buf = ByteBuffer.allocate(MESSAGE_SIZE);
         buf.put(new byte[MESSAGE_SIZE]);
         buf.flip();
         socket.getChannel().write(buf);
         client.mainLoop();
        public static void main(String args[])
         throws Exception
         if (args.length == 1 && args[0].equals("server")) {
             SelectPingPong server = new SelectPingPong(6666, "server");
             server.mainLoop();
         } else if (args.length == 1 && args[0].equals("client")) {
             startClient();
         } else if (args.length == 1 && args[0].equals("both")) {
             new Thread() { public void run() {
              try {
                  SelectPingPong server = new SelectPingPong(6666, "server");
                  server.mainLoop();
              } catch (Exception e) {
                  System.err.println("error in server");
             } }.start();
             startClient();
         } else {
             System.err.println("usage: SelectPingPong [client | server | both]");
    }

  • Multiple Standalone Persistence Manager Servers in a single JVM?

    Greetings [Kodo 3.4.1, Oracle9i]
    I am currently working on introducing the Kodo Standalone Persistence
    Manager Server into our architecture. One issue is that our application
    accesses several different databases, each via a separate
    PersistenceManagerFactory. This would mean (I think) that I would need to
    start a separate Standalone PM Server for every database, which would mean
    about 10 different JVMs running, just for the required Standalone PM
    Servers...
    The question... Will it be possible and sensible to run multiple
    "Standalone" Persistence Manager Servers within a single JVM? The idea
    would be for me to write a threaded server, where each of my threads invokes
    kodo.jdbc.runtime.StartPersistenceManagerServer.run(someJDBCConf), where I
    provide a JDBCConfiguration for each database I want to connect to. This
    means that my server will effectively be listening for clients on several
    different ports and accessing several databases all from within the same
    JVM.
    Is this feasible? Anyone with access to the source, can you say that the
    StartPersistenceManagerServer.run() method may be safely run in several
    different threads?
    I suppose another option would be to use the HTTP Persistence Manager Server
    and then simply deploy 10 servlets, one per database... But I'm trying to
    avoid introducing a servlet container into the mix.
    Thanks
    Drew

    Hi Marcus and thanks...
    Yes, I want to use Remote Persistence Managers. Currently we have a 2-Tier
    application, but we need to introduce a 3rd tier to be able to use the
    DataCache. If we don't do this, then each running application will have
    it's own DataCache, which will not "see" changes in other running
    application DataCaches. I have tried to attach a "before" and "after"
    diagram to illustrate...
    Now if we extend this a bit further, and say that instead of just one
    database, our application actually needs to access 10 different databases
    (so 10 different PersistenceManagerFactories and 10 different DataCaches),
    then hopefully it is clear that we would then need 10 separate Standalone
    Persistence Manager Servers. I have attempted to attach another diagram to
    illustrate.
    I don't really want to start up 10 Remote PM servers, I would rather just
    have one server, which brings me back to my original question... Can I run
    them all in a single JVM?
    Cheers and thanks
    Drew

  • Multiple web apps sharing same cache in a single JVM ?

    Is it possible to share cache across multiple web apps running in the same app server (multiple web apps, single JVM) ?
    Thanks for any info.

    Hi Bob,
    Cluster membership is scoped to the ClassLoader, so if your application server provides a ClassLoader-per-application, this will work fine.
    This is supported for both Coherence (NamedCaches) and Coherence*Web (HTTP sessions).
    Jon Purdy
    Tangosol, Inc.

  • How to configure single web server instance to multiple application servers..

    Hi all,
    we are running single instance of IWS6.0 SP2 on solaris, we want to comfigure this single instance to multiple application servers(JRun). Can any one advise me whether it is possible to do.
    Thanks
    Raj

    Hi Raj,
    "how to configure single web server instance to multiple application servers.."
    It's not possible for setting up multiple applicataion servers for Single iWS instance.
    Thanks,
    Dakshin.

  • One Search service application for multiple web applications in a single server

      We are planning to host 17 Web applications in a single Server. Do I need to create search service application for each web application or I need to create one  Search service application , create a Content source for each web
    application and create a Result source for filtering. Which is the best approach. And which approach takes more RAM memory.
       In my application I am using Search web part, "Recently Changed Items", "Popular Items" web parts. when I created only one one  Search Service application for all web applications and using Result sources ,
    I am not getting the results. What could be the problem.

    Hi,
    One SSA is ok, but you should think about access rights. If the access is clear cut between all the web apps you should be ok with one SSA. Multiple result sources limiting on content source also works, but could easily be bypassed.
    Multiple SSA's will eat up RAM/CPU like a mother :)
    As for popular etc.. it could be due to how those sources are set up, but haven't investigated or tested this much.
    Thanks,
    Mikael
    Search Enthusiast - SharePoint MVP/MCT/MCPD - If you find an answer useful, please up-vote it.
    http://techmikael.blogspot.com/
    Author of Working with FAST Search Server 2010 for SharePoint

  • Can we create multiple application with single MSI(or Same MSI) in biztalk admin console ?

    Can we create multiple application with single MSI(or Same MSI) in biztalk admin console ?
    My client requirement is process 100 files  from biztalk with in 5 min ,actually it is taking 20 min .
    So I decided to created same instance of the application with multiple time in BTS admin console ,as I understand biztalk admin console never allow to install same
    schema’s with multiple  time .
    Any help can be  appreciate ..

    BizTalk will automatically process multiple messages on separate threads so you may need to tune your system. The following link should get you started:
    http://social.technet.microsoft.com/wiki/contents/articles/7801.biztalk-server-performance-tuning-optimization.aspx
    Another possibility is to set the Batch Size property on your receive location if the adapter uses batch size to determine how messages are picked up.  As an example, it you want  the MSMQ adapter to immediately pick up messages and start
    to process them, set the batch size to 1.
    You may also need to distribute the processing across multiple BizTalk servers by installing BizTalk on additional servers and joining the existing BizTalk group.
    David Downing... If this answers your question, please Mark as the Answer. If this post is helpful, please vote as helpful.

  • Use of multiple Applications for single webdynpro component in ABAP WEB DYNPRO

    I am working on a object which have multiple webdynpro applications for single webdynnpro component.How to assign a different functionality to each application bcoz when we right click on webdynnpro component and select create webdynpro applications ,it just creates a application how so we assign diff functionality to each of them .Also in the parameter tab of the webdynpro applications ,there is a diff config id mentioned for each application.what is its relavance

    Hi Sam,
    Different functionalities for a single webdynpro component can be achieved by many ways. Among them is the use of multiple applications. Say for example if you want different views/windows to be displayed at the start up, you can achieve it by specifying at the default window, for each every webdynpro application.
    And if you want control the fields, say for example you want to display input fields as editable for one application and read only for other application, you can achieve it through application parameters. Based on parameters, in HANDLEDEFAULT method of window controller , you can specify the type of behaviour , whether it has to editable or not based on parameters and same can be used at context binding of UI properties. 
    Application configuration can be used for personalization.Web Dynpro ABAP Application Configuration. This tutorial would help you understanding the concept much better. There can be multiple application configurations for a single application.
    Regards,
    Harsha

  • 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.
              

  • Multiple Application Express Installs on one server

    What, if any, restrictions / caveats are there for installing multiple Application Express versions on a single server? We have Application Express 2.2 installed and wondering if we can install Application Express 3.0 also.
    With 2.2, we have FLOWS_020200, FLOWS_FILES, and APEX_PUBLIC_USER as database users. Version 3.0 will want to create FLOWS_030000, FLOWS_FILES, and APEX_PUBLIC_USER. Any problems with what I expect will be errors on "user already exists" for FLOWS_FILES and APEX_PUBLIC_USER?
    Thanks in advance.

    Hello,
    I'm really sorry but this is a typo on my part. It should be "You can't have two different APEX versions on the same instance."
    Does it mean that if we install ApEx v3 we will have only ApEx v3?Yes. This is exactly what it means. The installation script automatically detect previous installed APEX (or earlier HTML DB ) version, and upgrade it. You can end up with only one version per instance.
    Regards,
    Arie.

  • Multiple application instance on the same server instance

    Can we have multiple instances of the same application on a single WLS?? For ex, can I have two app.ear files in different application directories??
              

    Hi Nilesh,
    Can you please clarify your landscape as this will help in getting answers to your question.
    In general adding instances (and/or server nodes) should be considered for increasing capacity rather than impoving performance. Specifcially, adding instances (and/or server nodes on the same host you risk a situation where the processes compete for resources which will have a negative effect on performance. If you do need to combine instances on the same host, make sure there is enough hardware (specifically memory in case of JAVA).
    Hope this helps,
    Best regards, Walter

Maybe you are looking for

  • I want to erase everything on the hard drive and have snow leopard which is the operating system now left

    i just brought a laptop on ebay with snow leopard on it and alot of programs i dont want. i want to erase everthing and end up with the snow leopard amd i can buy ilife which i want.

  • How to add attachments to Webdynpro Application?

    Hi All, I have a requirement wherein I need to add supporting documents to a Webdynpro application online. The attachments can be of any type and any number of attachments can be added. If any of you had worked in such a kind of requirement please gi

  • Can't Open jpg and other attachments

    Since this new email took over, I cannot open jpg and some other files that are sent to me.  Word and pdf's are okay, but not photos that are attached.  A pop up says they were deleted. This is just since the new mail version arrived. How do I get my

  • Parmeter testing condition

    I am converting some ingress procedures into PL/SQL and have a situation where based on the results (i.e. rows returned) I execute different code. So I have a v_file_name_found parameter that is defined locally to the procedure. The procedure is pass

  • Service Master Upload way

    Can anyone tell me what is the way to upload service master?? I have created simple LSMW for the upload but it works in foreground only.In background it gives an exception error