SCA bindings IBM® WebSphere® Application Server V7 Feature Pack for Service Component Architecture SCA bindings This presentation covers the SCA bindings. Binding overview Binding overview SCA component SCA component SCA component SCA component Non-SCA application Domain defined communication Other interoperable communication ex. Web services Service Reference Explicit /default binding Composite Domain Services and references allow a component to communicate with other applications. By design, however, they say nothing about how that communication happens. Bindings do the job of specifying this communication. The figure shows where bindings fit into the SCA picture. A binding specifies exactly how communication should be done between an SCA component and something else. Depending on what it is communicating with, a component might or might not have explicitly specified bindings. As the figure shows, a component that communicates with another component in the same domain, even one in another process or on another machine, need not have any explicit bindings specified. In this scenario, the default binding would be used. To communicate outside its domain, a component’s creator (or perhaps the person who deploys the component) must specify one or more bindings for this communication. Outside domain would include a non-SCA application or an SCA application running in some other domain. Each binding defines a particular protocol that can be used to communicate with this service or reference. A single service or reference can have multiple bindings, allowing different remote software to communicate with it in different ways. Note that an SCA application communicating with another SCA application in a different domain sees that application just like a non-SCA application; therefore would require a binding to be specified for that communication. Binding: Definition Binding: Definition A binding is… A description of an access mechanism offered by a service A description of an access mechanism needed by a reference An aspect of a service or a reference As mentioned in the previous slide, binding specifies exactly how communication should be done between an SCA component and something else. Therefore binding can be defined in three ways. One way is as a description of an access mechanism offered by a Service. Another way is as a description of an access mechanism needed by a Reference or as an aspect of a Service or a Reference. Specifying bindings Specifying bindings Bindings are specified indirectly in Java™ Bindings are: Set explicitly in the component’s SCDL configuration file If not specified the chosen binding is always the SCA default binding A binding is defined by a binding element Example: Element’s name – protocol (Type of binding) Element’s URI (where ) According to the SCA Java component implementation specification version 1.0, bindings are specified indirectly in Java. They are independent of the programming language used. They may be specified in SCDL or defaulted. The Web service or EJB bindings are specified in a component’s SCDL configuration file. If bindings are not specified the SCA default binding is used. Here is an example of how a binding for a component’s service might be specified: In this example, the binding element specifies two things: what protocol the binding uses and where the service can be accessed using this protocol. The binding.ws in the element’s name indicates the first of these, specifying the Web services binding. The element’s URI attribute indicates the second, specifying the URL at which the service can be found. Note that it is also possible and much more likely for a Web service binding to use a relative URL rather than the absolute form shown here. Purpose of bindings Purpose of bindings Bindings determine how a component communicates with the world outside its domain References use bindings to describe the access mechanism used to call a service Services use bindings to describe the access mechanism that clients have to use to call the service Bindings determine how a component communicates with the world outside its domain. They are used by both services and references. References use bindings to describe the access mechanism used to call a service, which can be a service provided by another SCA component. Services use bindings to describe the access mechanism that clients, which can be a client from another SCA component, have to use to call the service. In general, SCA allows each remotable service and each reference to specify the protocols it supports using bindings. Why bindings are useful Why bindings are useful JAX-WS EJB RMI SOAP IIOP Binary protocol Application Service component architecture Service component architecture Service component architecture SOAP IIOP Binary protocol SCA Component Web services binding EJB Binding SCA binding A B SCA uses bindings Protocols wrapped into distinct technologies This figure shows why bindings are useful. Think of how applications use different protocols in Java EE5 and its JEE predecessors. As shown in A, each protocol is provided by a distinct technology, so each one has its own application programming interface. Using SOAP over HTTP, for example, typically means building on JAX-WS (or JAX-RPC in JEE 1.4), while using IIOP means using EJBs. This approach mixes business logic. SCA takes a simpler approach. Rather than wrapping different protocols into distinct technologies with different APIs, SCA allows each remotable service and each reference to specify the protocols it supports using bindings. The programming model seen by an application remains the same regardless of which protocol is used, as the figure B shows. To be accessible through SOAP over HTTP, for example, an SCA service uses the Web services binding. Similarly, the EJB session bean binding allows access to session beans using IIOP. Binding types Binding types Binding types supported in this SCA feature pack Default – SCA binding Web service EJB 2 and 3.0 Binding types supported in the current release of the SCA feature pack include default (SCA) binding, Web service binding and EJB 2 and 3 bindings. These bindings will be discussed in more detail in their individual presentations. Note that: SCA in itself supports the use of multiple different types of bindings like data base stored procedure binding, and EIS service binding. The current release of the SCA feature pack does not support these bindings. Summary Summary Bindings are useful in that they specify exactly how communication should be done between an SCA component and something else Bindings separate communication details from business logic simplifying life for you The three supported bindings in the SCA feature pack are: Default binding Web service binding EJB binding Services and references allow a component to communicate with other applications. By design, however, they say nothing about how that communication happens. Bindings do the job of specifying this communication. Bindings are useful in that they specify exactly how communication should be done between an SCA component and something else. They separate communication details from business logic simplifying life for you. There are three supported bindings in the SCA feature pack namely default, Web service and EJB bindings. Default binding which is the default binding and is used when no other binding is specified for a configuration of a component reference or service. Web service binding defines the manner in which a service can be made available as a Web service, and in which a reference can invoke a Web service. Last but not least, EJB session beans are used to implement business services. References References SCA Specifications: http://www.osoa.org/display/Main/Service+Component+Architecture+Specifications EJB 3.0 bindings: http://publib.boulder.ibm.com/infocenter/wasinfo/v7r0/index.jsp?topic=/com.ibm.websphere.base.doc/info/aes/ae/cejb_bindingsejbfp.html The Service Component Architecture specifications and the information center article on EJB 3.0 bindings are available at the addresses shown here. Feedback Feedback Your feedback is valuable You can help improve the quality of IBM Education Assistant content to better meet your needs by providing feedback. Did you find this module useful? Did it help you solve a problem or answer a question? Do you have suggestions for improvements? Click to send e-mail feedback: mailto:iea@us.ibm.com?subject=Feedback_about_WASv7SCA_SCABindings_overview.ppt This module is also available in PDF format at: ../WASv7SCA_SCABindings_overview.pdf You can help improve the quality of IBM Education Assistant content by providing feedback. Trademarks