Loading JDO in a web service endpoint

I have a web service endpoint (Java class exposed as a web service) I'm developing in NW04-sp9, and I'm having trouble getting access to JDO in my web service.  I have an object class I'd like to persist using JDO, and I've developed them and run the build helper utility to make them persistable.  I believe that this works, because I can look at the .class file in a text editor and see references to javax/jdo/spi/PersistenceCapable.
In my WSE, I try to get the default PersistenceManagerFactory doing a JNDI lookup with:
_pmf=(PersistenceManagerFactory)ctx.lookup("java:comp/env/jdo/defaultPMF");
which fails with a NamingException.  Based on another forum posting, I tried:
_pmf=(PersistenceManagerFactory)ctx.lookup("deployedAdapters/jdo/defaultPMF/shareable/jdo/defaultPMF");
Which actually seems to work, but when I do this, I get a NoClassDefFoundError on javax/jdo/PersistenceManagerFactory from the web service endpoint.
I have added the com.sap.jdo application to my WSE's application-j2ee-engine.xml file, as described in the JDO chapter of the NW04 documentation.
Any clues what I'm missing?
Thanks,
- Bill

>
> I will check if it is possible to declare resource
> references for web services and tell you.
>
Thanks very much
>
> By the way, I have just found out that one can lookup
> JCA connection factories in the global JNDI context
> without having to declare resource references. I
> don't like this. In my opinion, applications should
> never access the global JNDI context directly, but
> only the local java:comp/env context.
>
> You can find the JDO PMF at the following location in
> the global JNDI context:
>
> deployedAdapters/jdo/defaultPMF/shareable/jdo/default
> PMF
>
I did this (see my initial post), and I agree that it's a bad idea.  I didn't have much choice, though   When I did this, and I tried to cast the returned object to a PersistenceManagerFactory, I received a NoClassDefFoundError, which led me to believe that the JDO classes were not loaded into the web service container.  This is what led me down the resource reference path.
>
> I don't know when this deployedAdapters directory was
> introduced, but I can imagine why. Most likely, there
> are runtime environments like Web Dynpro or Web
> Services where one needs to access JCA adapters, but
> where resource references are not available.
>
Thanks again,
- Bill

