public void processDecksOld() {
        DBCursor cursor = deckCollection.find();
        cursor.addOption(Bytes.QUERYOPTION_NOTIMEOUT);
        int countProcessed = 0;
        while (cursor.hasNext()) {
            countProcessed++;
            DBObject deckObject = cursor.next();
            List<String> cards = (List<String>) deckObject.get("cards");
            List<Node> nodes = new ArrayList<Node>();
            for (String card : cards) {

                //System.out.println("Found nodes? "+foundNodes);
                if (!cardNodes.containsKey(card)) {
                    System.out.println("Created new node for card: " + card);
                    Node newCardNode = graphDb.createNode();
                    newCardNode.setProperty("name", card);
                    nodes.add(newCardNode);
                    cardNodes.put(card, newCardNode);
                } else {
                    nodes.add(cardNodes.get(card));
                }

            }
            System.out.println("DECK " + countProcessed + ": Adding relationships for " + cards.size() + " cards");
            for (int i = 0; i < nodes.size(); i++) {
                for (int j = i + 1; j < nodes.size(); j++) {
                    Node node1 = nodes.get(i);
                    Node node2 = nodes.get(j);




                    Transaction tx = graphDb.beginTx();
                    try {
                        Iterable<Relationship> relationships = node1.getRelationships();
                        boolean foundRelationship = false;
                        for (Relationship relationship : relationships) {
                            Node relatedNode = relationship.getOtherNode(node1);
                            String relatedName = relatedNode.getProperty("name").toString();
                            if (relatedName.equalsIgnoreCase(node2.getProperty("name").toString())) {
                                Integer count = (Integer) relationship.getProperty("count");
                                count++;
                                relationship.setProperty("count", count);
                                foundRelationship = true;
                                break;
                            }
                        }
                        if (!foundRelationship) {
                            System.out.println(": Creating new relationship between " + node1.getProperty("name") + " to " + node2.getProperty("name"));
                            Relationship relationship = node1.createRelationshipTo(node2, MtgRelationships.IN_DECK_WITH);
                            relationship.setProperty("count", 1);
                        } else {
                            //System.out.println("updated relationship");
                        }
                        tx.success();
                    } catch (Exception e) {
                        e.printStackTrace();
                    } finally {
                        tx.finish();
                    }
                }
            }


            System.out.println("Processed " + countProcessed + " decks");
        }
    }