Make keys able to hold 4GB as well (though I only plan to use it for 2MB keys, max)
diff --git a/README.md b/README.md
index 32ceecf..1915c30 100644
--- a/README.md
+++ b/README.md
@@ -28,7 +28,7 @@
 * A Store can have zero or more Collections.
 * A Collection can have zero or more Items.
 * An Item is a key and value.
-* A key is a []byte, max length 64KB (length is uint16).
+* A key is a []byte, max length 4GB (length is uint32).
 * A value is a []byte, max length 4GB (length is uint32).
 
 ACID properties
diff --git a/item.go b/item.go
index 51c7ece..4159b76 100644
--- a/item.go
+++ b/item.go
@@ -63,7 +63,7 @@
 	atomic.StorePointer(&i.item, unsafe.Pointer(src.Item()))
 }
 
-const itemLoc_hdrLength int = 4 + 2 + 4 + 4
+const itemLoc_hdrLength int = 4 + 4 + 4 + 4
 
 func (i *itemLoc) write(c *Collection) (err error) {
 	if i.Loc().isEmpty() {
@@ -85,8 +85,8 @@
 		pos := 0
 		binary.BigEndian.PutUint32(b[pos:pos+4], uint32(ilength))
 		pos += 4
-		binary.BigEndian.PutUint16(b[pos:pos+2], uint16(len(iItem.Key)))
-		pos += 2
+		binary.BigEndian.PutUint32(b[pos:pos+4], uint32(len(iItem.Key)))
+		pos += 4
 		binary.BigEndian.PutUint32(b[pos:pos+4], uint32(vlength))
 		pos += 4
 		binary.BigEndian.PutUint32(b[pos:pos+4], uint32(iItem.Priority))
@@ -131,8 +131,8 @@
 		pos := 0
 		length := binary.BigEndian.Uint32(b[pos : pos+4])
 		pos += 4
-		keyLength := binary.BigEndian.Uint16(b[pos : pos+2])
-		pos += 2
+		keyLength := binary.BigEndian.Uint32(b[pos : pos+4])
+		pos += 4
 		valLength := binary.BigEndian.Uint32(b[pos : pos+4])
 		pos += 4
 		i := c.store.ItemAlloc(c, keyLength)
diff --git a/store.go b/store.go
index 0393940..8e8d6db 100644
--- a/store.go
+++ b/store.go
@@ -45,7 +45,7 @@
 	// Optional callback to allocate an Item with an Item.Key.  If
 	// your app uses ref-counting, the returned Item should have
 	// logical ref-count of 1.
-	ItemAlloc func(c *Collection, keyLength uint16) *Item
+	ItemAlloc func(c *Collection, keyLength uint32) *Item
 
 	// Optional callback to allow you to track gkvlite's ref-counts on
 	// an Item.  Apps might use this for buffer management and putting
@@ -159,7 +159,7 @@
 
 func collNames(coll map[string]*Collection) []string {
 	res := make([]string, 0, len(coll))
-	for name, _ := range coll {
+	for name := range coll {
 		res = append(res, name)
 	}
 	sort.Strings(res) // Sorting because common callers need stability.
@@ -460,7 +460,7 @@
 	}
 }
 
-func (o *Store) ItemAlloc(c *Collection, keyLength uint16) *Item {
+func (o *Store) ItemAlloc(c *Collection, keyLength uint32) *Item {
 	if o.callbacks.ItemAlloc != nil {
 		return o.callbacks.ItemAlloc(c, keyLength)
 	}
diff --git a/tools/slab/slab.go b/tools/slab/slab.go
index 8dc023e..594b0cc 100644
--- a/tools/slab/slab.go
+++ b/tools/slab/slab.go
@@ -159,7 +159,7 @@
 		i.Val = b
 		return nil
 	}
-	itemAlloc := func(c *gkvlite.Collection, keyLength uint16) *gkvlite.Item {
+	itemAlloc := func(c *gkvlite.Collection, keyLength uint32) *gkvlite.Item {
 		var n *ItemNode
 		if freeItemNodes != nil {
 			n = freeItemNodes
@@ -290,7 +290,7 @@
 			pri := rand.Int31()
 			var it *gkvlite.Item
 			if scb.ItemAlloc != nil {
-				it = scb.ItemAlloc(x, uint16(len(k)))
+				it = scb.ItemAlloc(x, uint32(len(k)))
 			} else {
 				it = &gkvlite.Item{Key: make([]byte, len(k))}
 			}