diff --git a/lucene/CHANGES.txt b/lucene/CHANGES.txt
index 6c26ecb4e34..1c63484c450 100644
--- a/lucene/CHANGES.txt
+++ b/lucene/CHANGES.txt
@@ -434,6 +434,12 @@ Bug fixes
======================= Lucene 3.x (not yet released) ================
+Changes in backwards compatibility policy
+
+* LUCENE-3140: IndexOutput.copyBytes now takes a DataInput (superclass
+ of IndexInput) as its first argument. (Robert Muir, Dawid Weiss,
+ Mike McCandless)
+
Changes in runtime behavior
* LUCENE-2834: the hash used to compute the lock file name when the
@@ -441,6 +447,11 @@ Changes in runtime behavior
will see a different lucene-XXX-write.lock in your lock directory.
(Robert Muir, Uwe Schindler, Mike McCandless)
+New Features
+
+* LUCENE-3140: Added experimental FST implementation to Lucene.
+ (Robert Muir, Dawid Weiss, Mike McCandless)
+
======================= Lucene 3.2.0 =======================
Changes in backwards compatibility policy
diff --git a/lucene/src/java/org/apache/lucene/index/codecs/VariableGapTermsIndexReader.java b/lucene/src/java/org/apache/lucene/index/codecs/VariableGapTermsIndexReader.java
index 77dc6eda6de..9812d0d14d6 100644
--- a/lucene/src/java/org/apache/lucene/index/codecs/VariableGapTermsIndexReader.java
+++ b/lucene/src/java/org/apache/lucene/index/codecs/VariableGapTermsIndexReader.java
@@ -33,11 +33,11 @@ import org.apache.lucene.store.Directory;
import org.apache.lucene.store.IndexInput;
import org.apache.lucene.util.BytesRef;
import org.apache.lucene.util.CodecUtil;
-import org.apache.lucene.util.automaton.fst.Builder;
-import org.apache.lucene.util.automaton.fst.BytesRefFSTEnum;
-import org.apache.lucene.util.automaton.fst.FST;
-import org.apache.lucene.util.automaton.fst.PositiveIntOutputs;
-import org.apache.lucene.util.automaton.fst.Util; // for toDot
+import org.apache.lucene.util.fst.Builder;
+import org.apache.lucene.util.fst.BytesRefFSTEnum;
+import org.apache.lucene.util.fst.FST;
+import org.apache.lucene.util.fst.PositiveIntOutputs;
+import org.apache.lucene.util.fst.Util; // for toDot
/** See {@link VariableGapTermsIndexWriter}
*
diff --git a/lucene/src/java/org/apache/lucene/index/codecs/VariableGapTermsIndexWriter.java b/lucene/src/java/org/apache/lucene/index/codecs/VariableGapTermsIndexWriter.java
index 9c1aba93f93..d10608879cb 100644
--- a/lucene/src/java/org/apache/lucene/index/codecs/VariableGapTermsIndexWriter.java
+++ b/lucene/src/java/org/apache/lucene/index/codecs/VariableGapTermsIndexWriter.java
@@ -29,9 +29,9 @@ import org.apache.lucene.store.IndexOutput;
import org.apache.lucene.util.BytesRef;
import org.apache.lucene.util.CodecUtil;
import org.apache.lucene.util.IOUtils;
-import org.apache.lucene.util.automaton.fst.Builder;
-import org.apache.lucene.util.automaton.fst.FST;
-import org.apache.lucene.util.automaton.fst.PositiveIntOutputs;
+import org.apache.lucene.util.fst.Builder;
+import org.apache.lucene.util.fst.FST;
+import org.apache.lucene.util.fst.PositiveIntOutputs;
/**
* Selects index terms according to provided pluggable
diff --git a/lucene/src/java/org/apache/lucene/index/codecs/simpletext/SimpleTextFieldsReader.java b/lucene/src/java/org/apache/lucene/index/codecs/simpletext/SimpleTextFieldsReader.java
index 5f5b68cb044..ab17022d9d3 100644
--- a/lucene/src/java/org/apache/lucene/index/codecs/simpletext/SimpleTextFieldsReader.java
+++ b/lucene/src/java/org/apache/lucene/index/codecs/simpletext/SimpleTextFieldsReader.java
@@ -32,11 +32,11 @@ import org.apache.lucene.util.Bits;
import org.apache.lucene.util.CharsRef;
import org.apache.lucene.util.StringHelper;
import org.apache.lucene.util.UnicodeUtil;
-import org.apache.lucene.util.automaton.fst.Builder;
-import org.apache.lucene.util.automaton.fst.BytesRefFSTEnum;
-import org.apache.lucene.util.automaton.fst.FST;
-import org.apache.lucene.util.automaton.fst.PositiveIntOutputs;
-import org.apache.lucene.util.automaton.fst.PairOutputs;
+import org.apache.lucene.util.fst.Builder;
+import org.apache.lucene.util.fst.BytesRefFSTEnum;
+import org.apache.lucene.util.fst.FST;
+import org.apache.lucene.util.fst.PositiveIntOutputs;
+import org.apache.lucene.util.fst.PairOutputs;
import java.io.IOException;
import java.util.Comparator;
diff --git a/lucene/src/java/org/apache/lucene/util/automaton/fst/Builder.java b/lucene/src/java/org/apache/lucene/util/fst/Builder.java
similarity index 99%
rename from lucene/src/java/org/apache/lucene/util/automaton/fst/Builder.java
rename to lucene/src/java/org/apache/lucene/util/fst/Builder.java
index 19949170936..b5736264e2d 100644
--- a/lucene/src/java/org/apache/lucene/util/automaton/fst/Builder.java
+++ b/lucene/src/java/org/apache/lucene/util/fst/Builder.java
@@ -1,4 +1,4 @@
-package org.apache.lucene.util.automaton.fst;
+package org.apache.lucene.util.fst;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
diff --git a/lucene/src/java/org/apache/lucene/util/automaton/fst/ByteSequenceOutputs.java b/lucene/src/java/org/apache/lucene/util/fst/ByteSequenceOutputs.java
similarity index 98%
rename from lucene/src/java/org/apache/lucene/util/automaton/fst/ByteSequenceOutputs.java
rename to lucene/src/java/org/apache/lucene/util/fst/ByteSequenceOutputs.java
index f99c80f93c1..89690908201 100644
--- a/lucene/src/java/org/apache/lucene/util/automaton/fst/ByteSequenceOutputs.java
+++ b/lucene/src/java/org/apache/lucene/util/fst/ByteSequenceOutputs.java
@@ -1,4 +1,4 @@
-package org.apache.lucene.util.automaton.fst;
+package org.apache.lucene.util.fst;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
@@ -25,6 +25,7 @@ import org.apache.lucene.util.BytesRef;
/**
* Output is a sequence of bytes, for each input term.
+ *
* @lucene.experimental
*/
diff --git a/lucene/src/java/org/apache/lucene/util/automaton/fst/BytesRefFSTEnum.java b/lucene/src/java/org/apache/lucene/util/fst/BytesRefFSTEnum.java
similarity index 98%
rename from lucene/src/java/org/apache/lucene/util/automaton/fst/BytesRefFSTEnum.java
rename to lucene/src/java/org/apache/lucene/util/fst/BytesRefFSTEnum.java
index 01ce6efe449..e3eff43551b 100644
--- a/lucene/src/java/org/apache/lucene/util/automaton/fst/BytesRefFSTEnum.java
+++ b/lucene/src/java/org/apache/lucene/util/fst/BytesRefFSTEnum.java
@@ -1,4 +1,4 @@
-package org.apache.lucene.util.automaton.fst;
+package org.apache.lucene.util.fst;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
@@ -22,6 +22,7 @@ import java.io.IOException;
import org.apache.lucene.util.BytesRef;
/** Can next() and advance() through the terms in an FST
+ *
* @lucene.experimental
*/
diff --git a/lucene/src/java/org/apache/lucene/util/automaton/fst/FST.java b/lucene/src/java/org/apache/lucene/util/fst/FST.java
similarity index 99%
rename from lucene/src/java/org/apache/lucene/util/automaton/fst/FST.java
rename to lucene/src/java/org/apache/lucene/util/fst/FST.java
index 62c5199e77e..04428c6b356 100644
--- a/lucene/src/java/org/apache/lucene/util/automaton/fst/FST.java
+++ b/lucene/src/java/org/apache/lucene/util/fst/FST.java
@@ -1,4 +1,4 @@
-package org.apache.lucene.util.automaton.fst;
+package org.apache.lucene.util.fst;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
@@ -23,7 +23,7 @@ import org.apache.lucene.store.DataInput;
import org.apache.lucene.store.DataOutput;
import org.apache.lucene.util.ArrayUtil;
import org.apache.lucene.util.CodecUtil;
-import org.apache.lucene.util.automaton.fst.Builder.UnCompiledNode;
+import org.apache.lucene.util.fst.Builder.UnCompiledNode;
// NOTE: while the FST is able to represent a non-final
// dead-end state (NON_FINAL_END_NODE=0), the layres above
@@ -32,6 +32,7 @@ import org.apache.lucene.util.automaton.fst.Builder.UnCompiledNode;
/** Represents an FST using a compact byte[] format.
*
The format is similar to what's used by Morfologik
* (http://sourceforge.net/projects/morfologik).
+ *
* @lucene.experimental
*/
public class FST {
diff --git a/lucene/src/java/org/apache/lucene/util/automaton/fst/FSTEnum.java b/lucene/src/java/org/apache/lucene/util/fst/FSTEnum.java
similarity index 99%
rename from lucene/src/java/org/apache/lucene/util/automaton/fst/FSTEnum.java
rename to lucene/src/java/org/apache/lucene/util/fst/FSTEnum.java
index db1b7ddee12..8fbd4ea7f1d 100644
--- a/lucene/src/java/org/apache/lucene/util/automaton/fst/FSTEnum.java
+++ b/lucene/src/java/org/apache/lucene/util/fst/FSTEnum.java
@@ -1,4 +1,4 @@
-package org.apache.lucene.util.automaton.fst;
+package org.apache.lucene.util.fst;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
@@ -23,6 +23,7 @@ import org.apache.lucene.util.RamUsageEstimator;
import java.io.IOException;
/** Can next() and advance() through the terms in an FST
+ *
* @lucene.experimental
*/
diff --git a/lucene/src/java/org/apache/lucene/util/automaton/fst/IntSequenceOutputs.java b/lucene/src/java/org/apache/lucene/util/fst/IntSequenceOutputs.java
similarity index 98%
rename from lucene/src/java/org/apache/lucene/util/automaton/fst/IntSequenceOutputs.java
rename to lucene/src/java/org/apache/lucene/util/fst/IntSequenceOutputs.java
index 807bd836c59..8f3ad732814 100644
--- a/lucene/src/java/org/apache/lucene/util/automaton/fst/IntSequenceOutputs.java
+++ b/lucene/src/java/org/apache/lucene/util/fst/IntSequenceOutputs.java
@@ -1,4 +1,4 @@
-package org.apache.lucene.util.automaton.fst;
+package org.apache.lucene.util.fst;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
@@ -25,6 +25,7 @@ import org.apache.lucene.util.IntsRef;
/**
* Output is a sequence of ints, for each input term.
+ *
* @lucene.experimental
*/
diff --git a/lucene/src/java/org/apache/lucene/util/automaton/fst/IntsRefFSTEnum.java b/lucene/src/java/org/apache/lucene/util/fst/IntsRefFSTEnum.java
similarity index 98%
rename from lucene/src/java/org/apache/lucene/util/automaton/fst/IntsRefFSTEnum.java
rename to lucene/src/java/org/apache/lucene/util/fst/IntsRefFSTEnum.java
index cb99f838a3d..cdd79c31c6a 100644
--- a/lucene/src/java/org/apache/lucene/util/automaton/fst/IntsRefFSTEnum.java
+++ b/lucene/src/java/org/apache/lucene/util/fst/IntsRefFSTEnum.java
@@ -1,4 +1,4 @@
-package org.apache.lucene.util.automaton.fst;
+package org.apache.lucene.util.fst;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
@@ -22,6 +22,7 @@ import org.apache.lucene.util.IntsRef;
import java.io.IOException;
/** Can next() and advance() through the terms in an FST
+ *
* @lucene.experimental
*/
diff --git a/lucene/src/java/org/apache/lucene/util/automaton/fst/NoOutputs.java b/lucene/src/java/org/apache/lucene/util/fst/NoOutputs.java
similarity index 97%
rename from lucene/src/java/org/apache/lucene/util/automaton/fst/NoOutputs.java
rename to lucene/src/java/org/apache/lucene/util/fst/NoOutputs.java
index edb9167e84c..40404a3fb90 100644
--- a/lucene/src/java/org/apache/lucene/util/automaton/fst/NoOutputs.java
+++ b/lucene/src/java/org/apache/lucene/util/fst/NoOutputs.java
@@ -1,4 +1,4 @@
-package org.apache.lucene.util.automaton.fst;
+package org.apache.lucene.util.fst;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
@@ -22,6 +22,8 @@ import org.apache.lucene.store.DataOutput;
/**
* Use this if you just want to build an FSA.
+ *
+ * @lucene.experimental
*/
public final class NoOutputs extends Outputs