Results 1 to 10 of 10

Thread: how to invoke a servlet from zimlet

  1. #1
    Join Date
    Jun 2006
    Posts
    6
    Rep Power
    9

    Default how to invoke a servlet from zimlet

    hi
    is it possible to invoke a servlet from zimlet
    if so, where should i place the .class file in apache-tomcat and what is the url i have to pass in the zimlet
    i tried to place the .class file in ,apache-tomcat/webapps/service/WEB-INF/classes and by default the port number for apache-tomcat is 8080 but when i pass the url as http://localhost/....
    iam getting permission denied error
    should i make any changes in apache-tomcat/conf file

    thanking you
    with regards
    srinath

  2. #2
    Join Date
    Aug 2005
    Location
    San Mateo, CA
    Posts
    4,789
    Rep Power
    19

    Default

    Best way is to write a JSP and put that JSP in your Zimlet zip file. It will get deployed with the Zimlet. In 3.2 you can also include a .jar file that will get added to the class path.
    Looking for new beta users -> Co-Founder of Acompli. Previously worked at Zimbra (and Yahoo! & VMware) since 2005.

  3. #3
    Join Date
    Jun 2006
    Posts
    6
    Rep Power
    9

    Default

    hi kevin
    thanks for the reply but still iam having a doubt as to where i have to place the servlet(.class file)
    iam using zimbra 3.1.3 version
    thanking you
    with regards
    srinath

  4. #4
    Join Date
    Jun 2006
    Posts
    6
    Rep Power
    9

    Default

    hi kevin
    thank you verymuch
    i was able to invoke the servlet directly
    with regards
    srinath

  5. #5
    Join Date
    Jul 2007
    Posts
    17
    Rep Power
    8

    Default Could you please tell me how to do invoke servlet from Zimlet?

    Could you please tell me how to do invoke servlet from Zimlet? I have been searching this from a long time. I need it very urgently.

  6. #6
    Join Date
    Sep 2008
    Location
    Sydney, Australia
    Posts
    4
    Rep Power
    7

    Default

    look at the ZimletJS and ZimletJSP topics I have been working on.


  7. #7
    Join Date
    Sep 2008
    Posts
    25
    Rep Power
    7

    Default

    Quote Originally Posted by srinath View Post
    hi kevin
    thank you verymuch
    i was able to invoke the servlet directly
    with regards
    srinath
    Can you or someone explain how do you get it?
    I would like to invoke a servlet from a zimlet.

  8. #8
    Join Date
    Jul 2007
    Posts
    17
    Rep Power
    8

    Default I want to invoke Servlet not jsp

    Hello SvenDowideit,

    I don't want JSP. Instead I would like to invoke a servlet directly from Zimlet.

    Hello Srinath,

    I saw your reply in which you have said that you were able to invoke servlet from Zimlet. So could you please tell how you did that?

  9. #9
    Join Date
    Jun 2006
    Posts
    6
    Rep Power
    9

    Default

    Anuradha,
    Sorry for my late reply
    1) write your servlet program and place it in the zimbra server's tomcat folder "tomcat home directory/webapps/root/web-inf/classes"
    2) in your zimlet code specifiy the path(url) of the servlet
    cheers
    srinath

  10. #10
    Join Date
    Jan 2009
    Location
    Denmark
    Posts
    7
    Rep Power
    6

    Default

    Hi srinath and KevinH

    If I have a working servlet on my local machine (for starters just outputting static html code), and copy the war file to the zimbra server, I can't locate it with a browser.

    In the WAR file is the class file WEB-INF/classes/echotest/echo.class, and it's placed in /opt/zimbra/jetty/webapps/service/echotest.war on the server

    The servlet cannot be found through a browser (tried [hostname]/service/echotest/echo and a whole bunch of other combinations), and yes, it does have a doGet() method.

    Same goes for copying the .class file directly to /opt/zimbra/jetty/webapps/service/WEB-INF/classes

    Kevin's suggestion about putting stuff in the zimlet zip works perfectly for jsp files, but a servlet .war file in the zimlet zip is still not deployed or reachable, though it seems to be the most logical way to set things up.

Similar Threads

  1. Replies: 21
    Last Post: 02-04-2010, 10:06 AM
  2. Replies: 5
    Last Post: 01-11-2008, 05:34 AM
  3. Domain Admin Error: Permission Denied
    By shanson in forum Administrators
    Replies: 3
    Last Post: 05-29-2007, 06:48 AM
  4. Post instsallation problems
    By Assaf in forum Installation
    Replies: 14
    Last Post: 01-29-2007, 11:38 AM
  5. Zimbra on Debian?
    By omry_y in forum Installation
    Replies: 25
    Last Post: 11-04-2005, 11:36 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •