• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Run-time deployment is faster for mdb??

 
Ranch Hand
Posts: 61
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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
 
Author
Posts: 65
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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?

  •  
    srinivasrao marri
    Ranch Hand
    Posts: 61
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
    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
     
    reply
      Bookmark Topic Watch Topic
    • New Topic