Similar Messages

  • Web Service Endpoint URI expected. Not found endpoint with URI /wssproc

    Hi All,
    We are following the steps mentioned here http://help.sap.com/saphelp_nwpi71/helpdata/en/ea/c91141e109ef6fe10000000a1550b0/frameset.htm to configure the message level security in our new PI 7.1 system.
    We have created the RFC destination with prefix /wssproc/plain?style=document. But when we test the RFC connectioon, we get the following error message:
    Status HTTP Response     404
    Status Text     Not Found
    And response body is: Web Service Endpoint URI expected. Not found endpoint with URI /wssproc.
    Are we missing a configuration point? Do we need to create the endpoint manually? And if yes, how?
    Regards,
    Masoud
    Edited by: Masoud Ahanchian on Jul 23, 2009 4:58 PM

    Well, in addition to the 404 message I get the following error as well (i.e. if I go to the link http://<server>:<port>/wssproc/plain?style=document)
    Web Service Endpoint URI expected. Not found endpoint with URI /wssproc.
    Regards,
    Masoud

  • Use dynamic web services endpoints with eInsight

    Hi,
    I'm dealing with a small problem when integrating two multiple systems based on web services.
    The problem is that I�ve a WSDL that represents different web services endpoints and my Business Process have to look out the input information and access a different web service endpoint corresponding to the input code. I only want to be able to change the endpoint of the web service or change the server that is called. However I don't know how can do it or if I can.
    To explain more clearly I�ll give an example. Imagine a company with some stores. All the stores have a web service with the same WSDL (changing the endpoint). I want to be able to call the web service in different endpoints automatically, without having to import another WSDL and make changes on my Business Process.
    I hope someone can help me. Thank you in advance.

    I would prefer using a Sun's JAX-RPC implementation if you are using JBoss. USe JBossWS. There are many things you have to consider when developing a Web Services. You should probably research that first. If it is your first web service, probably you are better off using RPC style web services. The documents and samples are all available on SUN web site. Try those out. For deploying on JBoss you would require to configure some jboss specific deployment descriptors.

  • Operations not sorted in the drop list of the web service endpoint

    Hello,
    Since the beginning of oc4j standalone till the last release 10.1.3.5.0, the operations in the drop list of the web service endpoint are not alphabetically sorted,
    they are in a random order.
    If a web service contains a lot of operations, it's always difficult to find one operation in the list.
    How can this list be sorted ?
    I don't see any sort option in the web service properties (in Jdevelopper) or in the deployment descriptor (in Jdevlopper).
    Best regards
    Laurent

    You are correct...the above code is useful only when debugging in Visual Studio.  You should have better luck with either of the following two options:
    Option 1: Retrieve the id from the response of SaveChanges()
    sc.AddToSampleList(new ServiceReference.SampleListItem { Title= "Hello World" });
    System.Data.Services.Client.ChangeOperationResponse response = sc.SaveChanges().FirstOrDefault() as System.Data.Services.Client.ChangeOperationResponse;
    int id = ((ServiceReference.SampleListItem)((System.Data.Services.Client.EntityDescriptor)response.Descriptor).Entity).Id;
    Option 2: Create the list item and access its properties after calling SaveChanges()
    ServiceReference.SampleListItem li = new ServiceReference.SampleListItem { Title= "Hello World" };
    sc.AddToSampleList(li);
    sc.SaveChanges();
    int id = li.Id;

  • No business interface, component interface or web service endpoint interface found for Session Bean SessionEJB

    hi ,
    i am just using EJb in my Application
    just created an SessionBean and with Local interface in it i am getting this wierd exception with weblogic NetBeans and eclipse also
    weblogic.ejb.container.compliance.ComplianceException: No business interface, component interface or web service endpoint interface found for Session Bean SessionEJB
    weblogic.ejb.container.compliance.ComplianceException: No business interface, component interface or web service endpoint interface found for Session Bean SessionEJB
        at weblogic.ejb.container.compliance.SessionBeanClassChecker.checkInterfacesExist(SessionBeanClassChecker.java:177)
        at weblogic.ejb.container.compliance.Ejb30SessionBeanClassChecker.checkInterfacesExist(Ejb30SessionBeanClassChecker.java:27)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at weblogic.ejb.container.compliance.EJBComplianceChecker.check(EJBComplianceChecker.java:331)
        at weblogic.ejb.container.compliance.EJBComplianceChecker.checkDeploymentInfo(EJBComplianceChecker.java:280)
        at weblogic.ejb.container.ejbc.EJBCompiler.checkCompliance(EJBCompiler.java:789)
        at weblogic.ejb.container.ejbc.EJBCompiler.doCompile(EJBCompiler.java:222)
        at weblogic.ejb.container.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:461)
        at weblogic.ejb.container.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:428)
        at weblogic.ejb.container.deployer.EJBDeployer.runEJBC(EJBDeployer.java:437)
        at weblogic.ejb.container.deployer.EJBDeployer.compileJar(EJBDeployer.java:795)
        at weblogic.ejb.container.deployer.EJBDeployer.compileIfNecessary(EJBDeployer.java:683)
        at weblogic.ejb.container.deployer.EJBDeployer.prepare(EJBDeployer.java:1254)
        at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:442)
        at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:199)
        at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:517)
        at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
        at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:159)
        at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:45)
        at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:613)
        at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
        at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:184)
        at weblogic.application.internal.EarDeployment.prepare(EarDeployment.java:58)
        at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:154)
        at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:60)
        at weblogic.deploy.internal.targetserver.operations.ActivateOperation.createAndPrepareContainer(ActivateOperation.java:207)
        at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doPrepare(ActivateOperation.java:98)
        at weblogic.deploy.internal.targetserver.operations.AbstractOperation.prepare(AbstractOperation.java:217)
        at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentPrepare(DeploymentManager.java:747)
        at weblogic.deploy.internal.targetserver.DeploymentManager.prepareDeploymentList(DeploymentManager.java:1216)
        at weblogic.deploy.internal.targetserver.DeploymentManager.handlePrepare(DeploymentManager.java:250)
        at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.prepare(DeploymentServiceDispatcher.java:159)
        at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doPrepareCallback(DeploymentReceiverCallbackDeliverer.java:171)
        at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$000(DeploymentReceiverCallbackDeliverer.java:13)
        at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$1.run(DeploymentReceiverCallbackDeliverer.java:46)
        at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
        at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
        at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
        at weblogic.ejb.container.compliance.EJBComplianceChecker.check(EJBComplianceChecker.java:321)
        at weblogic.ejb.container.compliance.EJBComplianceChecker.checkDeploymentInfo(EJBComplianceChecker.java:280)
        at weblogic.ejb.container.ejbc.EJBCompiler.checkCompliance(EJBCompiler.java:789)
        at weblogic.ejb.container.ejbc.EJBCompiler.doCompile(EJBCompiler.java:222)
        at weblogic.ejb.container.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:461)
        Truncated. see log file for complete stacktrace
    >

    Hi Rajendar,
    I think the problem with having empty interfaces, or interfaces without methods for EJBs, is that they don't really make  "sense". After deploying your EJB, a client application will use JNDI or dependency injection to access your EJB.  So in your case it will look something like this
    @EJB
        mytestSSBLocal myejb; //(In this case we are using the local interface)
    In the second step, you will want to do something will your EJB, but since mytestSSBLocal doesn't define any methods, there is nothing you can do with your ejb.
    The Exception is telling you that weblogic couldn't find a complaint interface for your EJB.
    best regards, Nicolas

  • Question About Web Service Endpoint

    Is there a way to specify the endpoint of a Web Service that exposes a Data Source?
    For example, if I have a Liquid Data Control jcx with a Java package of foo.bar and the corresponding jws file is also in this package, then the web service endpoint will be http://myserver/myproject/foo/bar/mywebservice.jws.
    Is there a way to change this to say something like http://myserver/myproject/services/mywebservice.jws.
    Thanks.

    JWS files are created by Workshop. Try posting on the Workshop newsgroup or check edocs.

  • Jena Adapter and SPARQL web service endpoint

    As I understand, with Jena adapter java interface, the client can connect to Oracle RDF database directly. Why does it still need SPARQL web service endpoint? Does the query request from Jena adapter at client side have to go through SPARQL webservice first then route to Oracle server? Or the query with SPARQL need to go through webservice and non SPARQL query directly go to Oracle server?
    Thanks.

    Hi,
    You are right that a client can connect to Oracle RDF directly through the Jena Adapter. The reason for providing a SPARQL web service endpoint is to give additional interoperability and flexibility. With the SPARQL web service endpoint, one does not even need to write any Java code to interact with the underlying database. It also makes SPARQL federation a lot easier.
    Hope it helps,
    Zhe Wu

  • (URGENT) Accessing HTTPS Web Service Endpoint

    I have a java class setup as a client to a web service. The endpoint address of the service is an https address. I can successfully connect to and invoke the web service when running my code outside the database. However, once I load the java classes into the database, I receive the following....
    java.net.SocketException: SSL implementation not available
    I have loaded all the necessary JSSE jar files into the database, and have them also in my ...jdk/jre/lib/ext folder. I have set system properties to extend the SocketFactories, as noted in some other posts...i.e.,
    java.security.Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider());
    System.setProperty("java.protocol.handler.pkgs", "com.sun.net.ssl.internal.www.protocol");
    java.security.Security.setProperty("ssl.SocketFactory.provider", "com.MyCo.MySoftware.MyProject.node.ssl.SSLSocketFactoryExt");
    Can anyone give me any idea as to why this exception keeps happening...

    Hi,
    By default, your application tries to connect to the Net directly : if you have to specify a proxy, use either these lines in your code :
    System.setProperty("http.proxySet", "true");
    System.setProperty("http.proxyHost", "proxy");
    System.setProperty("http.proxyPort", "8080");
    Or specify them in the command line with the "-D"option.
    Ex : java .... -Dhttp.proxySet=true .... MyApp
    Hope it helps.
    See ya

  • How to create XML data source/ and load data from a web service to BI

    All,
    I m trying to find a 'how to' document (or any document) that shows how to create an XML data source to load data directly from a web service or from an XML file.
    I appreciate any help.

    Hi Mike,
    Two more for you:----
    /thread/111488 [original link is broken]
    http://help.sap.com/saphelp_nw70/helpdata/en/e6/1dd53bb90cbb1ae10000000a11402f/content.htm
    Regards,
    Suman

  • Loading *.txt files in web service

    I have a running web service on Axis, and can communicate with it from a j2se client and a browser test client.
    I'm attempting to load a txt file of data in the web service (stores a list of usernames). But the code can't locate the text file. Where are external resource placed if they're needed in a web service? I was assuming I could just place it next to my *.java files.
    Thanks

    I should add that I'm using Eclipse , and as such my web service seems to be self contained in my workspace for Eclipse. The structure is
    EclipseWorkspace -> myProject -> projectNamespace -> *.java
    I thought I could place my *.txt files inside the namespace directory with my Java files. I have also tried placing the *.txt file in the project directory, still no luck.

  • Change Web Service Endpoint dynamically in CE 7.2

    Hi experts.
    Is it possible to change endpoint of web services in CE 7.2?
    There are 2 ECC clients for test, so I want to change the endpoint of AWS model dynamically, for example,
    application parameters.
    Thanks for your time.

    hi,
    at design time, are you also using http://jbxsd292:50900/sapws/sap.com/WSCreateMDM_ENTAPP_com.sap.mdm.ws.gen.ejbs_WSCreateMDMVi/WSCreateMDMVi_SAP_DEFAULT_PROFILE_Service/HTTPAuthOverHTTP_1?wsdl?
    Best regards,
    john

  • Web service endpoint uri

    version: OSB 10g
    Hi,
    Can anyone tell me hoe to find the service endpoint uri for a web service derived from java classes is and deployed on weblogic? In ALSB this used to be
    in a file called weblogic-webservices.xml but this file no longer exists. I have checked oracle-webservices.xml and web.xml but haven't found a reference on what the endpoint uri is. I am invoking the web service using a business service in OSB.
    thanks.
    Damien

    I was little confused about your two statements
    Can anyone tell me hoe to find the service endpoint uri for a web service derived from java classes is and deployed on weblogic? and 'I am invoking the web service using a business service in OSB'.
    From your description it appears that you want to invoke WS through business service in OSB.
    BS---?>WS (Deployed in Weblogic and Derived from Java classes) is that the case?

  • [Tuxedo 9.1 - SALT 2.0] Web service Endpoint address

    I'm working on SALT 2.0 feature with Tuxedo 9.1.
    I have to expose one Tuxedo service as a web service.
    I followed the online documentation and this works fine.
    I just have one problem concerning the Web service exposition address (Endpoint). In my wsdf config file, I have the following AccessingPoints node :
    <AccessingPoints>
    <Endpoint id="GWWS_STAR_HTTP" address="http://servername:65002/STAR" />
    </AccessingPoints>
    Once the TMMETADA and GWWS configured, I started Tuxedo with the tmboot command and I made a test with a classical web browser thanks to get the wsdl.
    I first tried with http://servername:65002/STAR/wsdl? but I got an error.
    I made a test with http://servername:65002/wsdl? and I got a successful answer.
    Is anyone can explain to me how to expose the service with the following URL : http://servername:65002/STAR (as defined in the wsdf file) ?
    Is there another configuration to place in the SALTDEPLOY file ?
    Thanks in advance.
    With my best regards,
    Edited by: [email protected] on 5 mars 2009 07:20

    Hi Sebastien,
    The config of "<Endpoint id="GWWS_STAR_HTTP" address="http://servername:65002/STAR" />" specifies the SOAP address in WSDL, for example ,
    <wsdl:port binding="tns:simpapp_Binding" name="simpapp_GWWS1_HTTPPort">
    <soap11:address location=""http://servername:65002/STAR"/>
    </wsdl:port>
    You can not use web browser to access this address because it requires SOAP request message. The address http://servername:65002/wsdl is to retrieve the WSDL of your web service. The WSDL can be used to program or test for your exposed web services.
    If you want to test the web services directly, I would suggest you trying soapUI (http://www.soapui.org/) which is a very useful SOAP test utility. The most important is it is free:-). The steps sounds like,
    1. New a project
    Supply your WSDL address, such as http://servername:65002/wsdl to the "Initial WSDL..." box.
    2. Following the wizard steps you can create testsuite
    3. In the TestSuite, you can edit the SOAP request body directly and get the reply from GWWS.
    Hope some help.
    Wayne

  • Transport Web service endpoint?

    Hi,
    I have started to develop web services in ABAP. Basically develop Z function modules to convert it to web services.
    My process to create the web service is through SE80 Tx using the wizard. Then through SOAMANGER Transaction I create the corresponding service and can download the WSDLfile with the link "Open WSDL document for selected binding".
    It is necessary due to my client want to consume the service with an wsdl file that contains the url as an endpoint, so I need to create the service. Until this point all works perfect.
    My question is about transport orders.
    When I transport the webservice to the Quality system I have to create again the service through SOAMANAGER to get the corresponding WSDL file with the correct url, so for each transport to a new system I would have to create the service.
    Is it possible to create a transport order to transport the created services in SOAMANAGER to each system?
    May be is possible do the same action in SOAMANAGER using other transaction?
    Thanks

    Hi,
    >Is it possible to create a transport order to transport the created services in SOAMANAGER to each system?
    No it is not possible and has already been answered numerous times in this same forum.
    The endpoint is part of the runtime configuration and it should be different on the production system and on the dev system.
    So it would be illogical to transport them.
    You can only transport the Design time configuration.
    Regards,
    Olivier

  • Is possible to load a hierarchy from web services?

    Hi Experts,
    I have a doubt, exists some way to load a hierarchy of a infoobject from a system source that is a Web Services? Somebody I could do this? It would give a guide me of steps to do...
    Thanks & Regards,
    Leonel

    Usually web service datasources load into a PSA. and hierarchies are loaded using IDoc. You could however load the data from the web service into another infoobject / DSO and create a custom hierarchy datasource . The procedure for the same - I came across something like this in ABAP for BW ( SAP Press ) ... do not have it now but it can be done...

Maybe you are looking for

  • DMS document attachment to Service Entry sheet

    Hi All, One requirement, need to attach DMS document with Service entry sheet (t-code ML81N), any possibilites with object linking as in standard there is no object linking (ESSR object) available. Thank You, Manoj

  • How do I encrypt an archive for a PC user?

    I can't find a way to encrypt an archive for a PC user. There doesn't seem to be an option when making an archive from the Finder. I also tried making an encrypted disk image with Disk Utility but the PC can't open the DMG filetype apparently. In the

  • 16:9 ratio with letterboxing

    Hi, I have imported some QT clips in 16:9 wide screen ration, but when they get imported into iMovie, the above and below black bars appear. How can I fix this.

  • Power on, on a timer.

    Does anyone know how to set up my mac to turn on, on a timer?

  • HTMLDB_ITEM.POPUP_FROM_QUERY - character string buffer too small

    I am creating a updateable report with a popup_from_query item on a table with a high number of columns (40 columns) where every column should be displayed as a popup_from_query. I get the following error message when running the page: report error: