You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by ch...@apache.org on 2006/12/31 18:32:42 UTC
svn commit: r491452 -
/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java
Author: chirino
Date: Sun Dec 31 09:32:40 2006
New Revision: 491452
URL: http://svn.apache.org/viewvc?view=rev&rev=491452
Log:
Fix RecoveryBrokerTest that I messed up :)
Modified:
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java
Modified: incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java?view=diff&rev=491452&r1=491451&r2=491452
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java (original)
+++ incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java Sun Dec 31 09:32:40 2006
@@ -48,7 +48,7 @@
private String subscriberName;
private Destination regionDestination;
- boolean empty=true;
+ boolean empty;
private MessageId firstMessageId;
private MessageId lastMessageId;
@@ -65,7 +65,16 @@
this.subscriberName=subscriberName;
}
- public void start() throws Exception{
+ public void start() throws Exception {
+ if(batchList.isEmpty()){
+ try{
+ fillBatch();
+ }catch(Exception e){
+ log.error("Failed to fill batch",e);
+ throw new RuntimeException(e);
+ }
+ empty = batchList.isEmpty();
+ }
}
public void stop() throws Exception{
Re: svn commit: r491452 - /incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java
Posted by Hiram Chirino <hi...@hiramchirino.com>.
which one?
On 12/31/06, chirino@apache.org <ch...@apache.org> wrote:
> Author: chirino
> Date: Sun Dec 31 09:32:40 2006
> New Revision: 491452
>
> URL: http://svn.apache.org/viewvc?view=rev&rev=491452
> Log:
> Fix RecoveryBrokerTest that I messed up :)
>
> Modified:
> incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java
>
> Modified: incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java
> URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java?view=diff&rev=491452&r1=491451&r2=491452
> ==============================================================================
> --- incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java (original)
> +++ incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java Sun Dec 31 09:32:40 2006
> @@ -48,7 +48,7 @@
> private String subscriberName;
> private Destination regionDestination;
>
> - boolean empty=true;
> + boolean empty;
> private MessageId firstMessageId;
> private MessageId lastMessageId;
>
> @@ -65,7 +65,16 @@
> this.subscriberName=subscriberName;
> }
>
> - public void start() throws Exception{
> + public void start() throws Exception {
> + if(batchList.isEmpty()){
> + try{
> + fillBatch();
> + }catch(Exception e){
> + log.error("Failed to fill batch",e);
> + throw new RuntimeException(e);
> + }
> + empty = batchList.isEmpty();
> + }
> }
>
> public void stop() throws Exception{
>
>
>
--
Regards,
Hiram
Blog: http://hiramchirino.com