mirror of https://github.com/apache/activemq.git
Switch to scala 2.10
git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@1429079 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
c61ee931f6
commit
1949846c0a
|
@ -274,7 +274,7 @@
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.scalatest</groupId>
|
<groupId>org.scalatest</groupId>
|
||||||
<artifactId>scalatest_2.9.1</artifactId>
|
<artifactId>scalatest_${scala-version}</artifactId>
|
||||||
<version>${scalatest-version}</version>
|
<version>${scalatest-version}</version>
|
||||||
<scope>test</scope>
|
<scope>test</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
@ -290,8 +290,8 @@
|
||||||
|
|
||||||
<plugins>
|
<plugins>
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.scala-tools</groupId>
|
<groupId>net.alchim31.maven</groupId>
|
||||||
<artifactId>maven-scala-plugin</artifactId>
|
<artifactId>scala-maven-plugin</artifactId>
|
||||||
<version>${scala-plugin-version}</version>
|
<version>${scala-plugin-version}</version>
|
||||||
<executions>
|
<executions>
|
||||||
<execution>
|
<execution>
|
||||||
|
@ -327,7 +327,7 @@
|
||||||
<compilerPlugin>
|
<compilerPlugin>
|
||||||
<groupId>org.fusesource.jvmassert</groupId>
|
<groupId>org.fusesource.jvmassert</groupId>
|
||||||
<artifactId>jvmassert</artifactId>
|
<artifactId>jvmassert</artifactId>
|
||||||
<version>1.1</version>
|
<version>1.4</version>
|
||||||
</compilerPlugin>
|
</compilerPlugin>
|
||||||
</compilerPlugins>
|
</compilerPlugins>
|
||||||
</configuration>
|
</configuration>
|
||||||
|
@ -379,13 +379,9 @@
|
||||||
<pluginExecutions>
|
<pluginExecutions>
|
||||||
<pluginExecution>
|
<pluginExecution>
|
||||||
<pluginExecutionFilter>
|
<pluginExecutionFilter>
|
||||||
<groupId>
|
<groupId>org.fusesource.hawtbuf</groupId>
|
||||||
org.fusesource.hawtbuf
|
<artifactId>hawtbuf-protoc</artifactId>
|
||||||
</groupId>
|
<versionRange>[${hawtbuf-version},)</versionRange>
|
||||||
<artifactId>
|
|
||||||
hawtbuf-protoc
|
|
||||||
</artifactId>
|
|
||||||
<versionRange>[1.9,)</versionRange>
|
|
||||||
<goals>
|
<goals>
|
||||||
<goal>compile</goal>
|
<goal>compile</goal>
|
||||||
</goals>
|
</goals>
|
||||||
|
@ -396,13 +392,9 @@
|
||||||
</pluginExecution>
|
</pluginExecution>
|
||||||
<pluginExecution>
|
<pluginExecution>
|
||||||
<pluginExecutionFilter>
|
<pluginExecutionFilter>
|
||||||
<groupId>org.scala-tools</groupId>
|
<groupId>net.alchim31.maven</groupId>
|
||||||
<artifactId>
|
<artifactId>scala-maven-plugin</artifactId>
|
||||||
maven-scala-plugin
|
<versionRange>[${scala-plugin-version},)</versionRange>
|
||||||
</artifactId>
|
|
||||||
<versionRange>
|
|
||||||
[2.15.1,)
|
|
||||||
</versionRange>
|
|
||||||
<goals>
|
<goals>
|
||||||
<goal>compile</goal>
|
<goal>compile</goal>
|
||||||
<goal>testCompile</goal>
|
<goal>testCompile</goal>
|
||||||
|
|
|
@ -53,7 +53,7 @@ package object leveldb {
|
||||||
attempt = Thread.currentThread().getContextClassLoader().loadClass(name).newInstance().asInstanceOf[SnappyTrait];
|
attempt = Thread.currentThread().getContextClassLoader().loadClass(name).newInstance().asInstanceOf[SnappyTrait];
|
||||||
attempt.compress("test")
|
attempt.compress("test")
|
||||||
} catch {
|
} catch {
|
||||||
case x =>
|
case x:Throwable =>
|
||||||
attempt = null
|
attempt = null
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -470,7 +470,7 @@ class LevelDBClient(store: LevelDBStore) {
|
||||||
-1
|
-1
|
||||||
}
|
}
|
||||||
} catch {
|
} catch {
|
||||||
case e => throw new Exception("Unexpected version file format: " + version_file)
|
case e:Throwable => throw new Exception("Unexpected version file format: " + version_file)
|
||||||
}
|
}
|
||||||
ver match {
|
ver match {
|
||||||
case STORE_SCHEMA_VERSION => // All is good.
|
case STORE_SCHEMA_VERSION => // All is good.
|
||||||
|
@ -702,14 +702,13 @@ class LevelDBClient(store: LevelDBStore) {
|
||||||
}
|
}
|
||||||
|
|
||||||
private def storeCounters = {
|
private def storeCounters = {
|
||||||
def storeMap(key:Array[Byte], map:HashMap[Long, _ <: AnyRef]) {
|
def storeMap[T <: AnyRef](key:Array[Byte], map:HashMap[Long, T]) {
|
||||||
val baos = new ByteArrayOutputStream()
|
val baos = new ByteArrayOutputStream()
|
||||||
val os = new ObjectOutputStream(baos);
|
val os = new ObjectOutputStream(baos);
|
||||||
os.writeInt(map.size);
|
os.writeInt(map.size);
|
||||||
map.foreach {
|
for( (k,v) <- map ) {
|
||||||
case (k, v) =>
|
os.writeLong(k)
|
||||||
os.writeLong(k)
|
os.writeObject(v)
|
||||||
os.writeObject(v)
|
|
||||||
}
|
}
|
||||||
os.close()
|
os.close()
|
||||||
index.put(key, baos.toByteArray)
|
index.put(key, baos.toByteArray)
|
||||||
|
|
|
@ -582,7 +582,6 @@ class LevelDBStore extends LockableServiceSupport with BrokerServiceAware with P
|
||||||
override def removeAsyncMessage(context: ConnectionContext, ack: MessageAck): Unit = {
|
override def removeAsyncMessage(context: ConnectionContext, ack: MessageAck): Unit = {
|
||||||
if( ack.getTransactionId!=null ) {
|
if( ack.getTransactionId!=null ) {
|
||||||
transaction(ack.getTransactionId).remove(this, ack)
|
transaction(ack.getTransactionId).remove(this, ack)
|
||||||
DONE
|
|
||||||
} else {
|
} else {
|
||||||
waitOn(withUow{uow=>
|
waitOn(withUow{uow=>
|
||||||
doRemove(uow, ack.getLastMessageId)
|
doRemove(uow, ack.getLastMessageId)
|
||||||
|
|
|
@ -184,7 +184,7 @@ object FileSupport {
|
||||||
try {
|
try {
|
||||||
proc(closable)
|
proc(closable)
|
||||||
} finally {
|
} finally {
|
||||||
try { closable.close } catch { case ignore => }
|
try { closable.close } catch { case ignore:Throwable => }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
4
pom.xml
4
pom.xml
|
@ -100,8 +100,8 @@
|
||||||
<rome-version>1.0</rome-version>
|
<rome-version>1.0</rome-version>
|
||||||
<saxon-version>9.4</saxon-version>
|
<saxon-version>9.4</saxon-version>
|
||||||
<saxon-bundle-version>9.4.0.1_2</saxon-bundle-version>
|
<saxon-bundle-version>9.4.0.1_2</saxon-bundle-version>
|
||||||
<scala-plugin-version>2.15.2</scala-plugin-version>
|
<scala-plugin-version>3.1.0</scala-plugin-version>
|
||||||
<scala-version>2.9.1</scala-version>
|
<scala-version>2.10.0</scala-version>
|
||||||
<scalatest-version>1.8</scalatest-version>
|
<scalatest-version>1.8</scalatest-version>
|
||||||
<slf4j-version>1.6.6</slf4j-version>
|
<slf4j-version>1.6.6</slf4j-version>
|
||||||
<spring-version>3.0.7.RELEASE</spring-version>
|
<spring-version>3.0.7.RELEASE</spring-version>
|
||||||
|
|
Loading…
Reference in New Issue