WO2003073309A1 - Web services programming and deployment - Google Patents

Web services programming and deployment Download PDF

Info

Publication number
WO2003073309A1
WO2003073309A1 PCT/US2003/005077 US0305077W WO03073309A1 WO 2003073309 A1 WO2003073309 A1 WO 2003073309A1 US 0305077 W US0305077 W US 0305077W WO 03073309 A1 WO03073309 A1 WO 03073309A1
Authority
WO
WIPO (PCT)
Prior art keywords
web service
backend component
message
java
implementing
Prior art date
Application number
PCT/US2003/005077
Other languages
French (fr)
Inventor
Todd Karakashian
Original Assignee
Bea Systems, Inc.
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Priority claimed from US10/366,246 external-priority patent/US7693955B2/en
Application filed by Bea Systems, Inc. filed Critical Bea Systems, Inc.
Priority to AU2003217598A priority Critical patent/AU2003217598A1/en
Publication of WO2003073309A1 publication Critical patent/WO2003073309A1/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/34Network arrangements or protocols for supporting network services or applications involving the movement of software or configuration parameters 
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/75Indicating network or usage conditions on the user display
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/30Definitions, standards or architectural aspects of layered protocol stacks
    • H04L69/32Architecture of open systems interconnection [OSI] 7-layer type protocol stacks, e.g. the interfaces between the data link level and the physical level
    • H04L69/322Intralayer communication protocols among peer entities or protocol data unit [PDU] definitions
    • H04L69/329Intralayer communication protocols among peer entities or protocol data unit [PDU] definitions in the application layer [OSI layer 7]

