Exposing Constants in WebServices

In web service is it possible to expose the Constants used in the application. Let say for my web serice I need to pass value for Operation, possible values for this are (add, delete, update). Is it possible expose these constant values(add, delete, update) visible to client application accesssing the web service.
Server Side: public static String[] OPERATIONS={"ADD", "DELETE", "UPDATE"};
client Side: mywebsericeport.setOperation( mywebservicePort.ADD );
thanks
Manju

Check V_T511K , V_T511P also
yes it is important for some of the indian specific things like PF and ESI we maintain the constants here
check PF bas in table 511P where u will maintian the which ever is less i mean 6500
Edited by: Sikindar on Dec 30, 2008 9:29 AM

Similar Messages

  • Expose IDoc as Webservice

    Hi,
    <i>"RFC-enabled function modules, function groups that contain an RFC-enabled function module, BAPIs, and XI message interfaces can be made available as Web services without any additional programming."</i>
    http://help.sap.com/saphelp_nw04/helpdata/en/e5/a68d10f4eb894087fc9c1c3f9ae433/content.htm
    I like to know if IDoc's can also be exposed as a Webservice..? If Yes, How.
    Cheers,
    Siva Maranani.
    Message was edited by: siva  maranani

    Hi siva,
    Have you achieved this thing?
    Have you succeeded to expose IDoc as webservice?
    If yes then how you have done it?
    Thanks in Advance,
    Bhavik

  • Expose IDoc as Webservice without PI/XI

    Is it possible to expose an IDoc as an webservice without PI/XI?
    I noticed there is a port called XML-HTTP. Does it use SOAP? Can i use this port for webservices.
    Thanks.

    Hi,
    Precisely.
    Idoc is not a program but structure. You can create RFC which interact with this Idoc or related structure and then expose this RFC as webservice.
    Regards,
    Gourav

  • Exposing ejb3 as webservices

    hi java folks,
    I am exposing my existing ejb3 components as web servieces.
    cleint tries to access webservice using JNDI lookup,but i am getting following error,
    javax.naming.NameNotFoundException: service not bound
    could anybody tell me does it requires any deploy descriptor files.As i am using ejb3 its full of annotation.No deployment descriptor file is required.But to bind jndi name with webservice do i require any additional descripor files?
    please help me..
    thanks in advance.

    Thanks Timo !
    Found out to be an issue with Oracle Fusion Middleware control (http://<hostname>:<port>/em ) validating for required Inputs, but when tested with SOAP UI or Web logic Test Client (http://<hostname>:<port>/wls_utc) it works as expected. Reported the issue to Oracle Support and the problem has been reproduced there.
    Regards,
    Prashanth

  • Exposing IDoc as Webservice

    Hello Everybody,
    I want to find the way how can i expose the IDoc as webservice.
    First of all is it possible? If yes then how can we achieve this?
    Thanks In advance,
    Bhavik

    Hi Bhavik,
       There is a basic difference between web service and IDOC. Web service is a call based interface, where you use request and response mechanism to call a functionality, these are mostly synchronous. IDOC is document based interface, these are mostly assynchronous.
       Coming to your problem, since you want to use IDOC's you can not expect to get a response synchronously(Processing of IDOC depends on partner profile) and I am quite sure you are talking about an inbound scenario because for outbound scenario you will consume web service rather than exposing web service.
       If my assumption is correct then from WAS 6.20 onwards you can use FM IDOC_PROCESS_ASYNCHRONOUS (I can't recall the exact name of the FM but it sounds like this) and create a WSDL for this using BSP application 'WEBSERVICEBROWSER'.
    Regards,
    Sanjeev

  • Expose Table as Webservice

    I am trying to create a internal web service that will return a recordset based on filter.
    Platform JDev 10g
    1. Made Database connection.
    2. Created new application. (JSP, Struts, EJB)
    3. Created Model Diagram. (Which Diagram should I create.)
    If I choose web service Diagram I cannot drop my table view onto diagram.
    4. ? using When I drag the Table onto the Diagram. Do I create a EJB or Java Class. I ask this because only Java Classes can be made into WS.
    What steps do I need to take to expose a table as a webservice???

    Eric,
    You can't publish a table as a web service directly,
    You'll need some code that access the table and then you'll publish this code as a Web service.
    The code can be a simple Java class doing JDBC calls, a BC4J component, and EJB or even a PL/SQL stored procedure that you publish as a web service.
    Here are some tutorials that might help:
    For PL/SQL
    http://otn.oracle.com/tech/webservices/htdocs/series/plsql/index.html
    For BC4J
    http://otn.oracle.com/tech/webservices/htdocs/series/pattern/
    for EJB
    http://otn.oracle.com/tech/java/oc4j/1003/how_to/how-to-ws-ejb21.html
    More on http://otn.oracle.com/tech/webservices

  • Few business scenario for exposing Schema as webservice in biztalk

    Can anyone give me few business scenario when we need to publish Schema as webservice in biztalk
    Regards
    Suresh

    A lot of people prefer to publish schemas as a service as opposed to publishing the orchestration as a service. This (to list a few)..
    disassociates the orchestration version from the service definition and for every change in the orchestration you do not have to republish the web service.
    allows you to create an orchestration using direct bound ports. This provides you with a flexibility to invoke the orchestration across two-way (request-response) or one-way ports. This permits service virtualization where the same service can be invoked
    through multiple protocols, etc.
    In a large project you may be required to publish the Service Definitions (WSDL) well in advance for others to start their portion of the work, in which case having decided on the schemas, this is a easy way to publish service contracts while you work on
    building them.
    Regards.

  • Exposing complete data structure in webservice

    Hello Experts,
      I have a scenario where a Bapi functionality(server proxy) is exposed as a webservice .
    So scenario will be SOAP -> XI -> Proxy (calls a BAPI)
    In our BAPI (proxy, target structure) we are having 100+ fields. Currently the WS consumer - application making SOAP call to our webservice will send only 20 (minimum required) fields. But in near future it will be updated to send all 100 fields.
    Is it OK to include all 100 fields in source data type even though we will receive only 20 fields. (If i mark all of them as optional i.e. occurance 0..1) Or will it result in error?
    Thanks in Advance,
    XI Queries.

    Hi,
    >>Is it OK to include all 100 fields in source data type even though we will receive only 20 fields. (If i mark all of them as optional i.e. occurance 0..1) Or will it result in error?
    yes it is ok to have all 100 fields in source even if you use only 20 fields. But later when you make them as mandatory or anything, you need to regenerate the wsdl
    Regards
    Suraj

  • Exposing OIM APIs as webservice

    Hi,
    I wanted to know if i can expose OIM APIs as webservice?
    As per my reqmnt, i need to implement forgot password and change password functionality for OIM users from a portal application.
    So wanted to know if I can use OIM APIs say getChallengeValuesForSelf , compareChallengeValuesForSelf, changePasswordForSelf and then expose them as webservice?

    Can I do this...
    Create a WebService using NetBeans Editor...
    In it add a web method, which basically is using OIM API say getChallengeValuesForUser to fetch some value and then returning it as output of this web method?
    I'll be setting all the system properties required for calling OIM API here itself and also would make the connection to OIM here.
    I tried doing so, but getting an exception while I try to deploy the webservice,
    com.sun.xml.ws.model.RuntimeModelerException: The web service defined by the class weblogic.wsee.async.AsyncResponseBeanSoap12 does not contain any valid WebMethods.
    Kindly suggest.

  • Can I expose existing java applications as webservices

    I have some java based applications doing functions such as datamining, visualization ... Can I expose these as webservices? How to do that? Can I directly expose it as webservices? What tools should I use? Please explain.
    Thanks

    basically, if you have a java application doing stuff, you can create a webservice by writing JSP pages and beans and/or servlets. very simple example:
    - write a jsp page for data input that access your bean
    - write a bean that routes the request/response to/from your application classes
    all you need for doing this is a webserver and a servlet container (e.g. tomcat).
    however, if youre application is doing some graphical output, you could split your application in two: a client application for the visualization, which is communication with a servlet or a full blown J2EE server (http://java.sun.com/j2ee/tutorial/1_3-fcs/doc/WCC.html).

  • Sending Email from EJB exposed as Webservice

    Hi,
    I have created a EJB, which i have wrapped in an EAR & exposed as a WebService.
    <b>I want the code to send an email from the EJB</b>
    I know there is a code to send email, but that code is to send an email from WebDynpro. I am not sure if that will work with the EJB.
    Any ideas??
    Regards,
    Hanoz

    Hi,
    Thanx for the prompt response.
    I went through that blog. Its good, but it requires me to install additional plugins, which is dont want to do.
    Here is the code to send email from WebDynpro:
    String l_str_to = "<destination email id>";
                   String l_str_from = "sender";
                   String p_subject = "U've got mail!!! ";
    //               String p_l_request_id = "1" ;
                   // SUBSTITUTE YOUR ISP'S MAIL SERVER HERE!!!
                   String host = "<SMTP SERver ip>";
                   // Create properties, get Session
                   Properties props = new Properties();
                   // If using static Transport.send(),
                   // need to specify which host to send it to
                   props.setProperty("mail.smtp.host", host);
                   // To see what is going on behind the scene
                   //props.put("mail.debug", "true");
                   Session session = Session.getInstance(props);
                   try {
                        // Instantiatee a message
                        Message msg = new MimeMessage(session);
                        //Set message attributes
                             msg.setFrom(new InternetAddress(l_str_from));
                             InternetAddress[] address = { new InternetAddress(l_str_to)};
                             msg.setRecipients(Message.RecipientType.TO, address);
                             msg.setSubject(p_subject);
                             //msg.setSentDate(new Date());
                        java.util.Date dt = new java.util.Date();
                        msg.setSentDate(dt);
                        // Set message content
                        msg.setText("This is a test email");                         
                        //Send the message
                        Transport.send(msg);
                   catch (Exception mex)
                        // Prints all nested (chained) exceptions as well
                        mex.printStackTrace();
    <b>i want a similar code, which can be executed from the EJB!!!!</b>

  • Probelm while connecting from PI server to BAPI (exposed as webservice)

    hi friends
    i exposed BAPI as webservice in R/3 system .
    when i am trying to test from tcode wsadmin with
    "http://10.136.148.36:8002/wsnavigator/jsps/explorer.jsp?description=WebServiceZZBAPI_USER_GET_DETAIL&name=ZZBAPI_USER_GET_DETAIL&wsdl=http%3A%2F%2Finst50053318.BLR4.SAP.CORP%3A8002%2Fsap%2Fbc%2Fsrt%2Frfc%2Fsap%2FZZBAPI_USER_GET_DETAIL%3Fsap-client%3D001%26wsdl%3D1.1"
    its giving reponse when i test it.
    if directly opens with Internet Explorer through the following link
    "http://inst50053318.blr4.sap.corp:8002/sap/bc/srt/rfc/sap/ZZBAPI_USER_GET_DETAIL?sap-client=001" its showing HTTP 500 - Internal server error in R/3 system.
    in PI SERVER  i am trying to call this webservice using SOAP adapter with scenario HTTP->SOAP.
    i configured the soap adapter using URL "http://inst50053318.blr4.sap.corp:8002/sap/bc/srt/rfc/sap/ZZBAPI_USER_GET_DETAIL?sap-client=001&wsdl=1.1".
    nw its giving the respose like " HTTP 500 TIMED OUT ERROR" as wellas showing Application server error".
    please suggest me with ur valuable inputs
    thanks & regards
    Ravi

    HI,
    Have u maintained the 4 RFC destination and run the SLDCHECK transaction on XI.
    DO let me know the result of SLDCHECK.
    AI_RUNTIME_JCOSERVER
    Points from the Integration Server to the mapping runtime. The program ID corresponds to the entry under JCo RFC provider for the J2EE Engine (used for the mapping runtime, value mapping, and the exchange profile).
    AI_DIRECTORY_JCOSERVER
    Points from the Integration Server to the Integration Builder. The program ID corresponds to the entry under JCo RFC provider for the J2EE Engine (used to refresh the runtime cache).
    LCRSAPRFC
    The RFC destination LCRSAPRFC is required for the connection to the System Landscape Directory (SLD). It is used to read the exchange profile.
    SAPSLDAPI
    The RFC destination SAPSLDAPI is required for the connection to the SLD. It is used by the ABAP API.
    INTEGRATION_DIRECTORY_HMI
    For Cache Updates
    Ur HTTP time out problem is repsolved or still u r facing it.
    Thnx
    Chirag

  • While Consuming a WebService in JSP Dyn Page - There is an Error

    Hi Friends,
    I have a web service created in ASP.NET web Service.
    And I have Consumed the Web Service using WSDL URL.
    I need to write a code to refer that class in the JSP DynPage
    I have created like this in DoIntialization
    MyServiceName obj=(MyServiceName) PortalRuntime.getRuntimeResources().getService(MyServiceName.KEY);
    int a = 10;
    int b = 20;
    obj.Add1(a,b);
    but it shows an error
    "The method Add1 Method(Add1 Method) is the type. MySErviceName is not Applicable for the arguements(int,int)"
    Please Help me in this regard.
    Thanks in Advance
    Thanks & Regards,
    Palani

    Hi Andy,
    I will let u know the sequence which i followed to consume the Webservice.
    NWDS --> File --> New --> Project --> Portal Application --> Create New Portal App Project.
    The Project is created.....
    After that i want to consume the Webservice for the same project...
    for that...
    NWDS --> File --> New --> Other --> Portal Application --> Create New Portal Application Object --> Selecting My Project?(intended prjct) --> Portal Webservice --> Portal Service from WSDL file - Client Side --> My WSDL URL --> Selecting the methods which i need to expose from the Webservice --> I gave unique name for my 1) Service 2) Alias 3) Package....and that was done....(other way is to add from portalapp.xml ??)
    After that i created a new JSPDyn page for my application in DoInitialization() method i tried to access the method from that webservice using the following code...
    MyServiceName obj=(MyServiceName) PortalRuntime.getRuntimeResources().getService(MyServiceName.KEY);
    I am successfully able to access the method from the webservice using the object which i have created but i am not able to pass arguments to that method...???
    I tried consuming same webservice created in .NET in .NET itself and i am able to pass arguments successfully.
    I tried to consume webservice created in ABAP in .NET and able to implement successfully...
    but the same ABAP webservice when  i tried to consume its not working with this NWDS.
    Is there any thing else i need to follow while consuming a webservice in the EP Perspectice of NWDS ???
    Deployable Proxy is required for that ?? if required how to create and use that ??
    Thanks in Advance,
    Palani

  • Error while generating webservices using Date

    I am facing the following problem while generating a web service which is having Date as one its members.
    I have serialized a class with the following DataStructure
    private String rowId1;
    private Date created;
    private String name;
    private String quoteNum;
    private String revNum;
    private String curcyCd;
    private String activeFlg;
    private Number discntAmt;
    private Number discntPercent;
    When i tried to expose this as webservice, If I use the class oracle.jbo.domain.Date for Date type, the webservice is not generated properly. It is not including the method which contains this call. ie) This method is not present in the WSDL file as well as in the proxy.
    When I used java.util.Date instead of oracle.jbo.domain.Date, I am able to expose the method and webservice got generated properly. But When i tried to generate the proxy for the WSDL in the consumer, I go the following error.
    oracle.jdeveloper.webservices.model.GenerationException: Proxy generation failed for the following reason:
         at oracle.jdeveloper.webservices.model.proxy.ProxyGenerator.doGeneration(ProxyGenerator.java:608)
         at oracle.jdeveloper.webservices.model.proxy.ProxyGenerator.generateImpl(ProxyGenerator.java:365)
         at oracle.jdeveloper.webservices.model.proxy.ProxyGenerator.mav$generateImpl(ProxyGenerator.java:77)
         at oracle.jdeveloper.webservices.model.proxy.ProxyGenerator$1ThrowingRunnable.run(ProxyGenerator.java:206)
         at oracle.jdeveloper.webservices.model.GeneratorUI$GeneratorAction.run(GeneratorUI.java:446)
         at oracle.ide.dialogs.ProgressBar.run(ProgressBar.java:551)
         at java.lang.Thread.run(Thread.java:595)
    Caused by: java.lang.RuntimeException: generator error: no encoder for type "{http://www.w3.org/2001/XMLSchema}dateTime" and Java type "java.lang.String"
         at oracle.j2ee.ws.common.processor.Processor.runActions(Processor.java:105)
         at oracle.j2ee.ws.tools.wsa.AssemblerTool.run(AssemblerTool.java:99)
         at oracle.j2ee.ws.tools.wsa.WsdlToJavaTool.createProxy(WsdlToJavaTool.java:354)
         at oracle.j2ee.ws.tools.wsa.Util.createProxy(Util.java:838)
         at oracle.jdeveloper.webservices.model.proxy.ProxyGenerator.doGeneration(ProxyGenerator.java:549)
         ... 6 more
    Caused by: generator error: no encoder for type "{http://www.w3.org/2001/XMLSchema}dateTime" and Java type "java.lang.String"
         at oracle.j2ee.ws.common.processor.generator.GeneratorBase.doGeneration(GeneratorBase.java:181)
         at oracle.j2ee.ws.common.processor.generator.GeneratorBase.perform(GeneratorBase.java:137)
         at oracle.j2ee.ws.common.processor.Processor.runActions(Processor.java:97)
         ... 10 more
    I am referring to "Entity and view objects based on web service " in the following URL
    http://radio.weblogs.com/0118231/stories/2004/09/23/notYetDocumentedAdfSampleApplications.html#93
    Thanks and Regards,
    James

    Hi all,
    I have applied the consolidated JRI fixes - patch 17191279 .
    Then, when generating Jar, received keypass is tampered error.
    re-generated the key using $ adjkey -initialize.
    Now, its working fine.
    Regards,
    Krish.

  • Error after import external webservice(RFC) wsdl url to Process Composer

    Hi all,
    I try to use RFC webservice in my BPM as below:
    1. Expose RFC as webservice using CAF (import external service RFC and then create application service use this external service)
    2. Define Destination in NWA.
    3. Create a Process Composer project, and import the external webservice(RFC) wsdl file as service interface in the project.
    After importing, i get error : the port type specified for the ...binding is undefined. Check port type name and ensure it is defined.
    If i import another external service, not RFC (such as business object), there is no error.
    My system is NWCE 7.11
    Thanks in advance,
    Sinh.
    Edited by: Sinh Nguyen Van on Jul 20, 2009 8:29 AM

    Hi Bharath,
    Below is content of wsdl url and error message, thanks
    Error message:
    The 'zfm_rfc_caf_as' port type specified for the 'zfm_rfc_caf_asBinding' binding is undefined. Check the 'zfm_rfc_caf_as' port type name and ensure it is defined.
    wsdl url :
    - <definitions xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://www.sap.com/caf/demo.sap.com/s00_caf_rfc/modeled/zfm_rfc_caf_as" xmlns:b0="http://www.sap.com/caf/demo.sap.com/s00_caf_rfc/modeled/zfm_rfc_caf_as">
      <import namespace="http://www.sap.com/caf/demo.sap.com/s00_caf_rfc/modeled/zfm_rfc_caf_as" location="http://sinhnv-lap:50000/zfm_rfc_caf_as/zfm_rfc_caf_asBeanImpl?wsdl=binding&mode=ws_policy" />
    - <service name="zfm_rfc_caf_as">
    - <port name="zfm_rfc_caf_asBindingPort" binding="b0:zfm_rfc_caf_asBinding">
      <address xmlns="http://schemas.xmlsoap.org/wsdl/soap/" location="http://sinhnv-lap:50000/zfm_rfc_caf_as/zfm_rfc_caf_asBeanImpl" />
      </port>
      </service>
      </definitions>
    Edited by: Sinh Nguyen Van on Jul 22, 2009 4:18 AM

Maybe you are looking for