Web service operation could not be found.

Would CF give this error if there was simply an error in the
cffunction code? The service is there and it looks fine. In fact,
most of the code comes from another cffunction in the same file,
but with more arguments and some additional code. I have cleared
the server cache several times.
It's driving me nuts. The error codes sometimes just don't
make any sense or are misleading. I hope future versions of CF deal
with this better.
Web service operation "RegisterFiles" with parameters
{groupID={185},folder={/},filename={MOV04684.MPG},userName={xxxx},userPassword={xxxx},fil eType={video}}
could not be found.

NealCrankshaw, in your case you definitaly need to use java
in order to create and use complex data types arguments with your
web service. Here are the steps to follow in nutshell
1. Use wsdl2java tool (CF_HOME/runtime/bin) tsupplying URL to
webservice WSDL to create java code.
2. Create java classes by compiling java code created in step
1
3. Create jar file(s) from classes in step 2
4. Put jar file in CF classpath or just copy it to
CF_HOME/lib directory
5. Using <cfscript> create required objects, arrays and
other arguments and supply them to web service method call.

Similar Messages

  • Com.crystaldecisions.sdk.exception.SDKException$ServiceNotFound: The service WebiReportEngine could not be found(Help needed )

    com.crystaldecisions.sdk.exception.SDKException$ServiceNotFound: The service WebiReportEngine could not be found
    Here is the code I have used to obtain a report engine object
    oEnterpriseSession = CrystalEnterprise.getSessionMgr().logon(username, password, cms, authType);
    reportEngine = (ReportEngine) oEnterpriseSession.getService("","WebiReportEngine");
    Exception lies in the above line .. I am not able to debug

    To get the ReportEngine object use the following code:
    // Retrieve the Report Engines
    ReportEngines boReportEngines = (ReportEngines) boEnterpriseSession.getService("ReportEngines");
    // Retrieve the Report Engine for Web Intelligence documents
    ReportEngine boReportEngine = boReportEngines.getService(ReportEngines.ReportEngineType.WI_REPORT_ENGINE);
    You may also want to look at our samples using the Report Engine SDK available here:
    http://diamond.businessobjects.com/samples/86/1199/

  • Com.crystaldecisions.sdk.exception.SDKException$ServiceNotFound: The service ReportEngine could not be found

    I am attempting to automate the "Save As" or export funtion of a webi doc but the documentation that states:
    ReportEngine repEngine = (ReportEngine)EnterpriseSession.getService("ReportEngine");
    Fails with:
    com.crystaldecisions.sdk.exception.SDKException$ServiceNotFound: The service ReportEngine could not be found
    When I run:
    enterpriseSession.getServiceNames("CMSName", 0);
    There is now "ReportEngine" listed.
    Can anyone help????? This is not JSP but a command line app that simple need to open a doc, then to getView() to get the binary version of the Webi doc in PDF and simply save to disk via some java method.
    I can get the doc, query reports, schedule reports, etc.. Just not export the report to disk.
    Can anyone help???

    These are the only things that show up when I call:
    EnterpriseSession().getServiceNames("sales-demo", 0);
    Batch
    Diagnostics
    InfoStore
    Logon
    NameService
    OCAAdministrator
    Pinger
    PluginDistribution
    Session
    APSAdmin
    AuditAdmin
    ISGeneralAdmin
    SSOAdmin
    This is the whole error:
    Exception in thread "main" java.lang.NoClassDefFoundError: com/businessobjects/wp/dbg/DBGTraceable
         at java.lang.ClassLoader.defineClass1(Native Method)
         at java.lang.ClassLoader.defineClass(Unknown Source)
         at java.security.SecureClassLoader.defineClass(Unknown Source)
         at java.net.URLClassLoader.defineClass(Unknown Source)
         at java.net.URLClassLoader.access$100(Unknown Source)
         at java.net.URLClassLoader$1.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at java.lang.ClassLoader.loadClassInternal(Unknown Source)
         at com.businessobjects.rebean.wi.occa.WebiReportEngine.<init>(WebiReportEngine.java:66)
         at com.businessobjects.rebean.wi.occa.WebiReportEngineFactory.makeOCCA(WebiReportEngineFactory.java:64)
         at com.crystaldecisions.sdk.framework.internal.a.getService(Unknown Source)
         at com.crystaldecisions.sdk.framework.internal.a.getService(Unknown Source)
         at com.tidalsoft.adaptors.buisnessobjects.EnterpriseSession.getReportEngine(EnterpriseSession.java:72)
         at com.tidalsoft.adaptors.buisnessobjects.BO.main(BO.java:28)

  • TF255186: The following SQL Server Reporting Services Instance could not be found

    Hi,
    I'm trying to install TFS 2013 on a remote SQL RS instance. 
    Using the TFS 2103 U4 installation
    SQL 2012 RS, name instance, Server: SQLProdA, Instance Name COMRS
    When I enabled tracing using debugView I see the following output:
    [4160] [Error  @11:07:10.978] Exception Message: TF255186: The following SQL Server Reporting Services Instance could not be found: COMRS. The server name is: SQLProdA. (type TfsAdminException)  
    Any ideas what the issue is?
    Thanks,
    reuvy

    Hi Charles,
    Thanks for the help. I already saw those links, and am already trying with the format. As I wrote above:
    Server: SQLProdA, Instance Name COMRS
    So I wrote in the box "SQLProdA\COMRS" (without quotes of course) and I still keep getting that error.
    I don't know if it matters, but although this is indeed a named instance, nonetheless, the path to the report server uses the default url (ie.
    http://servername/reports) as opposed to the name instance version (ie.
    http://servername_instance/reports) as mentioned by your link and this post:
    https://msdn.microsoft.com/en-us/library/bb552341.aspx
    But, I checked with Fiddler on the server and didn't see it trying to even access the link so I don't think it is related. I saw with Process Monitor that it is indeed trying to access via the network resources on SQLProdA, so I know it's trying.
    I have noticed something in the past, and wondered if this could be the issue, that for example if I have Management Studio 2014 installed, I cannot connect to a Reporting Services instance which is 2012. Only when Management Studio 2012 is installed
    and being used can I connect. I wondered if this possibly could be related, that maybe the API or something else which the installer is using is missing some component to connect to the RS instance.
    Just in case, I already installed both the SQL 2012 and 2014 Client Tools Connectivity (although I first installed 2014, and then 2012).
    Do you think this could be the issue? If not, do you possibly have any other leads?
    Thanks,
    Reuvy

  • "The service RASReportFactory could not be found" error

    I receive the error: "The service RASReportFactory could not be found" when I call the following line of code:
    IReportAppFactory reportAppFactory = (IReportAppFactory) es.getService("RASReportFactory");
    I believe this is due to a missing JAR file in my application classpath, namely either rasapp.jar or rascore.jar.  Can anyone confirm?  Is there anything else that could possibly cause this runtime error?
    Thanks...

    try:
    IReportAppFactory reportAppFactory = (IReportAppFactory) es.getService("","RASReportFactory");
    If you were missing rascore.jar or rasapp.jar you should see a compile time error like "class xxx not found". Also make sure that the RAS service on Enterprise is up.

  • The service WebiReportEngine could not be found : Help me resolve the problem

    com.crystaldecisions.sdk.exception.SDKException$ServiceNotFound: The service WebiReportEngine could not be found
         at com.crystaldecisions.sdk.occamgr.internal.a.getOCCAFactory(Unknown Source)
         at com.crystaldecisions.sdk.framework.internal.b.getService(Unknown Source)
         at org.apache.jsp.view_005fwebireport_005fhtml_jsp$ReportEngine_Common.logon(view_005fwebireport_005fhtml_jsp.java:306)
         at org.apache.jsp.view_005fwebireport_005fhtml_jsp$ReportEngine_Common.getDocumentInstance(view_005fwebireport_005fhtml_jsp.java:330)
         at org.apache.jsp.view_005fwebireport_005fhtml_jsp._jspService(view_005fwebireport_005fhtml_jsp.java:472)
         at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
         at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
         at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
         at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
         at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
         at java.lang.Thread.run(Thread.java:595)

    One more point  -  a JAR file callled rebean.jar was missing ....  Thincadenza.jar  was the one I had earlier ..
    This was another cause for the problem ... I needed  to have all  the necessary   JAR files ...
    I used the code snippet . Its working fine ...

  • The Web application at could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application

    Hi,
    I have created on windows service to fetch sharepoint list ad update the list items.
    when i run this service in sharepoint server(where the sharepoint site is hosted),it is working fine. If i run the same service in another machine(sharepoint installed in this machine also). it is giving the below error
    The Web application at [URL] could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application.
    Code snippet
    SPSite sharepointSite = null;
                SPWeb rootWeb = null;
                try
                    //SPList current = null, previous = null;
                    string colmId = ConfigurationManager.AppSettings[ID_COLM];
                    List<TaskEntity> list = new List<TaskEntity>();
                    sharepointSite = new SPSite(URL);
                    rootWeb = sharepointSite.OpenWeb();
                    SPList current = rootWeb.Lists[ConfigurationManager.AppSettings[OMEGA_REGISTRATION_LIST]];
                    WriteEventLog("current" + current.Items.Count.ToString());
                catch (Exception ex)
                    ExceptionMethod(ex);
                finally
                    sharepointSite = null;
                    rootWeb = null;
    I have pointed .net framework to 3.5 version and target palform as Any CPU. Please suggest me

    Hi mallela1,
    I also had similar issue couple of months back when I was trying to access a remote URL from a Windows service when the site does not exists in the server where service resides.
    You cannot access a remote url (even though it is SharePoint server and also in same network ) from server object model.
    SPSite can look in the current server only. here what is happening is SPSite will look for this in the current server DB and it is not finding this errror.
    So please dont use ServerObject model for accessing remote sites. You can use Client Object model for the code /requirement you have stated above.
    I wasted lot of time in finding a work around to make to work. It did not. So look for other options.
    Regards,
    Nandini

  • Web service fault:  could not find a target service

    I'm attempting to invoke a method on a web service. I
    instantiate the web service and call the method as indicated in the
    first three lines of the attached code (where sf_cred is a simple
    structure).
    The first two lines are fine, but the call to the "login"
    method produces the following error:
    Could not perform web service invocation "login".
    Here is the fault returned when invoking the web service
    operation:
    AxisFault
    faultCode: {
    http://xml.apache.org/axis/}Server.NoService}
    faultSubcode:
    faultString: The AXIS engine could not find a target service
    to invoke! targetService is
    faultActor:
    faultNode:
    faultDetail:
    http://xml.apache.org/axis/}stackTrace:The
    AXIS engine could not find a target service to invoke!
    targetService is
    at
    org.apache.axis.message.SOAPFaultBuilder.createFault(SOAPFaultBuilder.java:221)
    at
    org.apache.axis.message.SOAPFaultBuilder.endElement(SOAPFaultBuilder.java:128)
    at
    org.apache.axis.encoding.DeserializationContext.endElement(DeserializationContext.java:10 87)
    at
    org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown
    Source)
    at
    org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown
    Source)
    at
    org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch( Unknown
    Source)
    at
    org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown
    Source)
    at org.apache.xerces.parsers.XML11Configuration.parse...
    Can anyone point me to the cause of this error, either with
    something missing in my code or with a problem in the WSDL
    (provided in attached code)?

    ERROR [EngineConfigurationFactoryServlet] Unable to
    find config file
    Creating new servlet engine config file:
    /WEB-INF/server-config.wsdd
    I want to know what is server-config.wsdd
    what it contains?You can take this generated file and include it in your project. For a complete description of the various elements see:
    http://ws.apache.org/axis/java/reference.html#DeploymentWSDDReference
    My Eclipse IDE don't have required set AXISCLASSPATH.
    because already
    include the folowing jar automatically
    )saaj.jar
    ii)jaxrpc.jar
    iii)commons-discovery.jar
    iv)commons-logging.jar
    v)log4j-1.2.8.jarWhat does happyaxis.jsp say? From the docs:
    Java 1.4 changed the rules as to how packages beginning in java.* and javax.* get loaded. Specifically, they only get loaded from endorsed directories. jaxrpc.jar and saaj.jar contain javax packages, so they may not get picked up. If happyaxis.jsp (see below) cannot find the relevant packages, copy them from axis/WEB-INF/lib to CATALINA_HOME/common/lib and restart Tomcat.
    Message was edited by:
    YoGee

  • Save for Web - The operation could not be completed. Access is denied.

    Hello everyone! I was hoping it wouldn't have to come to this, but unfortunately, I really need help with my Adobe Photoshop. I run on Windows 32x and my program is Photoshop CS6 (Portable and its 64 bit), which I've had for about a year. Yesterday, I made a GIF and I tried to save it but along came the message saying "The operation could not be completed. Access is denied."
    I reset my preferences (more than once!), restarted my laptop and cleared up a bunch of memory on my hard drive. The mode is set to 8 Bits/Channel and RGB Color. I really have tried to look at every thread I could, but alas I could not find anything. I would really appreciate some help. Here is my system info!
    Any advice would really go a long way to helping me, and I am desperate. Thanks.

    Make sure that you have read write access to the foldler that you're trying to save your file to.  Save for web doesn't save in the same location as where the file resides. It remembers that last location used, and you may not have access to that.

  • Web service handler could not called in client web service

    Hi All,
    I have two web service ServiceA & ServiceB and both implemented in weblogic.
    The ServiceA is SSL enable and protocol is https which is not published by me.
    The ServieB is my web service(wls8.1) and act as client for ServiceA.
    My problem is when i hit my service, its not able set the handler when it call ServiceA but it is invoking the service and giving application exception like authentication error.
    My service file:
    import java.util.ArrayList;
    import java.util.HashMap;
    import java.util.Iterator;
    import java.util.List;
    import java.util.Map;
    import javax.xml.namespace.QName;
    import javax.xml.rpc.handler.HandlerInfo;
    import javax.xml.rpc.handler.HandlerRegistry;
    import javax.xml.rpc.handler.soap.SOAPMessageContext;
    import weblogic.webservice.client.SSLAdapterFactory;
    import weblogic.webservice.client.WLSSLAdapter;
    public class HelloService {
    String wsdl = "https://188.122.123.23/RemoetService?WSDL";
    static {
    SSLAdapterFactory factory = SSLAdapterFactory.getDefaultFactory();
    WLSSLAdapter adapter = (WLSSLAdapter) factory.getSSLAdapter();
    adapter.setTrustedCertificatesFile("D:\\lib\\certs
    cacerts");
    factory.setDefaultAdapter(adapter);
    System.setProperty("weblogic.xml.encryption.verbose","true");
    System.setProperty("weblogic.xml.signature.verbose","true");
    System.setProperty("weblogic.webservice.verbose","true");
    public String sayHello(String user) {
    RemoteService_Impl service = new RemoteService_Impl(wsdl);
    RemotePortType port = service.getRemoteServicePort1();
    String namespace = service.getServiceName()
    .getNamespaceURI();
    QName portName = new QName(namespace,
    "RemoteServicePortType");
    HandlerRegistry reg = service.getHandlerRegistry();
    List handlerList = new ArrayList();
    Map map = new HashMap();
    map.put("Username", "user1");
    map.put("Password", "pwd1");
    HandlerInfo info = new HandlerInfo();
    info.setHandlerClass(WSClientHandler .class);
    info.setHandlerConfig(map);
    handlerList.add(info);
    reg.setHandlerChain(portName,(List)handlerList);
    RemoteServiceResponse = port.callMe(name);
    My Handler file:
    package com.test;
    import java.util.Map;
    import javax.xml.namespace.QName;
    import javax.xml.rpc.handler.Handler;
    import javax.xml.rpc.handler.HandlerInfo;
    import javax.xml.rpc.handler.MessageContext;
    import javax.xml.rpc.handler.soap.SOAPMessageContext;
    import javax.xml.soap.Name;
    import javax.xml.soap.SOAPElement;
    import javax.xml.soap.SOAPEnvelope;
    import javax.xml.soap.SOAPException;
    import javax.xml.soap.SOAPHeader;
    import javax.xml.soap.SOAPHeaderElement;
    public class WSClientHandler implements Handler {
    private HandlerInfo handlerInfo;
    public WSClientAuthenticateHandler(){}
    public void init(HandlerInfo hi) {
    System.out.println("Handler init");
    handlerInfo = hi;
    public void destroy() {
    System.out.println("Handler destroy method called");
    handlerInfo = null;
    public QName[] getHeaders() {
    System.out.println("Handler Header method called");
    try {
    Map map = handlerInfo.getHandlerConfig();
    QName[] headers = handlerInfo.getHeaders();
    System.out.println(" Config :"+map);
    for(int i=0;i<headers.length;i++) {
    System.out.println(headers.getLocalPart()+" "+
    headers.toString()+" "+headers.getNamespaceURI());
    }catch(Exception e) {
    e.printStackTrace();
    return handlerInfo.getHeaders();
    public boolean handleRequest(MessageContext mc) {
    SOAPMessageContext smc = (SOAPMessageContext) mc;
    System.out.println("Calling handler class.....................");
    try {
    SOAPEnvelope se = smc.getMessage().getSOAPPart().getEnvelope();
    System.out.println("Calling handler class.....................");
    SOAPHeader soapHeader = se.getHeader();
    Name headerName = se.createName("Security","wsse","http://schemas.xmlsoap.org/ws/2002/07/secext");
    SOAPHeaderElement headerElement = soapHeader.addHeaderElement(headerName);
    SOAPElement element = headerElement.addChildElement(se.createName("UsernameToken", "wsse", "http://schemas.xmlsoap.org/ws/2002/07/secext"));
    element.addChildElement(se.createName("Username", "wsse","http://schemas.xmlsoap.org/ws/2002/07/secext")).addTextNode("testuser");
    element.addChildElement(se.createName("Password", "wsse","http://schemas.xmlsoap.org/ws/2002/07/secext")).addTextNode("testpwd");
    System.out.println("Calling handler class.....................");
    System.out.println("** Request: \n "se.toString()"\n");
    }catch(SOAPException e) {
    e.printStackTrace();
    return true;
    /** * Specifies that the SOAP response message be logged to a
    * log file before the
    * * message is sent back to the client application
    * that invoked the Web service.
    public boolean handleResponse(MessageContext mc) {
    System.out.println("Handler Response method called");
    SOAPMessageContext messageContext = (SOAPMessageContext) mc;
    System.out.println("** Response: \n"messageContext.getMessage().toString()"\n");
    return true;
    /** * Specifies that a message be logged to the log file if a SOAP fault is
    * * thrown by the Handler instance.
    public boolean handleFault(MessageContext mc) {
    SOAPMessageContext messageContext = (SOAPMessageContext) mc;
    System.out.println("** Fault: \n"messageContext.getMessage().toString()"\n");
    return true;
    Please need help here.
    Thanks in Advance,
    pps

    I have tested static client calling using handler simple above service and found the issues.
    QName portName = new QName(namespace,
    "*RemoteServicePortType*");
    The above line code has created the issues,becuase in wsdl file ( given similar wsdl file).
    <?xml version="1.0"; encoding="UTF-8"?>
    <definitions name="HelloService"
    targetNamespace="http://www.ecerami.com/wsdl/HelloService.wsdl"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    xmlns:tns="http://www.ecerami.com/wsdl/HelloService.wsdl"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    <message name="SayHelloRequest">
    <part name="firstName" type="xsd:string"/>
    </message>
    <message name="SayHelloResponse">
    <part name="greeting" type="xsd:string"/>
    </message>
    *<portType name="RemoteServicePortType">*
    <operation name="sayHello">
    <input message="tns:SayHelloRequest"/>
    <output message="tns:SayHelloResponse"/>
    </operation>
    </portType>
    <binding name="Hello_Binding" type="tns:*RemoteServicePortType*">
    <soap:binding style="rpc"
    transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="sayHello">
    <soap:operation soapAction="sayHello"/>
    <input>
    <soap:body
    encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
    namespace="urn:examples:helloservice"
    use="encoded"/>
    </input>
    <output>
    <soap:body
    encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
    namespace="urn:examples:helloservice"
    use="encoded"/>
    </output>
    </operation>
    </binding>
    <service name="Hello_Service">
    <port binding="tns:Hello_Binding" name="*RemoteServicePortType1*">
    <soap:address
    location="http://host1:8080/soap/servlet/rpcrouter"/>
    </port>
    <port binding="tns:Hello_Binding" name="*RemoteServicePortType2*">
    <soap:address
    location="http://host2:8080/soap/servlet/rpcrouter"/>
    </port>
    <port binding="tns:Hello_Binding" name="*RemoteServicePortType3*">
    <soap:address
    location="http://host3:8080/soap/servlet/rpcrouter"/>
    </port>
    <port binding="tns:Hello_Binding" name="*RemoteServicePortType4*">
    <soap:address
    location="http://host4:8080/soap/servlet/rpcrouter"/>
    </port>
    </service>
    </definitions>
    From the above WSDL, I have four port name (port binding="tns:Hello_Binding" name="*RemoteServicePortType1*) which is not matching with PortType (portType name="*RemoteServicePortType*")
    even i have iterated from getPorts() method and used to invoke the service.But handler was not calling when i invoke.
    Please guide me here how i specify correct portname which can call Handler class also.
    Thanks in advance,
    pps

  • Web service handler could not registered/called in client web service

    Hi Expert,
    I have two web service ServiceA & ServiceB and both implemented in weblogic.
    The ServiceA is SSL enable and protocol is https which is not published by me.
    The ServieB is my web service(wls8.1) and act as client for ServiceA.
    My problem is when i hit my service, its not able set the handler when it call ServiceA but it is invoking the service and giving application exception like authentication error.
    My service file:
    import java.util.ArrayList;
    import java.util.HashMap;
    import java.util.Iterator;
    import java.util.List;
    import java.util.Map;
    import javax.xml.namespace.QName;
    import javax.xml.rpc.handler.HandlerInfo;
    import javax.xml.rpc.handler.HandlerRegistry;
    import javax.xml.rpc.handler.soap.SOAPMessageContext;
    import weblogic.webservice.client.SSLAdapterFactory;
    import weblogic.webservice.client.WLSSLAdapter;
    public class HelloService {
    String wsdl = "https://188.122.123.23/RemoetService?WSDL";
    static     {
              SSLAdapterFactory factory =                SSLAdapterFactory.getDefaultFactory();
              WLSSLAdapter adapter = (WLSSLAdapter)     factory.getSSLAdapter();
              adapter.setTrustedCertificatesFile("D:\\lib\\certs\\cacerts");
              factory.setDefaultAdapter(adapter);
              System.setProperty("weblogic.xml.encryption.verbose","true");
              System.setProperty("weblogic.xml.signature.verbose","true");
              System.setProperty("weblogic.webservice.verbose","true");
         public String sayHello(String user) {
              RemoteService_Impl service = new RemoteService_Impl(wsdl);
              RemotePortType port = service.getRemoteServicePort1();
              String namespace = service.getServiceName()
                        .getNamespaceURI();
              QName portName = new QName(namespace,
                        "RemoteServicePortType");
              HandlerRegistry reg = service.getHandlerRegistry();
              List handlerList = new ArrayList();
              Map map = new HashMap();
              map.put("Username", "user1");
              map.put("Password", "pwd1");
              HandlerInfo info = new HandlerInfo();
              info.setHandlerClass(WSClientHandler .class);
              info.setHandlerConfig(map);
              handlerList.add(info);
              reg.setHandlerChain(portName,(List)handlerList);
              RemoteServiceResponse = port.callMe(name);
    My Handler Class:
    package com.test;
    import java.util.Map;
    import javax.xml.namespace.QName;
    import javax.xml.rpc.handler.Handler;
    import javax.xml.rpc.handler.HandlerInfo;
    import javax.xml.rpc.handler.MessageContext;
    import javax.xml.rpc.handler.soap.SOAPMessageContext;
    import javax.xml.soap.Name;
    import javax.xml.soap.SOAPElement;
    import javax.xml.soap.SOAPEnvelope;
    import javax.xml.soap.SOAPException;
    import javax.xml.soap.SOAPHeader;
    import javax.xml.soap.SOAPHeaderElement;
    public class WSClientHandler implements Handler {
         private HandlerInfo handlerInfo;
         public WSClientAuthenticateHandler(){}
         public void init(HandlerInfo hi) {   
              System.out.println("Handler init");
              handlerInfo = hi;
         public void destroy() {
              System.out.println("Handler destroy method called");
              handlerInfo = null;
         public QName[] getHeaders() {
              System.out.println("Handler Header method called");
              try     {
                   Map map = handlerInfo.getHandlerConfig();
                   QName[] headers = handlerInfo.getHeaders();
                   System.out.println(" Config :"+map);
                   for(int i=0;i<headers.length;i++)     {
                        System.out.println(headers.getLocalPart()+" "+
                        headers[i].toString()+" "+headers[i].getNamespaceURI());
              }catch(Exception e)     {
                   e.printStackTrace();
              return handlerInfo.getHeaders();
         public boolean handleRequest(MessageContext mc) {   
              SOAPMessageContext smc = (SOAPMessageContext) mc;
              System.out.println("Calling handler class.....................");
              try     {
              SOAPEnvelope se =      smc.getMessage().getSOAPPart().getEnvelope();
              System.out.println("Calling handler class.....................");
         SOAPHeader soapHeader = se.getHeader();
         Name headerName = se.createName("Security","wsse","http://schemas.xmlsoap.org/ws/2002/07/secext");
         SOAPHeaderElement headerElement = soapHeader.addHeaderElement(headerName);
         SOAPElement element = headerElement.addChildElement(se.createName("UsernameToken", "wsse", "http://schemas.xmlsoap.org/ws/2002/07/secext"));
         element.addChildElement(se.createName("Username", "wsse","http://schemas.xmlsoap.org/ws/2002/07/secext")).addTextNode("testuser");
         element.addChildElement(se.createName("Password", "wsse","http://schemas.xmlsoap.org/ws/2002/07/secext")).addTextNode("testpwd");
         System.out.println("Calling handler class.....................");
                   System.out.println("** Request: \n "+se.toString()+"\n");
              }catch(SOAPException e)     {
                   e.printStackTrace();
              return true;
         /** * Specifies that the SOAP response message be logged to a
         * log file before the
         * * message is sent back to the client application
         * that invoked the Web service.
         public boolean handleResponse(MessageContext mc) {  
              System.out.println("Handler Response method called");
              SOAPMessageContext messageContext = (SOAPMessageContext) mc;
              System.out.println("** Response: \n"+messageContext.getMessage().toString()+"\n");
              return true;
         /** * Specifies that a message be logged to the log file if a SOAP fault is
         * * thrown by the Handler instance.
         public boolean handleFault(MessageContext mc) {   
              SOAPMessageContext messageContext = (SOAPMessageContext) mc;
              System.out.println("** Fault: \n"+messageContext.getMessage().toString()+"\n");
              return true;
    Please need help here.
    Thanks in Advance,
    pps

    I have tested static client calling using handler simple above service and found the issues.
    QName portName = new QName(namespace,
    *"RemoteServicePortType");*
    The above line code has created the issues,becuase in wsdl file ( given similar wsdl file).
    <?xml version="1.0"; encoding="UTF-8"?>
    <definitions name="HelloService"
    targetNamespace="http://www.ecerami.com/wsdl/HelloService.wsdl"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    xmlns:tns="http://www.ecerami.com/wsdl/HelloService.wsdl"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    <message name="SayHelloRequest">
    <part name="firstName" type="xsd:string"/>
    </message>
    <message name="SayHelloResponse">
    <part name="greeting" type="xsd:string"/>
    </message>
    <portType name="*RemoteServicePortType*">
    <operation name="sayHello">
    <input message="tns:SayHelloRequest"/>
    <output message="tns:SayHelloResponse"/>
    </operation>
    </portType>
    <binding name="Hello_Binding" type="tns:*RemoteServicePortType*">
    <soap:binding style="rpc"
    transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="sayHello">
    <soap:operation soapAction="sayHello"/>
    <input>
    <soap:body
    encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
    namespace="urn:examples:helloservice"
    use="encoded"/>
    </input>
    <output>
    <soap:body
    encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
    namespace="urn:examples:helloservice"
    use="encoded"/>
    </output>
    </operation>
    </binding>
    <service name="Hello_Service">
    +<port binding="tns:Hello_Binding" name="*RemoteServicePortType1*">+
    +<soap:address+
    location="http://host1:8080/soap/servlet/rpcrouter"/>
    +</port>+
    +<port binding="tns:Hello_Binding" name="*RemoteServicePortType2*">+
    +<soap:address+
    location="http://host2:8080/soap/servlet/rpcrouter"/>
    +</port>+
    +<port binding="tns:Hello_Binding" name="*RemoteServicePortType3*">+
    +<soap:address+
    location="http://host3:8080/soap/servlet/rpcrouter"/>
    +</port>+
    +<port binding="tns:Hello_Binding" name="*RemoteServicePortType4*">+
    +<soap:address+
    location="http://host4:8080/soap/servlet/rpcrouter"/>
    +</port>+
    </service>
    </definitions>
    From the above WSDL, I have four port name (port binding="tns:Hello_Binding" name="*RemoteServicePortType1*) which is not matching with PortType (portType name="*RemoteServicePortType*")
    even i have iterated from getPorts() method and used to invoke the service.But handler was not calling when i invoke.
    Please guide me here how i specify correct portname which can call Handler class also.
    Thanks in advance,
    pps

  • Custom Timer Job to execute WCF web service error - Could not find default endpoint element that references contract

    Hi,
    I am currently creating custom timer job to call WCF web service to perform nighty job to update employee document library metadata. If I update regular list/library items it updates correctly on a specified interval basis. However when I try to integrate
    the WCF client, it throws error shown below :
    Could not find default endpoint element that references contract EmployeeServiceReference.
    EmployeeServiceClient in the ServiceModel client configuration section. This might be because no configuration file was found for your application, or because no endpoint element matching this contract could be found in the client element.
    I followed exact instructions Andrew Connell has provided but included my logic in execute()
    public
    override
    void Execute(Guid
    targetInstanceId)
    var empClient =
    new
    'ServiceReference.EmployeeServiceClient();
    var employee = empClient.EmployeesMethod();
    I have tried all approaches to manually adding app.config settings in sharepoing web.config but still it throws the error mentioned. It seems that application config and sharepoint site config binding issue still exist and cannot be resolved.
    <system.serviceModel>
    <bindings>
    <basicHttpBinding>
    <binding
    name="BasicHttpBinding_EmployeeService"
    />
    </basicHttpBinding>
    <netTcpBinding>
    <binding
    name="CustomBinding_EmployeeService">
    <security>
    <transport
    protectionLevel="None"
    />
    </security>
    </binding>
    </netTcpBinding>
    <wsHttpBinding>
    <binding
    name="WSHttpBinding_EmployeeService">
    <security
    mode="None"
    />
    </binding>
    </wsHttpBinding>
    </bindings>
    <client>
    <endpoint
    address="http://services.mycomp.com/EmployeeService.svc"
    binding="wsHttpBinding"
    bindingConfiguration="WSHttpBinding_EmployeeService"
    contract="EmployeeServiceReference.EmployeeService"
    name="WSHttpBinding_EmployeeService"
    />
    <endpoint
    address="http://services.mycomp.com/EmployeeService.svc/soap"
    binding="basicHttpBinding"
    bindingConfiguration="BasicHttpBinding_EmployeeService"
    contract="EmployeeServiceReference.EmployeeService"
    name="BasicHttpBinding_EmployeeService"
    />
    <endpoint
    address="net.tcp://crmapp.mycomp.com:5050/EmployeeService.svc/tcp"
    binding="netTcpBinding"
    bindingConfiguration="CustomBinding_EmployeeService"
    contract="EmployeeServiceReference.EmployeeService"
    name="CustomBinding_EmployeeService">
    <identity>
    <userPrincipalName
    value="[email protected]"
    />
    </identity>
    </endpoint>
    </client>
    </system.serviceModel>
    Will you please help resolving this issue?

    Hi,
    You can use any of the three approaches:-
    1) Access web application's web.config programmatically in Execute() method.
    http://praveenkasireddy.wordpress.com/2012/12/14/access-web-application-configuration-values-in-timer-job-sharepoint/
    2) Store the configuration in xml and upload it to SharePoint document library then read from there
    http://www.sharepointdynamics.net/2011/08/using-an-xml-settings-file-to-store-values-for-your-sharepoint-projects/
    3) Programmatically configure a WCF endpoint.
    http://msdn.microsoft.com/en-us/library/ff647110.aspx
    Regards, Shruti

  • Web Service Operations

    Hi,
    Is it possible to get list of operations from an wsdl file through Web service client? with out using wsdl2java tool?
    Thanks.

    Hello Bala,
    I have tried using many WSDL files. Even the WSDL file stated in the blog by Kai /people/community.user/blog/2006/10/27/create-new-argo-object-with-the-argo-web-service-wizard could not show the service methods for me.
    I also tried this wsdl file as well.
    http://www.ignyte.com/webservices/ignyte.whatsshowing.webservice/moviefunctions.asmx?wsdl
    And offcourse, my intension is to try Amazon or ebay webservices and get the search results which I still could not get any service methods displayed
    Thanking you.
    Regards,
    Ajay.

  • The type '*', provided as the Service attribute value in the ServiceHost directive, or provided in the configuration element * could not be found

    I have a provider hosted app in sharepoint which works locally without problem. I followed this tutorial to publish it to azure
    http://blogs.technet.com/b/sharepointdevelopersupport/archive/2013/09/05/how-to-deploy-a-provider-hosted-app-as-an-azure-site.aspx
    However after publishing the webservice doesnt work I get this exception:
    [InvalidOperationException: The type 'x.IntranetWeb.Services.AppEventReceiver', provided as the Service attribute value in the ServiceHost directive, or provided in the configuration element system.serviceModel/serviceHostingEnvironment/serviceActivations could not be found.]
    System.ServiceModel.Activation.ServiceHostFactory.CreateServiceHost(String constructorString, Uri[] baseAddresses) +62739
    System.ServiceModel.HostingManager.CreateService(String normalizedVirtualPath, EventTraceActivity eventTraceActivity) +1429
    System.ServiceModel.HostingManager.ActivateService(ServiceActivationInfo serviceActivationInfo, EventTraceActivity eventTraceActivity) +52
    System.ServiceModel.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath, EventTraceActivity eventTraceActivity) +598
    [ServiceActivationException: The service '/Services/AppEventReceiver.svc' cannot be activated due to an exception during compilation. The exception message is: The type 'x.IntranetWeb.Services.AppEventReceiver', provided as the Service attribute value in the ServiceHost directive, or provided in the configuration element system.serviceModel/serviceHostingEnvironment/serviceActivations could not be found..]
    System.Runtime.AsyncResult.End(IAsyncResult result) +486572
    System.ServiceModel.Activation.HostedHttpRequestAsyncResult.End(IAsyncResult result) +174
    System.ServiceModel.Activation.ServiceHttpModule.EndProcessRequest(IAsyncResult ar) +345998
    System.Web.AsyncEventExecutionStep.OnAsyncEventCompletion(IAsyncResult ar) +9683593
    My web.config which I didnt touch.
    <?xml version="1.0" encoding="utf-8"?>
    <!--
    For more information on how to configure your ASP.NET application, please visit
    http://go.microsoft.com/fwlink/?LinkId=301880
    -->
    <configuration>
    <appSettings>
    <add key="webpages:Version" value="3.0.0.0" />
    <add key="webpages:Enabled" value="false" />
    <add key="ClientValidationEnabled" value="true" />
    <add key="UnobtrusiveJavaScriptEnabled" value="true" />
    <add key="ClientId" value="xx-04e7-4caf-854a-89c20577d7da" />
    <add key="ClientSecret" value="ljguTvxHR+xx+Pl1IMg1Hjt5rsQ=" />
    </appSettings>
    <system.web>
    <compilation debug="true" targetFramework="4.5" />
    <httpRuntime targetFramework="4.5" />
    <customErrors mode="Off"/>
    </system.web>
    <runtime>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
    <dependentAssembly>
    <assemblyIdentity name="Newtonsoft.Json" culture="neutral" publicKeyToken="30ad4fe6b2a6aeed" />
    <bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0" />
    </dependentAssembly>
    <dependentAssembly>
    <assemblyIdentity name="System.Web.Optimization" publicKeyToken="31bf3856ad364e35" />
    <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="1.1.0.0" />
    </dependentAssembly>
    <dependentAssembly>
    <assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35" />
    <bindingRedirect oldVersion="0.0.0.0-1.5.2.14234" newVersion="1.5.2.14234" />
    </dependentAssembly>
    <dependentAssembly>
    <assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" />
    <bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
    </dependentAssembly>
    <dependentAssembly>
    <assemblyIdentity name="System.Web.WebPages" publicKeyToken="31bf3856ad364e35" />
    <bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
    </dependentAssembly>
    <dependentAssembly>
    <assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
    <bindingRedirect oldVersion="1.0.0.0-5.2.0.0" newVersion="5.2.0.0" />
    </dependentAssembly>
    </assemblyBinding>
    </runtime>
    <system.serviceModel>
    <bindings>
    <basicHttpBinding>
    <!--Used by app for SharePoint-->
    <binding name="secureBinding">
    <security mode="Transport" />
    </binding>
    </basicHttpBinding>
    </bindings>
    <protocolMapping>
    <add binding="basicHttpBinding" scheme="https" bindingConfiguration="secureBinding" />
    </protocolMapping>
    </system.serviceModel>
    <system.webServer>
    <handlers>
    <remove name="ExtensionlessUrlHandler-Integrated-4.0" />
    <remove name="OPTIONSVerbHandler" />
    <remove name="TRACEVerbHandler" />
    <add name="ExtensionlessUrlHandler-Integrated-4.0" path="*." verb="*" type="System.Web.Handlers.TransferRequestHandler" preCondition="integratedMode,runtimeVersionv4.0" />
    </handlers>
    </system.webServer>
    </configuration>
    and a piece of the code of the remote event receiver
    <%@ ServiceHost Language="C#" Debug="true" Service="x.IntranetWeb.Services.AppEventReceiver" CodeBehind="AppEventReceiver.svc.cs" %>
    namespace x.IntranetWeb.Services
    public class AppEventReceiver : IRemoteEventService
    Follow me on Twitter
    levalencia Blog

    Hi,
    The issue here is the mapping of the interface to the service in question, and usually points to a possible mistype or rename of something within your service architecture.
    You need to make sure your namespace and service name here match your service name itself.
    For detailed information, you could refer to:
    https://haddicus.wordpress.com/2011/06/06/service-attribute-value-not-found-wcf-services/
    http://stackoverflow.com/questions/9557221/the-type-restservice-weddingservice-provided-as-the-service-attribute-value-i
    Regards

  • How to solve Error SPSite - The Web application at address could not be found

    Hello,
    I am trying to find out the internal name of a custom SharePoint list columns, for this I have used following code snippet in my
    console application but getting below error. The site I am accessing is a public SharePoint web site. This code is working
    well with my local host site and i am able to get the internal names of any list columns but don't understand why this is failing with
    public SharePoint site
    For avoiding this issue I have done following steps:
    1.Rebuild the application
    2.changed the  platform target as "Any CPU"
    3.Visual studio and this public site is working in my admin account, but still I am getting the error!
    I use visual studio 2010 and SharePoint 2010
    please note the error I am getting
    Error : The Web application at https://public.sp.a5-group.com/ could not be found. Verify that you have typed the URL correctly.
    If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application
    Code Snippet
    static void Main(string[] args)
    using (SPSite Site = new SPSite("https://public.sp.a5-group.com/"))
    using (SPWeb web = Site.RootWeb)
    SPList splst = web.Lists["ListCard"];
    foreach (var field in splst.Fields)
    bool isHidden = splst.Fields[field.ToString()].Hidden;
    if (!isHidden)
    string internalName = splst.Fields[field.ToString()].InternalName; //This will give you the internal column name.
    Console.WriteLine(internalName);
    Console.ReadLine();

    I thin you need to have sharepoint installed on same computer and URL should be working on this computer.
    If this URL WEB APP is in your IISsite try to create disableloopbackcheck registry which should be help
    When you use the fully qualified domain name (FQDN) or a custom host header to browse a local Web site that is hosted on a computer that is running Microsoft Internet Information Services (IIS) 5.1 or a later version, you may receive an error
    message 
    http://support.microsoft.com/kb/896861

Maybe you are looking for