activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chir...@apache.org
Subject svn commit: r1426966 - in /activemq/activemq-apollo/trunk: apollo-amqp/src/test/scala/org/apache/activemq/apollo/amqp/test/ apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/ apollo-broker/src/main/scala/org/apache/activemq/apollo/b...
Date Sun, 30 Dec 2012 17:02:54 GMT
Author: chirino
Date: Sun Dec 30 17:02:53 2012
New Revision: 1426966

URL: http://svn.apache.org/viewvc?rev=1426966&view=rev
Log:
Fix some warnings produced by scala 2.10

Modified:
    activemq/activemq-apollo/trunk/apollo-amqp/src/test/scala/org/apache/activemq/apollo/amqp/test/AmqpConnectionTest.scala
    activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/HelperTrait.scala
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Broker.scala
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/CustomServiceFactory.scala
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Topic.scala
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/jetty/WebSocketTransportFactory.scala
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/protocol/Protocol.scala
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/DelayingStoreSupport.scala
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/FileDirectBufferAllocator.scala
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/PBSupport.scala
    activemq/activemq-apollo/trunk/apollo-itests/src/test/java/org/apache/activemq/apollo/StompBrokerProtocol.java
    activemq/activemq-apollo/trunk/apollo-leveldb/src/main/scala/org/apache/activemq/apollo/broker/store/leveldb/LevelDBClient.scala
    activemq/activemq-apollo/trunk/apollo-openwire/src/main/scala/org/apache/activemq/apollo/openwire/OpenwireProtocolHandler.scala
    activemq/activemq-apollo/trunk/apollo-openwire/src/test/scala/org/apache/activemq/apollo/openwire/test/OpenwireParallelTest.scala
    activemq/activemq-apollo/trunk/apollo-scala/pom.xml
    activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
    activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util.scala
    activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/FileSupport.scala
    activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/OptionSupport.scala
    activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/Result.scala
    activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/StateMachine.scala
    activemq/activemq-apollo/trunk/apollo-util/src/test/scala/org/apache/activemq/apollo/util/path/PathMapMemoryTest.scala
    activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/BrokerResource.scala
    activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/Support.scala