Definitions

  • the present invention relates to the implementation of Web services.
  • Web services are becoming an integral part of many application servers, with an importance that can rival HTTP or RMI stacks.
  • Java standards for Web Services are being developed through the Java Community Process. Presently, there is no complete and easy to use model for developing and deploying Web services. Further, when developing Web services, it is necessary for the developer to fully understand the complicated Web Service Definition Language (WSDL). The need to learn yet another complicated language is undesirable to many developers.
  • WSDL Web Service Definition Language
  • a backend component such as an Enterprise JavaBean or Java class is used to implement a Web service.
  • the operation of the Web service is mapped to methods of the backend component.
  • An interceptor provides access to SOAP contents of a Web service invocation message.
  • the interceptor can read the Web service invocation message and pass the contents of the message to the backend component.
  • the interceptor can receive response data back from the backend component and write SOAP contents to a Web service response message. This response message can be sent to the client invoking the Web service.
  • a codec such as a serializer or deserializer, can be used to convert data in the Web service invocation message and invocation response message between XML representations and Java objects for use with the backend component.
  • a JMS connection factory can be utilized for using JMS with the Web service.
  • An autotype method can generate custom codecs for custom data conversion.
  • Figure 1 is a diagram of a system in accordance with one embodiment of the present invention.
  • Figure 2 is flowchart for a method that can be used with the system of Figure 1.
  • Web service runtime can be used to generate any WSDL description that might be needed by remote clients in order to access the Web service. This approach can be suitable to developers who may be familiar with Java and J2EE, but do not wish to immerse themselves in the complicated WSDL specification.
  • An Web service runtime in accordance with one embodiment of the present invention may not support an implementation of Web services that must conform to a fixed WSDL description, although other embodiments may support these implementations.
  • a Web service can be implemented using certain types of components. Some of these components are shown in Figure 1 , a diagram of a Web service container 134 that can be used to implement Web services.
  • the HTTP protocol adapter 102 of the Web container 100 is shown passing message context to, and receiving message context from, a container driver 104.
  • the container driver 104 receives the message context from the protocol adapter 102 and sends the message context to the registered inbound interceptors 106, 108, 110.
  • the container driver 104 After extracting the operation parameters and performing any necessary data binding, such as by using a Java Binding codec 126, a SOAP codec 128, an XML codec 130, or a custom codec 132, the container driver 104 submits the operation request to the appropriate invocation handler 112, such as for EJB 114 or JMS 116, or to a customized invocation handler 118. After receiving data back from the invocation handler 112, the container driver 104 can perform any data unbinding using the appropriate codecs 126, 128, 130, 132 and send the response to the outbound interceptors 106, 108, 110. The container driver 104 can then return the response to the protocol adapter 102.
  • the appropriate invocation handler 112 such as for EJB 114 or JMS 116
  • the container driver 104 can perform any data unbinding using the appropriate codecs 126, 128, 130, 132 and send the response to the outbound interceptors 106, 108, 110.
  • the protocol adapter, interceptors, and invocation handler can each have access to an invocation context object 120
  • the invocation handler 112 can also provide context access to the component 122 to which it delegates, which can be contained in a component container 124.
  • Backend J2EE components such as Enterprise JavaBeans (EJBs) can be used as a component 122 for the invocation handler 112, as well as for interceptor components 106, 108, 110.
  • a specific interceptor that can be used referred to as a flow handler, can provide access to SOAP messages.
  • the codecs 126, 128, 130, 132 also referred to as serializers or deserializers, can be used to convert data between XML representation and Java objects.
  • a Web service can be mapped to methods of these backend J2EE components.
  • a single Web service can be implemented in terms of multiple backend components, with each operation being associated with a particular backend component.
  • Web service operation invocations can be sent that are encoded in SOAP messages.
  • the parameters can be mapped between Java data types and XML using serializer and deserializer classes, or codecs.
  • An Web service runtime can contain a set of hardwired codecs to support built-in data types in the SOAP specification. If non-built-in data types are needed, the runtime can require that codecs be provided by the application.
  • An application can include tool support for generating codecs by introspecting the data types used in many types of EJBs. Such support can be implemented through an autotype method, and referred to as an Autotyper.
  • An application may need access to the SOAP contents of an invocation message.
  • a user can write an interceptor referred to as a "flow handler".
  • Registered flow handlers can be called prior to, and immediately after, the invoke of a backend component.
  • a flow handler implementation can receive access to the
  • SOAP request and response can read or write accordingly.
  • Multiple flow handlers can be chained together.
  • the developer of a Web service in accordance with one embodment of the present invention can perform the following steps to build and deploy a Web service.
  • Command-line tools can be provided.
  • Ant tasks can facilitate the use of these tools.
  • a master service generation task, such as "ServiceGen”, can perform all these steps using one task.
  • FIG. 2 A method that can be used to build and deploy a Web service in accordance with one embodiment of the present invention is shown in Figure 2.
  • the method includes first developing the backend implementation components 200.
  • EJB components and their dependent classes can be packaged in ejb-jars. If JMS is used, JMS destinations and connection factories can be configured in a configuration file such as config.xml.
  • Data types can then be implemented, if necessary 202. If data types other than built-in data types are desired, serializers and deserializers can be developed for these custom types. This can be accomplished through an Autotyper Ant task, or can be done manually.
  • SOAP message processing can also be implemented 204. If an application needs to process information from SOAP headers in a request or response, or in other parts of the SOAP message not encoded into the backend component parameters, a SOAP interceptor called a flow handler can be developed. A Web service deployment descriptor can be edited using the flow handler 206.
  • a Web service home page can be generated that describes the deployed Web service, provides a link to the WSDL downloadable client, and provides a simple GUI for testing the Web service 208. This can be accomplished using a page generation Ant task.
  • a Java client jar can be generated to contain a thin Java client 210.
  • the thin Java client can be downloaded by a client and used to invoke a Web Service, such as from a JDK 1.3 Virtual Machine. This can be accomplished using a client generation Ant task.
  • a Web service EAR can be packaged and deployed on the application server 212.
  • a service generation master task can be used to perform many of these steps using task configuration parameters. This can be useful for simple Web services. More complex Web services may require more specific tasks, or at least manual configuration and packaging.
  • Backend components that can be used to implement a Web service can include stateless EJBs, JMS message consumers/producers, and Java classes. JMS message consumers and producers may not have methods that can be directly associated with operations. Therefore, an object-like pseudo-interface to JMS destinations can be defined. This interface can include 'send' and 'receive' methods for sending and receiving messages from a Web service to a JMS destination. The payload of these messages can be any data type supported by a Web service runtime. While in principle any JMS message consumer can implement a JMS backend component, a message-driven bean may be preferable for some embodiments.
  • Java types can be mapped directly to SOAP specified types. The conversion of these Java types can be handled natively by the Web service runtime. These Java types do not require the application to specify an XML representation, nor do they require any serializers or deserializers. These Java types are defined in JAX-RPC:
  • an Autotyper Ant task can be provided that can generate Java or XML representations, serializer/deserializer classes, and type mappings for most data types used in applications.
  • a command-line version of the Ant task can also be used.
  • An autotyping task can ensure that for every complex type, the following is available: - XML representation of the types (in XML Schema notation)
  • - Java mode start with Java representation of types and generate an XML Schema representation plus serialization classes and type mappings. Typically Java mode is used when implementing a Web service.
  • - XML mode start with an XML representation, such as from a WSDL service description, and generate a Java. representation plus serialization classes and type mappings.
  • XML mode can be used when implementing client access to a remote Web service for which there is a WSDL description.
  • Table 1 shows possible autotype task parameters.
  • An example of an autotype task parameter for Java is as follows:
  • the above example generates typing information for non-built-in data types in EJB interfaces in all ejbs in myejb.jar, and writes the serializers and deployment descriptors into myWebservice.war. If there is a deployment descriptor in myWebservice.war, it is overwritten.
  • the application data types may be too complex for an autotyper to understand.
  • the application developer may wish to have control over the parts of a Java class that are serialized, as well as control over how it will be done. Under these circumstances, a developer can choose to implement custom types manually. To do this, the developer can: - Write an XML Schema definition of the XML representation of that type.
  • a Web service can consist of the backend components and possibly some custom data types.
  • This model can ensure the separation of the business logic of the application, encapsulated in the backend components and types, from the details of the messaging infrastructure (i.e., SOAP, HTTP).
  • SOAP the messaging infrastructure
  • a handler can be provided that is a type of interceptor. Handlers can provide complete access to the SOAP and HTTP requests and responses. They can be invoked in the sequence of processing a SOAP message.
  • a handler can implement a Web service handler interface.
  • the handler can read or write the SOAP request or response.
  • the handler can also access information about the request processing, such as may include error status and MIME headers.
  • Flow handlers can be registered in the deployment descriptor as part of a flow.
  • the flow can consist of a series of inbound flow handlers, followed by an invoke of a backend component, followed by outbound flow handlers.
  • An additional capability that can be utilized is the ability to automatically generate a Web service "home page". This is a Web page that can be deployed along with the Web service, which can allow a browser client to: - access the service WSDL
  • the home page can be generated automatically when the service endpoint URL is dereferenced by a browser.
  • the output can be computed based on the content of the deployment descriptor and the interfaces of the backend components.
  • a thin client can be provided for accessing a Web service from a
  • Java Virtual Machine such as a JDK 1.3 virtual machine.
  • a complete thin client for a Web service can consist of two jars: a client runtime jar and a service-specific jar.
  • a client runtime jar can be independent of any specific Web service. This jar can contain those classes needed to support the client side of a Web service runtime. The contents of this jar can be included in Weblogic.jar, so clients that are server components do not need to include this jar in order to access remote Web services.
  • a service-specific client jar can be specific to a particular Web service. This jar can be generated by a client generation ant task. This jar can be required for static API access to a remote Web service, regardless of whether the client is a server-side component or in a standalone Java virtual machine. Task parameters for a client generation ant task are shown in Table 2.
  • the above example creates a session-client.jar which contains stubs for statically invoking the first service in session.war.
  • the above example creates a client jar for the services which are described in CATrafficService.wsdl.
  • the client interfaces and stubs are generated in the test.traffic package and put into the jar file traffic.jar.
  • a deployable Web service can be contained solely in an EAR file with components such as EJB jars containing the EJB implementation of the Web services.
  • Other components can include Web service WAR files containing the Web service configuration, typing resources, and entry point.
  • a Web service WAR is a Web archive file, which can include a Web service deployment descriptor in Web-INF/Web-services.xml.
  • the WAR can also include serializers and deserializers that support non- built-in data types.
  • the compiled Java classes can be written into Web- INF/classes.
  • the WAR can also include a service home page JSP.
  • Ant tasks can include a built-in EAR task to facilitate building EAR files.
  • Table 3 shows a summary of an EAR file structure.
  • - ⁇ service_name> is the service name as defined in the ⁇ Web- service> element of the deployment descriptor.
  • - ⁇ Webservices.war> is the name of the WAR file directory containing the Web services
  • a Web service WAR does not have to contain a Web.xml deployment descriptor, although it may include one if regular Web- applications are to be configured to go along with the Web service. There can also be multiple Webservice WARs and EJB-JARs in an EAR.
  • a single master Ant task can be supported to perform the steps needed to develop a Web service in an automated fashion. This task can be useful for Web services which are very run-of-the-mill, with few specific options needing to be set.
  • a service generation Ant task such as "servicegen” can be the master task used to build Web services for deployment. Parameters that can be useful with a service generation Ant task are shown in Table 4.
  • a service element can be used to build a Web service from ejb-jars or Java classes.
  • the EJBs or classes can be introspected, deployment descriptors constructed, and automatic typing performed.
  • a home page and client can be generated. Parameters that can be useful with a service Ant task are shown in Table 5.
  • a client element can be specified in service. If the client element is specified, a client jar can be generated and put into the EAR. This client jar en be accessible from the service home page so that it can be downloaded by remote clients. This element can be used to specify parameters for the generation of the client. Table 6 shows possible types for a client element.
  • descriptor sgen task to facilitate migrating EJBs peployable )etween versions of Web EAR services autotype Generate default typing for EJB-JARs or Deployment complex types in the service classnames descriptor mplementation optional: WAR serializer classes lientgen Generate a client jar and sample code to invoke a Web service

