wood burning stoves*
The moose likes BEA/Weblogic and the fly likes Run-time deployment is faster for mdb?? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » BEA/Weblogic
Bookmark "Run-time deployment is faster for mdb??" Watch "Run-time deployment is faster for mdb??" New topic
Author

Run-time deployment is faster for mdb??

srinivasrao marri
Ranch Hand

Joined: Feb 13, 2001
Posts: 61
i have a servlet having a lot of functionality, where its taking nearly 15 to 20 secs to get the o/p, inorder to reduce this time i want to go for message driven beans which is asynchronous, where the processing will be fast, and i want to deploy this bean during run time.
how can i do this in weblogic 6.1?
is it a right way to proceed like this?
Thanks
srinivas
Aaron Mulder
Author
Ranch Hand

Joined: Feb 25, 2003
Posts: 65
I guess I'm not clear on what your asking. So let me post a couple thoughts, and maybe you can clear this up for me:
  • You have a servlet doing a lot of work, it takes too long.
  • You're considering moving that to a MDB so the client doesn't have to wait for the result
  • The client will poll the server to see if the work is done? Another servlet will see if the MDB posted a message indicating that it was done? Or the client just starts the work and doesn't care whether it finishes?
  • What do you mean by deploying at runtime? You mean, when the work comes in, you want to create a new queue for this specific task and deploy a new MDB to handle just that bit of work, and then have the MDB and queue go away when the work is done? Wouldn't it be easier to just have an always-on queue and MDB and post a message with some sort of task identifier?


  • <a href="http://www.javaranch.com/bookpromo.jsp" target="_blank" rel="nofollow">WebLogic Book Giveaway</a> 2/25-2/27
    srinivasrao marri
    Ranch Hand

    Joined: Feb 13, 2001
    Posts: 61
    Plz refer below for clarification.
    I guess I'm not clear on what your asking. So let me post a couple thoughts, and maybe you can clear this up for me:
    You have a servlet doing a lot of work, it takes too long. You're considering moving that to a MDB so the client doesn't have to wait for the result The client will poll the server to see if the work is done? Another servlet will see if the MDB posted a message indicating that it was done? Or the client just starts the work and doesn't care whether it finishes?
    ----
    Yes u r right that currently servlet is doing lot of work so it takes long.When the teacher is scanning answer sheets, each sheet takes arould 15-20 sec for getting scanned which is not acceptable. so some portion related to database has been put in ScanningMDB. So now when the teacher will scan, he will get the message, 'scan successful' and he'll be able to scan a new sheet. On the server side ScanningMDB will be doing the database work. So this way teacher's work will be over soon. So during scanning, scanningservlet will call methods written in ScanningMDB and proceed ahead. Yes, scanningservlet doesn't have to bother whether the work finishes or not.

    What do you mean by deploying at runtime?
    -------
    Deployment at runtime means deployment at startup of the ems server. i think using the term 'Deployment at runtime ' is wrong. ScanningMDB should be deployed as any other EJB when the server starts.

    You mean, when the work comes
    in, you want to create a new queue for this specific task and deploy a new MDB to handle just that bit of work, and then have the MDB and queue go away when the work is done?
    ----
    no i dont mean this.

    Wouldn't it be easier to just have an
    always-on queue and MDB and post a message with some sort of task identifier?
    --------
    yes i've added the entry for queue in config-tokenized.xml and that solves thepurpose, i get an always on queue which will handle the messages.
    i hope now things r clear.
    Regards,
    srinivas
     
    I agree. Here's the link: http://aspose.com/file-tools
     
    subject: Run-time deployment is faster for mdb??