Problem using ant and weblogic web services (jwsc)

I have made a small HelloWorld implementation as given in http://download.oracle.com/docs/cd/E12840_01/wls/docs103/webserv/use_cases.html#wp228687. but when I run ant I get this error
Buildfile: build.xml
build-service:
[jwsc] JWS: processing module /examples/webservices/hello_world/HelloWorldImpl
[jwsc] Parsing source files
[jwsc] Parsing source files
[AntUtil.deleteDir] Deleting directory /tmp/_gwf3vm
BUILD FAILED
/home/testprojects/src/build.xml:10: java.lang.RuntimeException: Unknown javadoc problem: result=1, root=null:
JAM: error - Cannot find doclet class com.bea.util.jam.internal.javadoc.JavadocRunner_150
1 error
Any help?

I also faced the same problem what I did is
moved all the files from weblogic ant directory into another folder
and ant*.* from c:\bea\weblogic81\server\bin to a temp location
copied all the jar files from apache-ant-1.6.3\lib to beahome\lib\ant folder
copied all the ant*.* files from apache-ant-1.6.3\bin to c:\bea\weblogic81\server\bin directory
now I ran the ant -version I am getting the latest version
try this

Similar Messages

  • Using InfoPath and the Web service GetUserProfileByName-An error occurred accessing a data source

    Hi, Everyone,
    I want to realize the function that when user fills out the infopath form the form can automatically get current users' name and I've searched that I can use the Web service GetUserProfileByName method. When I preview the form it is all right, however, when
    I fill the form online, it occurs this error as folllowing. Anyone knows why and how to solve this problem?
    Thanks forward!
    Warning
    An error occurred querying a data source.
    Click OK to resume filling out the form. You may want to check your form data for errors.
    Hide error details
    An error occurred while trying to connect to a Web service.
    An entry has been added to the Windows event log of the server.
    Log ID:5566
    Correlation ID:9c23d39c-18fa-1025-c7ec-600a1582a54a

    Hi,
    According to your post, my understanding is that you get error when using the Web service GetUserProfileByName in InfoPath.
    Have the InfoPath form template call web service in code? If yes, please see following KB and check if it is the cause.
    http://support.microsoft.com/kb/981684
    You can also
    follow the steps in the article to resolve this error in InfoPath. Please refer to:
    Auto Populate User Information in InfoPath with Claims Based Authentication in SharePoint – Part 2 of 3
    In addition, you need to disable the Loopback check.
    Here is a similar thread for your reference:
    https://social.technet.microsoft.com/Forums/en-US/d6d20308-a5d0-45fa-881d-0626c68c4e73/infopath-an-entry-has-been-added-to-the-windows-event-log-of-the-server-logid-5566?forum=sharepointcustomizationprevious
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

  • Problem with java and flex web service

    Hi,
    I have a basic web service written in java using jax ws 2.1
    ri. I need to call it from Flex using the WebService class
    Annotations for the java web method :
    @WebMethod
    public void Login(
    @WebParam(name="server") String serverURL,
    @WebParam(name=AUTHENTICATE_HEADER,header=true,mode=WebParam.Mode.INOUTHolder<Authenticate Header>
    authHeader)
    When I try and call the service from Flex , it can't find the
    login method and attempts to call it fail. If I set the web service
    to RPC based using @SOAPBinding , the method is found but then
    there are issues with the authentication header.
    What do I need to do to get flex web services communicating
    succesfully with java ?
    Are there are any known compatibility issues ? Or guidelines
    for going about this ?
    Any help would be appreciated

    well Shay,
    i've used JDev's tools to developer and to deploy the web service: the war and ear files are automatically generates you to the end of the process.
    I have included all the files java and the compiled classes, but I do not have files jar.
    But don't works: if i create only one java class with all code inside then it works fine!!
    Daniele

  • Querying Exchange 2013 Mail server for email items using c# and Exchange Web Services

    I am trying to upgrade an existing application that reads Exchange 2003 using WebDAV. The mail server is to be upgraded to Exchange 2013, so I am checking how I can use EWS.
    I have a problem in that although I know the inbox has unread items with attachments, the query I am running against the
    FindItems object is returning empty (results.totalCount=0)
    Here is my code snippet:
    private static void GetAttachments(ExchangeService service)
    // Return a single item.
    ItemView view = new ItemView(100);
    ServicePointManager.ServerCertificateValidationCallback = CertificateValidationCallBack;
    ExchangeService service = new ExchangeService(ExchangeVersion.Exchange2010_SP2);// .Exchange2007_SP1);
    service.UseDefaultCredentials = true;
    service.AutodiscoverUrl("[email protected]", RedirectionUrlValidationCallback);
    ItemView view = new ItemView(1);
    string querystring = "HasAttachments:true Subject:'ATTACHMENT TEST' Kind:email";
    // Find the first email message in the Inbox that has attachments.
    // This results in a FindItem operation call to EWS.
    FindItemsResults<Item> results = service.FindItems(WellKnownFolderName.Inbox, querystring, view);
    //FindItemsResults<Item> results = service.FindItems(WellKnownFolderName.Inbox, new ItemView(50));
    if (results.TotalCount > 0)
    // looping through all the emails
    for (Int16 iDx = 0; iDx < results.TotalCount-1; iDx++)
    EmailMessage email = results.Items[iDx] as EmailMessage;
    if (email.IsRead == false) {
    // Request all the attachments on the email message. This results in a GetItem operation call to EWS.
    email.Load(new PropertySet(EmailMessageSchema.Attachments));
    foreach (Attachment attachment in email.Attachments)
    if (attachment is FileAttachment)
    FileAttachment fileAttachment = attachment as FileAttachment;
    What I am supposed to be doing is reading all the unread emails in the target inbox (only one Exchange server) and taking the attachments on disk so I can then add them as attachments as new cases on SalesForce.
    Where am I going wrong?
    Also, this line:
    ItemView view = new ItemView(100);
    was:
    ItemView view = new ItemView(1);
    Surely that will only look for one email item, right?

    thanks, do you know why I would be getting an error message like 'The specified object was not found in the store'
    here is my code:
    ServicePointManager.ServerCertificateValidationCallback = CertificateValidationCallBack;
    ExchangeService service = new ExchangeService(ExchangeVersion.Exchange2010_SP2);// .Exchange2007_SP1);
    service.Url = new Uri("https://sgexc.bocuk.local/EWS/Exchange.asmx");
    //creates an object that will represent the desired mailbox
    Mailbox mb = new Mailbox(@"[email protected]");
    //creates a folder object that will point to inbox folder
    FolderId fid = new FolderId(WellKnownFolderName.Inbox, mb);
    //this will bind the mailbox you're looking for using your service instance
    Folder inbox = Folder.Bind(service, fid);
    FindItemsResults<Item> findResults = service.FindItems(new FolderId(WellKnownFolderName.Inbox, new Mailbox("[email protected]")),new ItemView(10));
    it's happening on this line:
    Folder inbox = Folder.Bind(service, fid);
    and if I try to use AutoDiscoverURL then I just see my own inbox.

  • Unable to pass xmlbeans object in weblogic web services using OEPE

    Migrating Weblogic web services from Weblogic Workshop 10.3 to Oracle Enterprise for Eclipse...Passing xmlbean generated types in arguments of webservice call
    How to work around the following errors? I do not have this error when in workshop 10.3 only in OEPE eclipse
    "oracle.eclipse.tools.webservices.compiler.CompilationException: Errors: JAX-WS web services must not have xmlBean parameter or return type"
    PLease note that I want DocType to be xmlbeans generated or inherited from org.apache.xmlbeans.XmlObject....
    @WebMethod
         public void upload(String filename, DocType doc) {
    Hi, I have legacy codes from Weblogic workshop 10.1 and 10.3.....
    I am able to compile and run in Weblogic workshop 10.3 by passing the xmlbean generated DocType as arguments in the web services call.... but why am I not able to do this in Oracle Enterprise for Eclipse OEPE......
    If I were to generate the web service from teh wsdl...it will generate it's own DocType.class in the jar files and not use the xmlbean generated class one....
    How to get iOEPE to generate the classes in build\jws\ for
    testWSService-annotation.xml
    weblogic-webservices.xml etc like in workshop
    How can I resolve this??? Am I stuck with Workshop on this?? How to work around??
    Any help or clarifications would be much appreciated.
    Inside testWS.java,
    package ws;
    import java.io.File;
    import javax.jws.*;
    import org.example.doc.DocType;
    @WebService
    public class testWS {
         @WebMethod
         public void upload(String filename, DocType doc) {
              try {
                   doc.save(new File(filename));
              catch(Exception e) {
                   System.out.println(e);
    Inside xmlbeans generated DocType.java.....and DocTypeDocuments.java
    * XML Type: DocType
    * Namespace: http://www.example.org/doc
    * Java type: org.example.doc.DocType
    * Automatically generated - do not modify.
    package org.example.doc;
    * An XML DocType(@http://www.example.org/doc).
    * This is a complex type.
    public interface DocType extends org.apache.xmlbeans.XmlObject
    public static final org.apache.xmlbeans.SchemaType type = (org.apache.xmlbeans.SchemaType)
    org.apache.xmlbeans.XmlBeans.typeSystemForClassLoader(DocType.class.getClassLoader(), "schemaorg_apache_xmlbeans.system.testWSTypeSystem").resolveHandle("doctypec217type");
    * Gets the "element1" element
    java.lang.String getElement1();
    * Gets (as xml) the "element1" element
    org.apache.xmlbeans.XmlString xgetElement1();
    * Sets the "element1" element
    void setElement1(java.lang.String element1);
    * Sets (as xml) the "element1" element
    void xsetElement1(org.apache.xmlbeans.XmlString element1);
    * Gets the "element2" element
    java.lang.String getElement2();
    * Gets (as xml) the "element2" element
    org.apache.xmlbeans.XmlString xgetElement2();
    * Sets the "element2" element
    void setElement2(java.lang.String element2);
    * Sets (as xml) the "element2" element
    void xsetElement2(org.apache.xmlbeans.XmlString element2);
    * A factory class with static methods for creating instances
    * of this type.
    public static final class Factory
    public static org.example.doc.DocType newInstance() {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newInstance( type, null ); }
    public static org.example.doc.DocType newInstance(org.apache.xmlbeans.XmlOptions options) {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newInstance( type, options ); }
    /** @param xmlAsString the string value to parse */
    public static org.example.doc.DocType parse(java.lang.String xmlAsString) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xmlAsString, type, null ); }
    public static org.example.doc.DocType parse(java.lang.String xmlAsString, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xmlAsString, type, options ); }
    /** @param file the file from which to load an xml document */
    public static org.example.doc.DocType parse(java.io.File file) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( file, type, null ); }
    public static org.example.doc.DocType parse(java.io.File file, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( file, type, options ); }
    public static org.example.doc.DocType parse(java.net.URL u) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( u, type, null ); }
    public static org.example.doc.DocType parse(java.net.URL u, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( u, type, options ); }
    public static org.example.doc.DocType parse(java.io.InputStream is) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( is, type, null ); }
    public static org.example.doc.DocType parse(java.io.InputStream is, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( is, type, options ); }
    public static org.example.doc.DocType parse(java.io.Reader r) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( r, type, null ); }
    public static org.example.doc.DocType parse(java.io.Reader r, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( r, type, options ); }
    public static org.example.doc.DocType parse(javax.xml.stream.XMLStreamReader sr) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( sr, type, null ); }
    public static org.example.doc.DocType parse(javax.xml.stream.XMLStreamReader sr, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( sr, type, options ); }
    public static org.example.doc.DocType parse(org.w3c.dom.Node node) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( node, type, null ); }
    public static org.example.doc.DocType parse(org.w3c.dom.Node node, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( node, type, options ); }
    /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */
    public static org.example.doc.DocType parse(org.apache.xmlbeans.xml.stream.XMLInputStream xis) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xis, type, null ); }
    /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */
    public static org.example.doc.DocType parse(org.apache.xmlbeans.xml.stream.XMLInputStream xis, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xis, type, options ); }
    /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */
    public static org.apache.xmlbeans.xml.stream.XMLInputStream newValidatingXMLInputStream(org.apache.xmlbeans.xml.stream.XMLInputStream xis) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException {
    return org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newValidatingXMLInputStream( xis, type, null ); }
    /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */
    public static org.apache.xmlbeans.xml.stream.XMLInputStream newValidatingXMLInputStream(org.apache.xmlbeans.xml.stream.XMLInputStream xis, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException {
    return org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newValidatingXMLInputStream( xis, type, options ); }
    private Factory() { } // No instance of this class allowed
    Edited by: user11079482 on Jan 1, 2010 2:09 AM

    Ok just as I expected. So I guess I am left with the following two options
    1) either I switched to using JAXB in my apps instaed of xmlbeans....
    2) or if I still wanna use the old JAX-RPC web services to deploy on the Weblogic 10gR3 server i will have to create my own ant task jwsc directly......as shown below in your docs
    Programming Web Services for WebLogic Server (ant tasks)
    http://download.oracle.com/docs/cd/E13222_01/wls/docs92/webserv/anttasks.html
    Getting Started With WebLogic Web Services Using JAX-RPC
    http://download.oracle.com/docs/cd/E12840_01/wls/docs103/webserv_rpc/index.html
    Will OEPE be supporting the old JAX-RPC anytime in the near future release? or have to create own build ant task to call jwsc ant task directly to compile JAX-RPC web services??

  • Stateful WebLogic Web Services using cookie

    Hi all,
    How do I configure WebLogic Web Services to return cookie in the HTTP header?
    In my weblogic.xml I included the following attributes but no cookie is returned in the HTTP header.
    <session-descriptor>
    <cookie-http-only>false</cookie-http-only>
         <tracking-enabled>true</tracking-enabled>
         <cookies-enabled>true</cookies-enabled>
         <cookie-name>JSESSION_ID</cookie-name >
    </session-descriptor>
    Thanks
    SMT

    Ok just as I expected. So I guess I am left with the following two options
    1) either I switched to using JAXB in my apps instaed of xmlbeans....
    2) or if I still wanna use the old JAX-RPC web services to deploy on the Weblogic 10gR3 server i will have to create my own ant task jwsc directly......as shown below in your docs
    Programming Web Services for WebLogic Server (ant tasks)
    http://download.oracle.com/docs/cd/E13222_01/wls/docs92/webserv/anttasks.html
    Getting Started With WebLogic Web Services Using JAX-RPC
    http://download.oracle.com/docs/cd/E12840_01/wls/docs103/webserv_rpc/index.html
    Will OEPE be supporting the old JAX-RPC anytime in the near future release? or have to create own build ant task to call jwsc ant task directly to compile JAX-RPC web services??

  • Migrating a Eclipse Project to JDeveloper and use it as a web service

    Hi Guys,
    I have a problem with migrating a Eclipse Project (EP) to JDeveloper. I know there are several threads about the problem out there but none of these fit my needs.
    So, here is the problem:
    I didn't had any problems migrating EPs to JDev in the past but this project is neither a .jar/.lib nor could I change it to one of those types. The project hase some additional filesto work. These files areare libs and owl-mappings for Jena/Pellet ( [http://jena.sourceforge.net/|http://jena.sourceforge.net/] ).
    My porblem is that I don't know who to migrate the project to JDev and then use it as a web service, while the file structure stays the same plus everything is uploaded to Oracle as a web service. Meaning everything has to be included in one java package. Or am i wrong?
    The file structure looks like this (from the EP):
    src\*.java
    owl\*.owl
    lib\*.lib
    location-mapping.n3
    expdt.props
    The Libraries aren't a problem. They are all .jar-files but could be easily included in the project (JDev) but I don't know how to handle the other files. Especially the much needed owl files :(
    Maybe I'm doing it all wrong. My Goal is to use the EP as a web servies for a business process to enforce rulings and obligations. I'm kinda stumped...
    Greetings,
    Sebastian

    Thank you very much, Shay. It helped regaining overview of the project files. Before all additional files were in the AppFolder.
    I got to a point where I (hopefully) only got a problem with the directory matching (which is needed by jena).
    Tanks again.
    Sebastian

  • Authenticating to weblogic web service using a client cert with webserver

    I am trying to think of how to authenticate a client to a weblogic web service
    using a client certificate. The wrinkle is that a Web Server (iis or whatever)
    will be handling the ssl part and forwarding non-secure to weblogic. The cert
    will still be accessable in the request using: HttpServletRequest req.getAttribute("javax.net.ssl.peer_certificates).
    At this point it is not clear to me what I can do. When does CertAuthenticator
    get called? Can I even use it? Will I have to write my own version of the weblogic.soap.server.servlet.StatelessBeanAdapter
    class?
    Any help will be appreciated, even explaining why it can't be done.
    Thanks,
    Scott

    I am trying to think of how to authenticate a client to a weblogic web service
    using a client certificate. The wrinkle is that a Web Server (iis or whatever)
    will be handling the ssl part and forwarding non-secure to weblogic. The cert
    will still be accessable in the request using: HttpServletRequest req.getAttribute("javax.net.ssl.peer_certificates).
    At this point it is not clear to me what I can do. When does CertAuthenticator
    get called? Can I even use it? Will I have to write my own version of the weblogic.soap.server.servlet.StatelessBeanAdapter
    class?
    Any help will be appreciated, even explaining why it can't be done.
    Thanks,
    Scott

  • WebLogic Web Services Home Page and authentication

    I've generated a set of web services using a session bean and have secured
    my EJB methods. I'd like to enable testing of these methods via the WebLogic
    Web Services Home Page service, but I can't figure out how to pass along the
    authentication parameters. I've tried appending
    '&username=myUser&password=myPassword' to the URL and this doesn't appear to
    work (yeah, I know, but you can't blame me for trying).
    Any ideas on how I might do this?
    Thanks,
    Rob

    Looks like a bug. filed CR086448.
    Contact support for patch.
    regards,
    -manoj
    "Rob Moore" <[email protected]> wrote in message
    news:[email protected]..
    Hi, Manoj,
    We're using WLS 7.0.0.1.
    Thanks,
    Rob
    "manoj cheenath" <[email protected]> wrote in message
    news:[email protected]..
    The browser should pop up the user name/passwd dialog,
    if the WS is secured. Which version of WLS are you using?
    This could be a bug.
    regards,
    -manoj
    "Rob Moore" <[email protected]> wrote in message
    news:[email protected]..
    I've generated a set of web services using a session bean and have
    secured
    my EJB methods. I'd like to enable testing of these methods via theWebLogic
    Web Services Home Page service, but I can't figure out how to pass
    along
    the
    authentication parameters. I've tried appending
    '&username=myUser&password=myPassword' to the URL and this doesn't
    appear
    to
    work (yeah, I know, but you can't blame me for trying).
    Any ideas on how I might do this?
    Thanks,
    Rob

  • How to Create and Deploy Web Services Using Oracle 9i JDeveloper

    Hi,
    My Question is how to create and deploy Web Services using Oracle 9i JDeveloper.Anybody please give me a detailed Reply.Please Reply to [email protected]
    Hopr to Hear From you,
    Regards,
    G Sreekumar

    You could use datasources. You should do this in your BC4J Configuration. Then when deploying your applicaiton use the command -installDataSource (from admin.jar) to create the right datasource.
    You could probably use the name of your connection + "DS" so you can also use it locally in JDeveloper as JDev seesm to create this automaticly for your Connections.

  • Issue using Flash IDE with Mac OS and Windows Web Service using NTLM authentication?

    I have an existing application that I developed on a Windows machine using CS5.  It uses a local intranet web service written in .NET using NTLM authentication.  The web service does multiple things such as read data from an SQL database, provide the user's username, and test for write/read access to a local company fileshare.  When my company upgraded, I went to a Mac with Flash CC which is great.  However, Mac's don't handle HTTP Authorization Challenge Blocks like Windows machines.  In Safari, Chrome, etc. it will pop up a little username and password box and proceed on without issue.  The issue is in Flash development.  When running the exact same application in Flash testing all script access fails with HTTP Status 401 errors.  I have searched the AS3 documentation, but the only thing built in to handle http challenge requests is in AIR not Flash.  The server admin's and I have tried all method's of cross domain policy files and access changes with no luck at all.  Does anyone have a solution to this issue?

    Did you check Apple Support Boot Camp article?
    iMac displays a black screen during installation of Windows 7
    http://www.apple.com/support/bootcamp/
    Installation Guide
    Instructions for all features and settings.
    Boot Camp FAQGet answers to commonly asked Boot Camp questions.
    Windows 7 FAQAnswers to commonly asked Windows 7 questions.

  • How to prevent downloading wsdl in weblogic web service client

    Hi,
    I get a problem regarding weblogic web service client. My working environment:
    weblogic server 8.1
    Windows XP SP2
    JDK 1.4
    I use the weblogic tool to generate the client jar file from the wsdl file.
         <target name="generate-client">
              <clientgen wsdl="ACCESS.wsdl"
                   packageName="xxxxxx.client"
                   clientJar="${client}/${AccessClient_jar_file}"
                   keepGenerated="true"
                   saveWSDL="true"
              />
              <javac srcdir="${source}"
              destdir="${client}"
              includes="**/AccessClient.java">
              <classpath>
              <pathelement path="${client}/${AccessClient_jar_file}"/>
              </classpath>
              </javac>
         </target>
    After that, I create a client java file to invoke the service deploy in the server.
    public static void main(String[] argv)
    throws Exception
         int transactionId = 100;
         int id = 1000;
    // Setup the global JAXM message factory
    System.setProperty("javax.xml.soap.MessageFactory", "weblogic.webservice.core.soap.MessageFactoryImpl");
    // Setup the global JAX-RPC service factory
    System.setProperty( "javax.xml.rpc.ServiceFactory", "weblogic.webservice.core.rpc.ServiceFactoryImpl");
    AccessServicePorts ws = new AccessServicePorts_Impl(argv[0]);
    AccessService port = ws.getAccessService();
    // Resource - create
    Resource resource = new Resource();
    resource.setRES_CD("Create ResCo");
    resource.setCODE_CODE("code_cod");
    resource.setRES_TYPE("Resource typ");
    resource.setCOMMON_FIELD(common);
    AccessDefaultResult resultItems = port.createResource(resource);
    System.out.println("createResource : " + resultItems);
    I find that this web service client always issue 2 http requests to invoke an web service method deployed in server.
    1st http reqeust:
    GET /AccessEpol/EpolServiceSoap?WSDL HTTP/1.1
    User-Agent: Java/1.4.2_08
    Host: 127.0.0.1:8001
    Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2
    Connection: keep-alive
    the return result is the wsdl downloaded from the server.
    2nd http request is the real web service request.
    The question is how could I eliminate the 1st http request because it's really unnecessary. I use other web service client like Axis 1.x, Axis client never has the http request to download the wsdl from the server.
    I read through weblogic web service document. It do mentions that put saveWSDL="true" in the clientgen ant task. the default value for saveWSDL is true already. I did try saveWSDL="false" also. None of them can eliminate the 1st http request.
    appreciate for any answer my question?

    Hi David,
    thanks for the reply.
    More or less I agree some points you mentioned above.
    I did use Axis 1.x to test the inter-operability. The web service was developed in Weblogic 8.1 and is a part of an existing web application. It will be merged to existing application deployed in weblogic 8.1.
    I also program the web service client to test the web service.
    The implementation of the server and client will be handed over the project team and training for supporting or continuous development have to be conducted by me. So I don't like to use two types of technologies which will make thing complex.
    I found this issue when I tried to protected the web service endpoint, eg http://localhost:7001/epol/service, using the web application Basic mechanism. The wsdl URL http://localhost:7001/epol/service?WSDL is also protected in this case. Unfortunately the username/password pair is not sent to the server when the weblogic client download the WSDL from the server. In this case, the client failed and throw exception.

  • Accessing config information in XML file in a Weblogic web service (JWS)

    Problem:
    I have implemented a web service for sending emails and pages via Java Mail and SNPP respectively using WebLogic Workshop on the BEA WebLogic 8.1 platform. In the service, I use certain pieces of information that are currently stored in an XML file on disk. Also, in its current state, the web service is implemented with public methods directly in the .jws Java file and not as a session bean. The file read from disk is performed every time the web service operation to send a message is invoked. As we all know, the I/O files access is very expensive and a performance bottleneck, especially when it is incurred on every invocation of the web service ‘sendMessage’ [operation.
    Without radically re-writing the application, I am looking for a way to improve the performance of the web service and can only come up with the following 2 ways:
    1) Move the code out of the sendMessage operation: Here, the main question I have is 'to where should I move it to'? I have seen in the WebLogic Workshop documentation that WebLogic Server maintains only a single instance of a Java class that implements a Web Service operation, and each invoke of the Web Service uses this same instance. In that case, I should be able to put the code in the constructor so that the files is read only at the time the class is instantiated, but a constructor in the .jws file that contains the web service operations itself does not seem to be invoked by the container (I tried to put a breakpoint in the constructor, but it seems that the constructor code never gets called)
    2) Move the configuration variables into some type of standard configuration file of WebLogic, something like web.xml or wlw-config.xml or jws-config.properties files. But I found that these XML files have an associated schema to conform to and do not provide any custom elements or attributes that I could add for my application(is that true?). Also, if I can somehow put the configuration information into any of these standard files, how do I access it from within the application 'without' doing a file read from disk? Are these configuration file items available in memory for access and use by the web service and if they are, what API can I use to access and use them?
    Any and all ideas are welcome!
    Thanks!                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    I have been looking into a similar problem. Since web services are by design stateless, they aren't good for 'remembering' information between calls. Aside from a file read, the only other solution I have found is to use a database. You can make use of an entity bean or simply make some kind of JDBC call. I don't know if you need to stick with the config file, but if so maybe you could read the config data into a database once and then you might have faster access than reading from a file. I'm not sure about which would have better performace, but its all I have come up with so far. What parser are you using to read your XML file? Have you tried others to see if they have better performance?

  • Simple question re invoking non-WebLogic web services

    I have a very simple question that I haven't been able to resolve elsewhere.
    I need to invoke 3rd-party SOAP interfaces from my WebLogic 6.1 client EJB. All
    the Bea documentation I've found refers to invoking "WebLogic Web Services" and
    speaks of downloading the client.jar -- however, in my case it's not a "WebLogic
    Web Service" I'm invoking, it's a non-WebLogic web service.
    Does WebLogic 6.1's WebServiceProxy (or other tool) allow this? Or must I use
    some other SOAP tool such as Apache Axis in this case?
    Thanks.
    Cheers,
    allan

    Could this interopability problem have something to do with a problem
    I'm experiencing on 61.sp3?
    I have an EJB that accesses SOAP services on a Tomcat server. The SOAP
    service sends back a SOAP exception which is correct in what I am asking
    in to do. However, the weblogic app server is returning a SOAP
    exception to my EJB rather than passing the SOAP exception to the API
    that I am using to make my SOAP calls.
    Has anyone seen something like this?
    Sandy Mustard
    john wrote:
    >
    The 'samples/examples/webservices/rpc/javaClient/XMethodClient'
    is an example of how to invoke a non-WL webservice. You can
    use that code within your EJB.
    The javadocs for the WebServiceProxy class (from BEA's site)
    will give you more methods that may be useful to you.
    Note that your best bet, if possible, is to use the JAX-RPC
    APIs within WebLogic 7. The SOAP support in WL6.1 has
    interoperability issues.
    -john
    "Allan Halme" <[email protected]> wrote:
    I have a very simple question that I haven't been able to resolve elsewhere.
    I need to invoke 3rd-party SOAP interfaces from my WebLogic 6.1 client
    EJB. All
    the Bea documentation I've found refers to invoking "WebLogic Web Services"
    and
    speaks of downloading the client.jar -- however, in my case it's not
    a "WebLogic
    Web Service" I'm invoking, it's a non-WebLogic web service.
    Does WebLogic 6.1's WebServiceProxy (or other tool) allow this? Or must
    I use
    some other SOAP tool such as Apache Axis in this case?
    Thanks.
    Cheers,
    allan

  • Sending WSSE security headers to non-weblogic web service

    I have been trying to send wsse headers to a non-weblogic web service. I am looking for a way to do this using the control file I generated from the wsdl or the page flow where I implement the control, or the message handler file. I have username and password parameters but I cannot get this to function.
    Here is the signature I need:
    <?xml version="1.0" encoding="UTF-8" ?>
    - <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    - <env:Header>
    - <wsse:Security env:mustUnderstand="1" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">
    - <wsse:UsernameToken wsu:Id="Id-dFQDZm_34ewPYtaARIJ_4BfI" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">
    <wsse:Username>weblogic</wsse:Username>
    <wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">weblogic</wsse:Password>
    </wsse:UsernameToken>
    </wsse:Security>
    </env:Header>
    - <env:Body>
    <n1:hello xmlns:n1="http://workshop.bea.com/WebServiceB" />
    </env:Body>
    </env:Envelope>
    Of course the Body is different, but this is the security signature that I need to get into the header. After looking at all the examples, I only see the option of using a java proxy class to call the web service, which would be a little difficult to use as my whole page flow application so far is calling the web service from a generated control. There are also lots of coplex datatypes that are being sent to the web service so a jave proxy would be a little difficult. I have tried to take the code from the java proxy class example and put it in my handler class, but the handler seems to only use MessageContext, not WebServiceContext and will not let me add the username password tokens. When I have tried to case a WebServiceContext out of a MessageContext, it gives me a runtime error "Class Cast Exception" even though workshop lets me do it.
    This is extremely urgent. Please help me! I am using the sample handler class called MessageHandler.java and the sample WSSE java proxy class called WebServiceBClient.java that generated the above signature.

    More information:
    Here is the first part of my Java Control where I am calling the web service and the message handler:
    package controls;
    * @jc:location http-url="http://localhost:7001/Checking.jws"
    * @jc:wsdl file="#CheckingWsdl"
    * @jc:handler callback="MessageHandler" operation="MessageHandler"
    public interface CheckingService extends com.bea.control.ControlExtension, com.bea.control.ServiceControl
    public static class CustomerInfo
    implements java.io.Serializable
    public java.lang.String FirstName;
    public java.lang.String LastName;
    public java.lang.String MiddleName;
    public int SSN;
    public int CustomerNumber;
    public java.util.Calendar CreationDate;
    public java.util.Calendar LastModifiedDate;
    public static class FundingInfo
    implements java.io.Serializable
    public float Amount;
    public java.util.Calendar CurrentDate;
    public int AccountNumber;
    public static class anyType
    implements java.io.Serializable
    public com.bea.xml.XmlObject[] t;
    public static class AccountInfo
    implements java.io.Serializable
    public int AccountNumber;
    public float Balance;
    public int CustomerNumber;
    public java.util.Calendar LastModifiedDate;
    * @jc:protocol form-post="false" form-get="false"
    public AccountInfo CreateAccountChecking (CustomerInfo CustomerInfo, FundingInfo FundingInfo, anyType CommonHeader);
    static final long serialVersionUID = 1L;
    Here is the section of the MessageHandler class where I am attempting to add security token to the header:
    protected void addSecurityHeader (MessageContext mc)
    * Registers a handler for the SOAP message traffic.
    HandlerRegistry registry = mc.getHandlerRegistry();
    List list = new ArrayList();
    list.add(new HandlerInfo(WSSEClientHandler.class, null, null));
    registry.setHandlerChain(new QName("hello"), list);
    try
    WebServiceContext context = (WebServiceContext)WebServiceContext.currentContext().getLastMessageContext();
    //(WebServiceContext)mc;
    WebServiceSession session = context.getSession();
    * Set the username and password token for SOAP message sent from the client, through
    * the proxy, to the web service.
    UserInfo ui = new UserInfo("weblogic", "weblogic");
    session.setAttribute(WSSEClientHandler.REQUEST_USERINFO, ui);
    //mc.setProperty(WSSEClientHandler.REQUEST_USERINFO, ui);
    * Adds the username / password token to the SOAP header.
    SecurityElementFactory factory = SecurityElementFactory.getDefaultFactory();
    Security security = factory.createSecurity(null);
    security.addToken(ui);
    session.setAttribute(WSSEClientHandler.REQUEST_SECURITY, security);
    //mc.setProperty(WSSEClientHandler.REQUEST_SECURITY, security);
    } catch (Exception ex) {System.out.println("EXCEPTION CAUGHT DOING SECURITY STUFF " + ex.getMessage());}
    I tried to use the MessageContext to do this but it came out null. I tried to cast the MessageContext to WebServiceContext and it gave me a Class Cast Exception. I tried to add the HandlerRegistry section to this but of course the assignment mc.getHandlerRegistry is improper and is not compiling so don't let that confuse you.

Maybe you are looking for

  • Help needed in text entry box...

    hi, I have created one assessment simulation, which has a few text entry boxes. This I have included it in another flash file. Output of that flash file is .exe and not .swf.  But when I play that exe; this simulation doent allow to enter the text, w

  • Non -OCI compatible XML to OCI compatible XML : External Punchout

    Hi All, We are doing external punchout to around 60 different sites. No our problem is that more than half of them will not be able to send the data back in OCI compatible format. But they will sending us the data in the same format i.e. same for for

  • J2ee Stack not comming up after configuring RAC

    Hello We have installed High availability system in HP Unix box IA64 with Oracle 10g database with virtual host name and ip for usage type PI7.0 ABAP+JAVA dual stack. System was up and running successfully after the installation. We  configure RAC Re

  • How do I close Foxfire in order to download Foxfire 4.0

    As I start the steps in the download I am informed that I need to close Foxfire in order for the download to continue

  • CF-Flex wizard application problem

    I have built several simple CF-Flex wixard apps in which everything seems to look fine--buttons for add, edit, delete are displayed--but when I add a record and then Save it, the record does not appear in the master list. I also looked in the raw dat