Abstract

A Web service (134) can be deployed using a backend component (122) such as an Enterprise JavaBean (114) or Java class (118). The operation of the Web service can be mapped to methods of the backend component (112). An interceptor (106, 108, 110) can provide access to SOAP (128) contents of a Web service (134) invocation message (120), passing contents to and from the backend component (122). The interceptor (106, 108, 110) writes response data received from the backend component (122) to a Web service response message, which can be sent to the client invoking the Web service (134). A codec (132), such as a serializer or deserializer, can be used to convert data in the Web service invocation message (120) and invocation response message between XML (130) representations and Java (126) objects for use with the backend component (122). This description is not intended to be a complete description of, or limit the scope of, the invention. Other features, aspects, and objects of the invention can be obtained from a review of the specification, the figures, and the claims.

Description

WEB SERVICES PROGRAMMING AND DEPLOYMENT
CLAIM OF PRIORITY This application claims priority to U.S. Provisional Patent Application No. 60/359,098, filed February 22, 2002, entitled "WEB SERVICES RUNTIME ARCHITECTURE," as well as U.S. Provisional Patent Application No. 60/359,231 , filed February 22, 2002, entitled "WEB SERVICES PROGRAMMING AND DEPLOYMENT," each of which is hereby incorporated herein by reference.
COPYRIGHT NOTICE A portion of the disclosure of this patent document contains material which is subject to copyright protection. The copyright owner has no objection to the facsimile reproduction by anyone of the patent document of the patent disclosure, as it appears in the Patent and Trademark Office patent file or records, but otherwise reserves all copyright rights whatsoever.
FIELD OF THE INVENTION The present invention relates to the implementation of Web services.
BACKGROUND
Web services are becoming an integral part of many application servers, with an importance that can rival HTTP or RMI stacks. Java standards for Web Services are being developed through the Java Community Process. Presently, there is no complete and easy to use model for developing and deploying Web services. Further, when developing Web services, it is necessary for the developer to fully understand the complicated Web Service Definition Language (WSDL). The need to learn yet another complicated language is undesirable to many developers.
BRIEF SUMMARY Systems and methods in accordance with one embodiment of the present invention can overcome deficiencies in present approaches to developing and deploying a Web service. A backend component such as an Enterprise JavaBean or Java class is used to implement a Web service. The operation of the Web service is mapped to methods of the backend component.
An interceptor provides access to SOAP contents of a Web service invocation message. The interceptor can read the Web service invocation message and pass the contents of the message to the backend component. The interceptor can receive response data back from the backend component and write SOAP contents to a Web service response message. This response message can be sent to the client invoking the Web service.
A codec, such as a serializer or deserializer, can be used to convert data in the Web service invocation message and invocation response message between XML representations and Java objects for use with the backend component. A JMS connection factory can be utilized for using JMS with the Web service. An autotype method can generate custom codecs for custom data conversion.
Other features, aspects, and objects of the invention can be obtained from a review of the specification, the figures, and the claims.
BRIEF DESCRIPTION OF THE DRAWINGS Figure 1 is a diagram of a system in accordance with one embodiment of the present invention. Figure 2 is flowchart for a method that can be used with the system of Figure 1.
DETAILED DESCRIPTION Systems and methods for deploying a Web service in accordance with one embodiment of the present invention follow an "export from Java" model. Using such a model, a Web service developer can create Java interfaces and components without needing to know the Web Service Definition Language (WSDL). An Web service runtime can be used to generate any WSDL description that might be needed by remote clients in order to access the Web service. This approach can be suitable to developers who may be familiar with Java and J2EE, but do not wish to immerse themselves in the complicated WSDL specification. An Web service runtime in accordance with one embodiment of the present invention may not support an implementation of Web services that must conform to a fixed WSDL description, although other embodiments may support these implementations. A service developer understand WSDL, but such understanding is not required. Support for an "import from WSDL" model can also be supported. Tools, such as may be developed by third parties, can be used to introspect WSDL and generate a template "export from Java" implementation that closely conforms to the input WSDL.
A Web service can be implemented using certain types of components. Some of these components are shown in Figure 1 , a diagram of a Web service container 134 that can be used to implement Web services. The HTTP protocol adapter 102 of the Web container 100 is shown passing message context to, and receiving message context from, a container driver 104. The container driver 104 receives the message context from the protocol adapter 102 and sends the message context to the registered inbound interceptors 106, 108, 110. After extracting the operation parameters and performing any necessary data binding, such as by using a Java Binding codec 126, a SOAP codec 128, an XML codec 130, or a custom codec 132, the container driver 104 submits the operation request to the appropriate invocation handler 112, such as for EJB 114 or JMS 116, or to a customized invocation handler 118. After receiving data back from the invocation handler 112, the container driver 104 can perform any data unbinding using the appropriate codecs 126, 128, 130, 132 and send the response to the outbound interceptors 106, 108, 110. The container driver 104 can then return the response to the protocol adapter 102. The protocol adapter, interceptors, and invocation handler can each have access to an invocation context object 120 The invocation handler 112 can also provide context access to the component 122 to which it delegates, which can be contained in a component container 124. Backend J2EE components such as Enterprise JavaBeans (EJBs) can be used as a component 122 for the invocation handler 112, as well as for interceptor components 106, 108, 110. A specific interceptor that can be used, referred to as a flow handler, can provide access to SOAP messages. The codecs 126, 128, 130, 132, also referred to as serializers or deserializers, can be used to convert data between XML representation and Java objects.
The operations of a Web service can be mapped to methods of these backend J2EE components. A single Web service can be implemented in terms of multiple backend components, with each operation being associated with a particular backend component.
Web service operation invocations can be sent that are encoded in SOAP messages. The parameters can be mapped between Java data types and XML using serializer and deserializer classes, or codecs. An Web service runtime can contain a set of hardwired codecs to support built-in data types in the SOAP specification. If non-built-in data types are needed, the runtime can require that codecs be provided by the application. An application can include tool support for generating codecs by introspecting the data types used in many types of EJBs. Such support can be implemented through an autotype method, and referred to as an Autotyper.
Sometimes an application may need access to the SOAP contents of an invocation message. In this case, a user can write an interceptor referred to as a "flow handler". Registered flow handlers can be called prior to, and immediately after, the invoke of a backend component. A flow handler implementation can receive access to the
SOAP request and response, and can read or write accordingly. Multiple flow handlers can be chained together.
The developer of a Web service in accordance with one embodment of the present invention can perform the following steps to build and deploy a Web service. Command-line tools can be provided. Ant tasks can facilitate the use of these tools. A master service generation task, such as "ServiceGen", can perform all these steps using one task.
A method that can be used to build and deploy a Web service in accordance with one embodiment of the present invention is shown in Figure 2. The method includes first developing the backend implementation components 200. EJB components and their dependent classes can be packaged in ejb-jars. If JMS is used, JMS destinations and connection factories can be configured in a configuration file such as config.xml.
Data types can then be implemented, if necessary 202. If data types other than built-in data types are desired, serializers and deserializers can be developed for these custom types. This can be accomplished through an Autotyper Ant task, or can be done manually. SOAP message processing can also be implemented 204. If an application needs to process information from SOAP headers in a request or response, or in other parts of the SOAP message not encoded into the backend component parameters, a SOAP interceptor called a flow handler can be developed. A Web service deployment descriptor can be edited using the flow handler 206.
A Web service home page can be generated that describes the deployed Web service, provides a link to the WSDL downloadable client, and provides a simple GUI for testing the Web service 208. This can be accomplished using a page generation Ant task.
A Java client jar can be generated to contain a thin Java client 210. The thin Java client can be downloaded by a client and used to invoke a Web Service, such as from a JDK 1.3 Virtual Machine. This can be accomplished using a client generation Ant task. A Web service EAR can be packaged and deployed on the application server 212.
A service generation master task can be used to perform many of these steps using task configuration parameters. This can be useful for simple Web services. More complex Web services may require more specific tasks, or at least manual configuration and packaging. Backend components that can be used to implement a Web service can include stateless EJBs, JMS message consumers/producers, and Java classes. JMS message consumers and producers may not have methods that can be directly associated with operations. Therefore, an object-like pseudo-interface to JMS destinations can be defined. This interface can include 'send' and 'receive' methods for sending and receiving messages from a Web service to a JMS destination. The payload of these messages can be any data type supported by a Web service runtime. While in principle any JMS message consumer can implement a JMS backend component, a message-driven bean may be preferable for some embodiments.
Certain Java types can be mapped directly to SOAP specified types. The conversion of these Java types can be handled natively by the Web service runtime. These Java types do not require the application to specify an XML representation, nor do they require any serializers or deserializers. These Java types are defined in JAX-RPC:
- primitive types: boolean, byte, short, int, long, float, double
- primitive wrapper classes in java.lang: Boolean, Byte, Short, Integer, Long, Float, Double
- java.lang. String
- Java. util. Date
- Java. util. Calendar
- Java. math. Biglnteger - Java. math. BigDecimal
- Arrays of these
Applications can use data types other than those that are built-in. To avoid the need for manually defining serializers and XML schemas for every non-built-in type, an Autotyper Ant task can be provided that can generate Java or XML representations, serializer/deserializer classes, and type mappings for most data types used in applications. A command-line version of the Ant task can also be used.
An autotyping task can ensure that for every complex type, the following is available: - XML representation of the types (in XML Schema notation)
- Java representation of the types
- Serializer/Deserializer classes to convert between Java and
XML representations
- Type mappings to associate the XML and Java types with the appropriate serializer/deserializer classes.
There can be two modes for an Autotype Ant task, which can differ in the input they accept. These modes can include:
- Java mode: start with Java representation of types and generate an XML Schema representation plus serialization classes and type mappings. Typically Java mode is used when implementing a Web service. - XML mode: start with an XML representation, such as from a WSDL service description, and generate a Java. representation plus serialization classes and type mappings. XML mode can be used when implementing client access to a remote Web service for which there is a WSDL description. Table 1 shows possible autotype task parameters. Table 1: Autotype task parameters
Figure imgf000010_0001
Figure imgf000011_0001
An example of an autotype task parameter for Java is as follows:
<autotype ejbJar-'myejb.jar" destWar- 'myWebservice.war" overwrite="True"
/>
The above example generates typing information for non-built-in data types in EJB interfaces in all ejbs in myejb.jar, and writes the serializers and deployment descriptors into myWebservice.war. If there is a deployment descriptor in myWebservice.war, it is overwritten.
<autotype JavaClasses="test.MyService,test.MyOtherService" destWar- 'myWebservice.war" overwrite-True" />
The above example generates typing information for the two classes, test.MyService and test.MyOtherService. If there is a deployment descriptor in myWebservice.war, it is overwritten.
In some cases, the application data types may be too complex for an autotyper to understand. In other situations, the application developer may wish to have control over the parts of a Java class that are serialized, as well as control over how it will be done. Under these circumstances, a developer can choose to implement custom types manually. To do this, the developer can: - Write an XML Schema definition of the XML representation of that type.
- Write a Java class that represents the type in Java.
- Write a serializer class that implements the interface
Webservice.core.encoding.soap.SOAPSerializer. - Write a deserializer class that implements the interface
Webservice.core.encoding.soap.SOAPDeserializer.
- Enter the type information into the deployment descriptor: the
XML Schema definition under the <xml-type-defs> element; the Java class type definition and the serializer, deserializer class names under the <type-mapping> element. Apply the type mappings to operations of the Web service using the <operation> and/or <operation-set> elements.
An Autotyper can perform these steps automatically. Therefore, another entirely valid approach to developing custom types is to run the Autotyper and then customize the resulting generated schemas and classes.
Under normal circumstances, the implementation of a Web service can consist of the backend components and possibly some custom data types. This model can ensure the separation of the business logic of the application, encapsulated in the backend components and types, from the details of the messaging infrastructure (i.e., SOAP, HTTP). There can be some applications, however, that may need to access to the message level, such as to read or write SOAP headers. To support these applications, a handler can be provided that is a type of interceptor. Handlers can provide complete access to the SOAP and HTTP requests and responses. They can be invoked in the sequence of processing a SOAP message.
A handler can implement a Web service handler interface. The handler can read or write the SOAP request or response. The handler can also access information about the request processing, such as may include error status and MIME headers.
Flow handlers can be registered in the deployment descriptor as part of a flow. The flow can consist of a series of inbound flow handlers, followed by an invoke of a backend component, followed by outbound flow handlers.
An additional capability that can be utilized is the ability to automatically generate a Web service "home page". This is a Web page that can be deployed along with the Web service, which can allow a browser client to: - access the service WSDL
- download a client runtime (either SSL and non-SSL versions, depending on the protocol)
- downloadable client jar
- use a service test page
The home page can be generated automatically when the service endpoint URL is dereferenced by a browser. The output can be computed based on the content of the deployment descriptor and the interfaces of the backend components. A thin client can be provided for accessing a Web service from a
Java Virtual Machine, such as a JDK 1.3 virtual machine. A complete thin client for a Web service can consist of two jars: a client runtime jar and a service-specific jar.
A client runtime jar can be independent of any specific Web service. This jar can contain those classes needed to support the client side of a Web service runtime. The contents of this jar can be included in Weblogic.jar, so clients that are server components do not need to include this jar in order to access remote Web services.
A service-specific client jar can be specific to a particular Web service. This jar can be generated by a client generation ant task. This jar can be required for static API access to a remote Web service, regardless of whether the client is a server-side component or in a standalone Java virtual machine. Task parameters for a client generation ant task are shown in Table 2.
Table 2: client generation Ant task parameters
Figure imgf000014_0001
Figure imgf000015_0001
An example of a client generation ant task is given by the following: <clientgen ear="session.ear" warName- 'session.war" packageName- 'test" clientJar- 'session-client.jar" />
The above example creates a session-client.jar which contains stubs for statically invoking the first service in session.war.
<clientgen wsdl="http://www.xmethods.net/sd/2001/ CATrafficService.wsdl" packageName- 'test.traffic" clientJar- 'traffic.jar" />
The above example creates a client jar for the services which are described in CATrafficService.wsdl. The client interfaces and stubs are generated in the test.traffic package and put into the jar file traffic.jar.
A deployable Web service can be contained solely in an EAR file with components such as EJB jars containing the EJB implementation of the Web services. Other components can include Web service WAR files containing the Web service configuration, typing resources, and entry point.
A Web service WAR is a Web archive file, which can include a Web service deployment descriptor in Web-INF/Web-services.xml. The WAR can also include serializers and deserializers that support non- built-in data types. The compiled Java classes can be written into Web- INF/classes. The WAR can also include a service home page JSP.
Ant tasks can include a built-in EAR task to facilitate building EAR files. Table 3 shows a summary of an EAR file structure.
Table 3: EAR file structure
Figure imgf000016_0001
where
- <service_name> is the service name as defined in the <Web- service> element of the deployment descriptor. - <Webservices.war> is the name of the WAR file directory containing the Web services
- <ejb.jar> is the name of the ejb-jar directory containing the backend EJB components A Web service WAR does not have to contain a Web.xml deployment descriptor, although it may include one if regular Web- applications are to be configured to go along with the Web service. There can also be multiple Webservice WARs and EJB-JARs in an EAR.
A single master Ant task can be supported to perform the steps needed to develop a Web service in an automated fashion. This task can be useful for Web services which are very run-of-the-mill, with few specific options needing to be set. A service generation Ant task, such as "servicegen", can be the master task used to build Web services for deployment. Parameters that can be useful with a service generation Ant task are shown in Table 4.
Table 4: Service generation Ant task
Figure imgf000017_0001
Figure imgf000018_0001
A service element can be used to build a Web service from ejb-jars or Java classes. The EJBs or classes can be introspected, deployment descriptors constructed, and automatic typing performed. Optionally, a home page and client can be generated. Parameters that can be useful with a service Ant task are shown in Table 5.
Table 5: Service Ant task
Figure imgf000018_0002
Figure imgf000019_0001
Figure imgf000019_0002
A client element can be specified in service. If the client element is specified, a client jar can be generated and put into the EAR. This client jar en be accessible from the service home page so that it can be downloaded by remote clients. This element can be used to specify parameters for the generation of the client. Table 6 shows possible types for a client element.
Figure imgf000020_0001
Example:
<servicegen destEar="c:/myapps/myapp.ear"> <service ejbJar="c:/dev/myaps/myejb.jar"excludeEJBs= "badejb, awfulejb" /> Ant tasks that can be provided to support Web services are shown in the Table 7.
Table 7: Ant tasks
Task 'urpose In put Output servicegen aster task to generate a EJBs peployable deployable service. Calls optional: EAR Autotyper, HomePageGen, deployment ClientGen tasks. descriptor sgen task to facilitate migrating EJBs peployable )etween versions of Web EAR services autotype Generate default typing for EJB-JARs or Deployment complex types in the service classnames descriptor mplementation optional: WAR serializer classes lientgen Generate a client jar and sample code to invoke a Web service
The foregoing description of preferred embodiments of the present invention has been provided for the purposes of illustration and description. It is not intended to be exhaustive or to limit the invention to the precise forms disclosed. Many modifications and variations will be apparent to one of ordinary skill in the art. The embodiments were chosen and described in order to best explain the principles of the invention and its practical application, thereby enabling others skilled in the art to understand the invention for various embodiments and with various modifications that are suited to the particular use contemplated. It is intended that the scope of the invention be defined by the following claims and their equivalence.

