Using the Oneway Annotation Using the BufferQueue Annotation Using the ReliabilityBuffer Annotation

3-18 Programming Advanced Features of JAX-RPC Web Services for Oracle WebLogic Server For more information about the Policy annotation, see weblogic.jws.Policy in WebLogic Web Services Reference for Oracle WebLogic Server.

3.6.2 Using the Oneway Annotation

If you plan on invoking the reliable Web service operation synchronously or in other words, not using the asynchronous request-response feature, then you must annotate the implementing method with the Oneway annotation to specify that the method is one-way. This means that the method cannot return a value, but rather, must explicitly return void. Conversely, if the method is not annotated with the Oneway annotation, then you must invoke it using the asynchronous request-response feature. If you are unsure how the operation is going to be invoked, consider creating two flavors of the operation: synchronous and asynchronous. See Chapter 2, Invoking a Web Service Using Asynchronous Request-Response, and Chapter 6, Using the Asynchronous Features Together.

3.6.3 Using the BufferQueue Annotation

Use the BufferQueue annotation to specify the JNDI name of the JMS queue which WebLogic Server uses to store reliable messages internally. The JNDI name is the one you configured when creating a JMS queue in step 4 in Section 3.3, Configuring the Destination WebLogic Server Instance . The BufferQueue annotation is optional; if you do not specify it in your JWS file then WebLogic Server uses a queue with a JNDI name of weblogic.wsee.DefaultQueue . You must, however, still explicitly create a JMS queue with this JNDI name using the Administration Console. For more information about the BufferQueue annotation, see weblogic.jws.BufferQueue in WebLogic Web Services Reference for Oracle WebLogic Server.

3.6.4 Using the ReliabilityBuffer Annotation

Use the ReliabilityBuffer annotation to specify the number of times WebLogic Server should attempt to deliver the message from the JMS queue to the Web service implementation and the amount of time that the server should wait in between retries. Use the retryCount attribute to specify the number of retries and the retryDelay attribute to specify the wait time. The format of the retryDelay attribute is a number and then one of the following strings: ■ seconds ■ minutes ■ hours ■ days ■ years For example, to specify a retry count of 20 and a retry delay of two days, use the following syntax: ReliabilityBufferretryCount=20, retryDelay=2 days The retry count and delay default to 3 and 5 seconds, respectively. Using Web Services Reliable Messaging 3-19 For more information about the ReliabilityBuffer annotation, see weblogic.jws.ReliabilityBuffer in WebLogic Web Services Reference for Oracle WebLogic Server.

3.7 Configuring Reliable Messaging for a Reliable Web Service