Modified: activemq/activemq-apollo/trunk/apollo-amqp/src/test/scala/org/apache/activemq/apollo/amqp/test/AmqpConnectionTest.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-amqp/src/test/scala/org/apache/activemq/apollo/amqp/test/AmqpConnectionTest.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-amqp/src/test/scala/org/apache/activemq/apollo/amqp/test/AmqpConnectionTest.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-amqp/src/test/scala/org/apache/activemq/apollo/amqp/test/AmqpConnectionTest.scala
Sun Dec 30 17:02:53 2012
@@ -27,10 +27,10 @@ import org.apache.qpid.proton.hawtdispat
 
   class AmqpConnectionTest extends AmqpTestSupport {
 
-  def print_result[T](action: String)(then: => Unit): Callback[T] = new Callback[T] {
+  def print_result[T](action: String)(then_action: => Unit): Callback[T] = new Callback[T]
{
     def onSuccess(value: T) {
       println(action + " completed");
-      then
+      then_action
     }
 
     def onFailure(value: Throwable) {
@@ -39,7 +39,7 @@ import org.apache.qpid.proton.hawtdispat
     }
   }
 
-  def then[T](func: (T) => Unit): Callback[T] = new Callback[T] {
+  def then_do[T](func: (T) => Unit): Callback[T] = new Callback[T] {
     def onSuccess(value: T) {
       func(value)
     }

Modified: activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/HelperTrait.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/HelperTrait.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/HelperTrait.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/HelperTrait.scala
Sun Dec 30 17:02:53 2012
@@ -22,6 +22,7 @@ import java.io.Serializable
 import org.apache.activemq.apollo.broker.store._
 import PBSupport._
 import org.fusesource.hawtbuf._
+import language.implicitConversions
 
 object HelperTrait {
 

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Broker.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Broker.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Broker.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Broker.scala
Sun Dec 30 17:02:53 2012
@@ -43,6 +43,7 @@ import java.util
 import javax.management.openmbean.CompositeData
 import javax.net.ssl.SSLContext
 import util.Properties
+import language.implicitConversions
 
 /**
  * <p>

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/CustomServiceFactory.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/CustomServiceFactory.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/CustomServiceFactory.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/CustomServiceFactory.scala
Sun Dec 30 17:02:53 2012
@@ -67,6 +67,7 @@ object SimpleCustomServiceFactory extend
           return null;
       }
 
+      import language.reflectiveCalls
       type ServiceDuckType = {
         var broker: Broker
         var config: CustomServiceDTO

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Topic.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Topic.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Topic.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Topic.scala
Sun Dec 30 17:02:53 2012
@@ -45,6 +45,7 @@ class Topic(val router:LocalRouter, val 
   @transient
   var retained_message: Delivery = _
 
+  import language.implicitConversions
   implicit def from_link(from:LinkDTO):(Long,Long,Long)=(from.enqueue_item_counter, from.enqueue_size_counter,
from.enqueue_ts)
   implicit def from_session(from:DeliverySession):(Long,Long,Long)=(from.enqueue_item_counter,
from.enqueue_size_counter, from.enqueue_ts)
 

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/jetty/WebSocketTransportFactory.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/jetty/WebSocketTransportFactory.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/jetty/WebSocketTransportFactory.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/jetty/WebSocketTransportFactory.scala
Sun Dec 30 17:02:53 2012
@@ -532,7 +532,7 @@ object WebSocketTransportFactory extends
 
     var outbound_capacity_remaining = 1024 * 64;
 
-    val outbound_executor = new SerialExecutor(blockingExecutor) {
+    object outbound_executor extends SerialExecutor(blockingExecutor) {
       var outbound_drained = 0
       override def drained  = {
         val amount = outbound_drained

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/protocol/Protocol.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/protocol/Protocol.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/protocol/Protocol.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/protocol/Protocol.scala
Sun Dec 30 17:02:53 2012
@@ -144,6 +144,7 @@ object SimpleProtocolFilter2Factory exte
         case null => null
         case _ => throw new IllegalArgumentException("Invalid protocol filter type: "+instance.getClass)
       }
+      import language.reflectiveCalls
       type FilterDuckType = {
         var protocol_handler:ProtocolHandler
         var dto:SimpleProtocolFilterDTO

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/DelayingStoreSupport.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/DelayingStoreSupport.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/DelayingStoreSupport.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/DelayingStoreSupport.scala
Sun Dec 30 17:02:53 2012
@@ -26,6 +26,7 @@ import org.fusesource.hawtdispatch.{Base
 import org.apache.activemq.apollo.dto.{StoreStatusDTO, TimeMetricDTO, IntMetricDTO}
 import org.fusesource.hawtbuf.Buffer
 import java.lang.ref.WeakReference
+import language.implicitConversions
 
 object DelayingStoreSupport extends Log
 

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/FileDirectBufferAllocator.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/FileDirectBufferAllocator.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/FileDirectBufferAllocator.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/FileDirectBufferAllocator.scala
Sun Dec 30 17:02:53 2012
@@ -152,7 +152,7 @@ class TreeAllocator(range:Range) extends
     free_by_size.remove(spot)
 
     // only need to put back if it was not exactly what we need.
-    if( spot != req ) {
+    if( spot.offset != req.offset || spot.size != req.size ) {
 
       // deal with excess at the front
       if( spot.offset != req.offset ) {

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/PBSupport.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/PBSupport.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/PBSupport.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/store/PBSupport.scala
Sun Dec 30 17:02:53 2012
@@ -4,6 +4,7 @@ import java.io.{OutputStream, InputStrea
 import org.fusesource.hawtbuf.Buffer
 import org.apache.activemq.apollo.broker.DestinationAddress
 import collection.mutable.ListBuffer
+import language.implicitConversions;
 
 /**
  * Licensed to the Apache Software Foundation (ASF) under one or more

Modified: activemq/activemq-apollo/trunk/apollo-itests/src/test/java/org/apache/activemq/apollo/StompBrokerProtocol.java
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-itests/src/test/java/org/apache/activemq/apollo/StompBrokerProtocol.java?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-itests/src/test/java/org/apache/activemq/apollo/StompBrokerProtocol.java
(original)
+++ activemq/activemq-apollo/trunk/apollo-itests/src/test/java/org/apache/activemq/apollo/StompBrokerProtocol.java
Sun Dec 30 17:02:53 2012
@@ -47,7 +47,7 @@ public class StompBrokerProtocol extends
 
     @Override
     public String name(Destination destination) {
-        return ((StompJmsDestination)destination).getPhysicalName();
+        return ((StompJmsDestination)destination).getName();
     }
 
     @Override

Modified: activemq/activemq-apollo/trunk/apollo-leveldb/src/main/scala/org/apache/activemq/apollo/broker/store/leveldb/LevelDBClient.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-leveldb/src/main/scala/org/apache/activemq/apollo/broker/store/leveldb/LevelDBClient.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-leveldb/src/main/scala/org/apache/activemq/apollo/broker/store/leveldb/LevelDBClient.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-leveldb/src/main/scala/org/apache/activemq/apollo/broker/store/leveldb/LevelDBClient.scala
Sun Dec 30 17:02:53 2012
@@ -38,6 +38,7 @@ import org.apache.activemq.apollo.broker
 import org.apache.activemq.apollo.broker.store.PBSupport
 import java.util.concurrent.atomic.AtomicReference
 import org.fusesource.hawtbuf.{DataByteArrayInputStream, Buffer}
+import language.implicitConversions;
 
 /**
  * @author <a href="http://hiramchirino.com">Hiram Chirino</a>

Modified: activemq/activemq-apollo/trunk/apollo-openwire/src/main/scala/org/apache/activemq/apollo/openwire/OpenwireProtocolHandler.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-openwire/src/main/scala/org/apache/activemq/apollo/openwire/OpenwireProtocolHandler.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-openwire/src/main/scala/org/apache/activemq/apollo/openwire/OpenwireProtocolHandler.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-openwire/src/main/scala/org/apache/activemq/apollo/openwire/OpenwireProtocolHandler.scala
Sun Dec 30 17:02:53 2012
@@ -526,6 +526,8 @@ class OpenwireProtocolHandler extends Pr
             case None=>
               queue(ack(info))
           }
+        case Some(dest) =>
+          queue(fail(new OpenwireException("Internal error", "javax.jms.InvalidDestinationException"),
info))
       }
     }
   }

Modified: activemq/activemq-apollo/trunk/apollo-openwire/src/test/scala/org/apache/activemq/apollo/openwire/test/OpenwireParallelTest.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-openwire/src/test/scala/org/apache/activemq/apollo/openwire/test/OpenwireParallelTest.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-openwire/src/test/scala/org/apache/activemq/apollo/openwire/test/OpenwireParallelTest.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-openwire/src/test/scala/org/apache/activemq/apollo/openwire/test/OpenwireParallelTest.scala
Sun Dec 30 17:02:53 2012
@@ -729,7 +729,7 @@ class OpenwireParallelTest extends Openw
       fail("Expecting JMS Exception")
     } catch {
       case e:JMSException =>
-      case _ => fail("Expecting JMS Exception")
+      case e:Throwable => fail("Expecting JMS Exception")
     }
  }
 

Modified: activemq/activemq-apollo/trunk/apollo-scala/pom.xml
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-scala/pom.xml?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-scala/pom.xml (original)
+++ activemq/activemq-apollo/trunk/apollo-scala/pom.xml Sun Dec 30 17:02:53 2012
@@ -86,12 +86,12 @@
               <goal>${scala-plugin-main-goal}</goal>
             </goals>
             <configuration>
-              <!-- <displayCmd>true</displayCmd> -->
               <testSourceDir>dontcompile</testSourceDir>
               <useFsc>true</useFsc>
               <once>true</once>
               <args>
                 <arg>-deprecation</arg>
+                <arg>-feature</arg>
               </args>
               <compilerPlugins>
                 <compilerPlugin>
@@ -115,6 +115,7 @@
               <once>true</once>
               <args>
                 <arg>-deprecation</arg>
+                <arg>-feature</arg>
               </args>
               <compilerPlugins>
                 <compilerPlugin>
@@ -133,6 +134,13 @@
           </jvmArgs>
           <scalaVersion>${scala-version}</scalaVersion>
           <target>jvm-1.6</target>
+          <javacArgs>
+            <javacArg>-g</javacArg>
+            <javacArg>-target</javacArg>
+            <javacArg>1.6</javacArg>
+            <javacArg>-source</javacArg>
+            <javacArg>1.6</javacArg>
+          </javacArgs>
         </configuration>
       </plugin>
       
@@ -140,7 +148,6 @@
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-surefire-plugin</artifactId>
         <version>${maven-surefire-plugin-version}</version>
-        
         <configuration>
           <childDelegation>false</childDelegation>
           <useFile>true</useFile>
@@ -150,43 +157,4 @@
     </plugins>
   </build>
 
-
-  <profiles>
-    
-    <profile>
-      <id>fsc</id>
-      <properties>
-        <scala-plugin-main-goal>cc</scala-plugin-main-goal>
-        <scala-plugin-test-goal>cc</scala-plugin-test-goal>
-      </properties>
-    </profile>
-    
-    <!-- helper for the IDEA scala integration, enable this profile in IDEA -->
-    <profile>
-      <id>idea</id>
-      <build>
-        <plugins>
-          <plugin>
-            <groupId>net.alchim31.maven</groupId>
-            <artifactId>scala-maven-plugin</artifactId>
-            <version>${scala-plugin-version}</version>
-            <configuration>
-              <args>
-                <arg>-deprecation</arg>
-              </args>
-              <compilerPlugins>
-                <compilerPlugin>
-                  <groupId>org.fusesource.jvmassert</groupId>
-                  <artifactId>jvmassert</artifactId>
-                  <version>1.4</version>
-                </compilerPlugin>
-              </compilerPlugins>
-            </configuration>
-          </plugin>
-        </plugins>
-      </build>
-    </profile>
-
-  </profiles>
-  
 </project>

Modified: activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
Sun Dec 30 17:02:53 2012
@@ -51,6 +51,7 @@ case class RichBuffer(self:Buffer) exten
   }
 }
 
+import language.implicitConversions
 object BufferSupport {
   implicit def to_rich_buffer(value:Buffer):RichBuffer = RichBuffer(value)
 }

Modified: activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util.scala
Sun Dec 30 17:02:53 2012
@@ -19,6 +19,7 @@ package org.apache.activemq.apollo
 import org.fusesource.hawtdispatch._
 import org.fusesource.hawtdispatch.Future
 import java.util.concurrent.CountDownLatch
+import language.implicitConversions
 
 /**
  *

Modified: activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/FileSupport.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/FileSupport.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/FileSupport.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/FileSupport.scala
Sun Dec 30 17:02:53 2012
@@ -18,6 +18,7 @@ package org.apache.activemq.apollo.util
 
 import java.io._
 import org.fusesource.hawtdispatch._
+import language.implicitConversions
 
 object FileSupport {
 

Modified: activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/OptionSupport.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/OptionSupport.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/OptionSupport.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/OptionSupport.scala
Sun Dec 30 17:02:53 2012
@@ -16,6 +16,7 @@
  */
 package org.apache.activemq.apollo.util
 import java.{lang=>jl}
+import language.implicitConversions
 
 /**
  * <p>

Modified: activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/Result.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/Result.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/Result.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/Result.scala
Sun Dec 30 17:02:53 2012
@@ -15,6 +15,7 @@
  * limitations under the License.
  */
 package org.apache.activemq.apollo.util
+import language.implicitConversions
 
 object ResultSupport {
 

Modified: activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/StateMachine.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/StateMachine.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/StateMachine.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/StateMachine.scala
Sun Dec 30 17:02:53 2012
@@ -64,7 +64,7 @@ abstract class StateMachine {
 
   def react[T <: State : Manifest](func: (T)=>Unit) = {
     var m = manifest[T]
-    if( m.erasure == _state.getClass ) {
+    if( m.runtimeClass == _state.getClass ) {
       func(_state.asInstanceOf[T])
     }
   }

Modified: activemq/activemq-apollo/trunk/apollo-util/src/test/scala/org/apache/activemq/apollo/util/path/PathMapMemoryTest.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-util/src/test/scala/org/apache/activemq/apollo/util/path/PathMapMemoryTest.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-util/src/test/scala/org/apache/activemq/apollo/util/path/PathMapMemoryTest.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-util/src/test/scala/org/apache/activemq/apollo/util/path/PathMapMemoryTest.scala
Sun Dec 30 17:02:53 2012
@@ -38,6 +38,7 @@ class PathMapMemoryTest {
   def testVeryLongPaths = {
     var i = 1
     while (i < 100) {
+      i += 1
       var name: String = "1"
       var j = 2
       while (j <= i) {
@@ -49,11 +50,8 @@ class PathMapMemoryTest {
         var map: PathMap[String] = new PathMap[String]
         map.put(d1, "test")
       } catch {
-        case e: Throwable => {
-          fail(("Destination name too long: " + name + " : " + e))
-        }
+        case e: Throwable => fail("Destination name too long: " + name + " : " + e)
       }
-      i += 1
     }
   }
 

Modified: activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/BrokerResource.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/BrokerResource.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/BrokerResource.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/BrokerResource.scala
Sun Dec 30 17:02:53 2012
@@ -36,6 +36,7 @@ import javax.ws.rs.core.MediaType._
 import javax.servlet.http.HttpServletResponse
 import FutureResult._
 import com.wordnik.swagger.annotations.{ApiOperation, Api}
+import language.implicitConversions;
 
 @Path(          "/api/json/broker")
 @Api(value =    "/api/json/broker",

Modified: activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/Support.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/Support.scala?rev=1426966&r1=1426965&r2=1426966&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/Support.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/Support.scala
Sun Dec 30 17:02:53 2012
@@ -39,8 +39,7 @@ import com.sun.jersey.server.impl.Thread
 import com.sun.jersey.spi.resource.Singleton
 import com.sun.jersey.api.view.ImplicitProduces
 import com.sun.jersey.api.core.ResourceConfig
-// import com.wordnik.swagger.jaxrs.{Help, ApiListing}
-// import com.wordnik.swagger.core.{Documentation, ApiOperation, Api}
+import language.implicitConversions;
 
 object Resource extends Log {
 



Mime
View raw message