Claims

CLAIMS What is claimed is:
1. A system for deploying a Web service, comprising: a backend component for implementing a Web service, the operation of the Web service being mapped to methods of the backend component; an interceptor for providing access to SOAP contents of a Web service invocation message, said interceptor adapted to read the Web service invocation message and pass the contents of the message to said backend component, said interceptor adapted to receive response data from the backend component and write SOAP contents to a Web service response message; and a codec for converting data in the Web service invocation message and invocation response message between XML representations and Java objects for use with said backend component.
2. A system according to claim 1 , further comprising a JMS connection factory for using JMS with the Web service.
3. A system according to claim 1 , wherein said backend component is selected from the group consisting of Enterprise JavaBeans, JMS message consumers, JMS message producers, and Java classes.
4. A system according to claim 1 , further comprising an Autotyper for generating additional codecs.
5. A system according to claim 1 , further comprising a container driver for controlling the flow of the Web service invocation message.
6. A system according to claim 1 , further comprising a Web service home page for describing the Web service.
7. A system according to claim 1 , further comprising a thin client for accessing the Web service from a Java virtual machine.
8. A method for deploying a Web service, comprising: deploying a backend component for implementing the Web service; providing access to SOAP contents of a Web service invocation message using an interceptor; and providing a codec for converting data in the Web service invocation message from an XML representation to a Java object for use with the backend component implementing the Web service.
9. A method according to claim 8, further comprising: mapping the operation of the Web service mapped to methods of the backend component.
10. A method according to claim 8, further comprising: reading the Web service invocation message with the interceptor and passing the contents of the message to the backend component.
11. A method according to claim 8, further comprising: receiving response data from the backend component and writing SOAP contents to a Web service response message using the interceptor.
12. A method according to claim 11 , further comprising: providing a codec for converting data in the Web service response message from a Java object to an XML representation.
13. A method according to claim 8, further comprising: implementing data types for the Web service.
14. A method according to claim 8, further comprising: using a SOAP message processor to process SOAP information not encoded in the backend component.
15. A method according to claim 8, further comprising: editing a Web service deployment descriptor to activate the Web service.
16. A method according to claim 8, further comprising: generating a Web service home page to describe the Web service.
17. A method according to claim 8, further comprising: generating a Java client for accessing the Web service from a Java virtual machine.
18. A method according to claim 17, further comprising: generating a client jar to contain the Java client.
19. A method according to claim 8, further comprising: packaging and deploying a Web service archive file.
20. A computer-readable medium, comprising: means for deploying a backend component for implementing the Web service; means for providing access to SOAP contents of a Web service invocation message using an interceptor; and means for providing a codec for converting data in the Web service invocation message from an XML representation to a Java object for use with the backend component implementing the Web service.
21. A computer program product for execution by a server computer for deploying a Web service, comprising: computer code for deploying a backend component for implementing the Web service; computer code for providing access to SOAP contents of a Web service invocation message using an interceptor; and computer code for providing a codec for converting data in the Web service invocation message from an XML representation to a Java object for use with the backend component implementing the Web service..
22. A system for deploying a Web service, comprising: means for deploying a backend component for implementing the Web service; means for providing access to SOAP contents of a Web service invocation message using an interceptor; and means for providing a codec for converting data in the Web service invocation message from an XML representation to a Java object for use with the backend component implementing the Web service.
23. A computer system comprising: a processor; object code executed by said processor, said object code configured to: deploy a backend component for implementing the Web service; provide access to SOAP contents of a Web service invocation message using an interceptor; and provide a codec for converting data in the Web service invocation message from an XML representation to a Java object for use with the backend component implementing the Web service.
24. A computer data signal embodied in a transmission medium, comprising: a code segment including instructions to deploy a backend component for implementing the Web service; a code segment including instructions to provide access to SOAP contents of a Web service invocation message using an interceptor; and a code segment including instructions to provide a codec for converting data in the Web service invocation message from an XML representation to a Java object for use with the backend component implementing the Web service.
PCT/US2003/005077 2002-02-22 2003-02-20 Web services programming and deployment WO2003073309A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
AU2003217598A AU2003217598A1 (en) 2002-02-22 2003-02-20 Web services programming and deployment

