Configuring Persistent Channels Advanced Topic: Persisting Messages to Physical Storage

Using the HTTP Publish-Subscribe Server 12-23 receives all messages that have been published to the persistent channel during that time; if the client reconnects after the timeout, then it does not get the messages. The default value is 600 seconds.

12.7.1 Configuring Persistent Channels

You configure a persistent channel in the weblogic-pubsub.xml deployment descriptor file of the pub-sub server. First configure the pub-sub by adding a wlps:persistent-client-timeout-secs child element of wlps:server-config if you want to change the default persistent timeout value of 600 seconds. Then you configure a persistent channel by adding a wlps:channel-persistence child element of wlps:channel and specify the maximum amount of time that messages for that channel should be persisted and the name of the persistent store to which the messages should be persisted. The following example shows the relevant sections of the weblogic-pubsub.xml file: ?xml version=1.0 encoding=UTF-8? wlps:weblogic-pubsub xmlns:wlps=http:xmlns.oracle.comweblogicweblogic-pubsub wlps:server-config ... wlps:persistent-client-timeout-secs400wlps:persistent-client-timeout-secs wlps:server-config wlps:channel wlps:channel-patternchatwlps:channel-pattern wlps:channel-persistence wlps:max-persistent-message-duration-secs3000wlps:max-persistent-message-durat ion-secs wlps:persistent-storePubSubFileStorewlps:persistent-store wlps:channel-persistence wlps:channel wlps:weblogic-pubsub In the preceding example: ■ The persistent client timeout value is 400 seconds. This value applies to all persistent channels of this pub-sub server. ■ The channel with pattern chat, and all its subchannels, has been configured as a persistent channel. The messages will be persisted to a WebLogic persistent store called PubSubFileStore and they will live for a maximum of 3000 seconds in the store. It is assumed that you have already created and configured the PubSubFileStore using the WebLogic Server Administration Console; for details, see Using the WebLogic Persistent Store in Configuring Server Environments for Oracle WebLogic Server. 12-24 Developing Web Applications, Servlets, and JSPs for Oracle WebLogic Server 13 WebLogic JSP Reference 13-1 13 WebLogic JSP Reference The following sections provide reference information for writing JavaServer Pages JSPs: ■ Section 13.1, JSP Tags