Applications Claiming Priority (8)

Application Number Priority Date Filing Date Title
US35909802P 2002-02-22 2002-02-22
US35923102P 2002-02-22 2002-02-22
US60/359,231 2002-02-22
US60/359,098 2002-02-22
US10/366,236 2003-02-13
US10/366,246 US7693955B2 (en) 2002-02-22 2003-02-13 System and method for deploying a web service
US10/366,236 US20040015578A1 (en) 2002-02-22 2003-02-13 Web services runtime architecture
US10/366,246 2003-02-13

Publications (1)

Publication Number Publication Date
WO2003073309A1 true WO2003073309A1 (en) 2003-09-04

Family

ID=27767923

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/US2003/005077 WO2003073309A1 (en) 2002-02-22 2003-02-20 Web services programming and deployment

Country Status (2)

Country Link
AU (2) AU2003211141A1 (en)
WO (1) WO2003073309A1 (en)

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2006106080A1 (en) * 2005-04-05 2006-10-12 International Business Machines Corporation Business context services for adaptable service oriented architecture components
CN100353713C (en) * 2005-12-26 2007-12-05 北京航空航天大学 Authentic remote service heat deploying method
WO2008095736A1 (en) * 2007-02-05 2008-08-14 Bundesdruckerei Gmbh Data processing system method for receiving personal data and computer programme product
US7698684B2 (en) 2005-09-28 2010-04-13 Sap Ag Method and system for generating schema to Java mapping descriptors and direct mapping of XML schema and Java interfaces
US7814060B2 (en) 2005-12-30 2010-10-12 Sap Ag Apparatus and method for web service client deployment
US8010695B2 (en) 2005-12-30 2011-08-30 Sap Ag Web services archive
US8024425B2 (en) 2005-12-30 2011-09-20 Sap Ag Web services deployment
US8078671B2 (en) 2005-09-21 2011-12-13 Sap Ag System and method for dynamic web services descriptor generation using templates
US8250522B2 (en) 2005-09-28 2012-08-21 Sap Ag Method and system for generating a web services meta model on the java stack
US8589518B2 (en) 2005-09-28 2013-11-19 Sap Ag Method and system for directly mapping web services interfaces and java interfaces
US8700681B2 (en) 2005-09-28 2014-04-15 Sap Ag Method and system for generating schema to java mapping descriptors
US9454616B2 (en) 2005-09-28 2016-09-27 Sap Se Method and system for unifying configuration descriptors
CN116055569A (en) * 2023-03-31 2023-05-02 浙江华东工程数字技术有限公司 Method, system, computer device and storage medium for custom switching time zone

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020178254A1 (en) * 2001-05-23 2002-11-28 International Business Machines Corporation Dynamic deployment of services in a computing network
US20030005181A1 (en) * 2001-07-02 2003-01-02 David Bau Annotation based development platform for asynchronous web services
US20030033369A1 (en) * 2001-08-09 2003-02-13 Bernhard Benjamin Karb Donovan Web services container

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020178254A1 (en) * 2001-05-23 2002-11-28 International Business Machines Corporation Dynamic deployment of services in a computing network
US20030005181A1 (en) * 2001-07-02 2003-01-02 David Bau Annotation based development platform for asynchronous web services
US20030033369A1 (en) * 2001-08-09 2003-02-13 Bernhard Benjamin Karb Donovan Web services container

Cited By (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2006106080A1 (en) * 2005-04-05 2006-10-12 International Business Machines Corporation Business context services for adaptable service oriented architecture components
US8078671B2 (en) 2005-09-21 2011-12-13 Sap Ag System and method for dynamic web services descriptor generation using templates
US8589518B2 (en) 2005-09-28 2013-11-19 Sap Ag Method and system for directly mapping web services interfaces and java interfaces
US7698684B2 (en) 2005-09-28 2010-04-13 Sap Ag Method and system for generating schema to Java mapping descriptors and direct mapping of XML schema and Java interfaces
US8250522B2 (en) 2005-09-28 2012-08-21 Sap Ag Method and system for generating a web services meta model on the java stack
US8700681B2 (en) 2005-09-28 2014-04-15 Sap Ag Method and system for generating schema to java mapping descriptors
US9141592B2 (en) 2005-09-28 2015-09-22 Sap Se Method and system for directly mapping web services interfaces and java interfaces
US9280527B2 (en) 2005-09-28 2016-03-08 Sap Se Method and system for directly mapping web services interfaces and Java interfaces
US9454616B2 (en) 2005-09-28 2016-09-27 Sap Se Method and system for unifying configuration descriptors
CN100353713C (en) * 2005-12-26 2007-12-05 北京航空航天大学 Authentic remote service heat deploying method
US7814060B2 (en) 2005-12-30 2010-10-12 Sap Ag Apparatus and method for web service client deployment
US8010695B2 (en) 2005-12-30 2011-08-30 Sap Ag Web services archive
US8024425B2 (en) 2005-12-30 2011-09-20 Sap Ag Web services deployment
WO2008095736A1 (en) * 2007-02-05 2008-08-14 Bundesdruckerei Gmbh Data processing system method for receiving personal data and computer programme product
CN116055569A (en) * 2023-03-31 2023-05-02 浙江华东工程数字技术有限公司 Method, system, computer device and storage medium for custom switching time zone

Also Published As

Publication number Publication date
AU2003217598A1 (en) 2003-09-09
AU2003211141A1 (en) 2003-09-09

Similar Documents

Publication Publication Date Title
US7693955B2 (en) System and method for deploying a web service
US7769825B2 (en) System and method for web services Java API-based invocation
US7565443B2 (en) Common persistence layer
JP5160553B2 (en) Aggregation of portlets used in the client environment without depending on server resources
US7000238B2 (en) Development system providing extensible remoting architecture
JP4594621B2 (en) Supplying aggregate services in a distributed computing environment
US20040044656A1 (en) System for web service generation and brokering
US20040045004A1 (en) System for runtime web service to java translation
US20020010781A1 (en) Shared service messaging models
US20010047385A1 (en) Passthru to shared service funtionality
US20060031850A1 (en) System and method for a Web service virtual interface
WO2003034219A1 (en) System and method for implementing an event adapter
WO2003073309A1 (en) Web services programming and deployment
US20020046304A1 (en) Dynamic class loading
US8626825B2 (en) Facilitating a service application to operate with different service frameworks in application servers
AU2003223040A1 (en) Exchange infrastructure system and method
US7353521B1 (en) Object oriented distributed software system with methodology for piggybacked reflective callbacks
KR20040032876A (en) Inbound connector
Siegel A preview of CORBA 3
US7783717B1 (en) System and method for a web service client framework
WO2004003770A1 (en) System and method for web services java api-based invocation
Siegel An overview of CORBA 3
Devin Web‐Oriented Architecture–How to design a RESTFull API
Siddhartha et al. Web services interoperability: A practitioner’s experience
Valikov et al. A model-transformers architecture for Web applications

Legal Events

Date Code Title Description
AK Designated states

Kind code of ref document: A1

Designated state(s): AE AG AL AM AT AU AZ BA BB BG BR BY BZ CA CH CN CO CR CU CZ DE DK DM DZ EC EE ES FI GB GD GE GH GM HR HU ID IL IN IS JP KE KG KP KR KZ LC LK LR LS LT LU LV MA MD MG MK MN MW MX MZ NO NZ OM PH PL PT RO RU SC SD SE SG SK SL TJ TM TN TR TT TZ UA UG UZ VC VN YU ZA ZM ZW

AL Designated countries for regional patents

Kind code of ref document: A1

Designated state(s): GH GM KE LS MW MZ SD SL SZ TZ UG ZM ZW AM AZ BY KG KZ MD RU TJ TM AT BE BG CH CY CZ DE DK EE ES FI FR GB GR HU IE IT LU MC NL PT SE SI SK TR BF BJ CF CG CI CM GA GN GQ GW ML MR NE SN TD TG

121 Ep: the epo has been informed by wipo that ep was designated in this application
122 Ep: pct application non-entry in european phase
NENP Non-entry into the national phase

Ref country code: JP

WWW Wipo information: withdrawn in national office

Country of ref document: JP