Package org.neo4j.graphdb

Examples of org.neo4j.graphdb.Transaction.finish()


                    tx.success();
                    return true;
                }
                finally
                {
                    tx.finish();
                }
            }
        } );
        executorService.execute( reader );
View Full Code Here


        try {
            clearIndex(result);
            removeNodes(result, maxNodesToDelete);
            tx.success();
        } finally {
            tx.finish();
        }
        return result;
    }

    private void removeNodes(Map<String, Object> result, long maxNodesToDelete) {
View Full Code Here

                final Index<Relationship> index = indexManager.forRelationships("rel_index_" + String.valueOf(i % 5));
                index.add(relationship, "ID", i);
            }
            tx.success();
        } finally {
            tx.finish();
        }
    }
}
View Full Code Here

                pc.setProperty(property, pc.getProperty(property));
                count++;
                if (count >= 10000) {
                    count = 0;
                    tx.success();
                    tx.finish();
                    tx = rawGraphDB.beginTx();
                }
            }
        }
        tx.success();
View Full Code Here

                    tx = rawGraphDB.beginTx();
                }
            }
        }
        tx.success();
        tx.finish();
    }

    public String toString() {
        return StringFactory.graphString(this, this.rawGraph.toString());
    }
View Full Code Here

                rawGraphDB.getReferenceNode().delete();
                tx.success();
            } catch (Exception e) {
                tx.failure();
            } finally {
                tx.finish();
            }

            GlobalGraphOperations graphOperations = GlobalGraphOperations.at(rawGraphDB);
            if (this.vertexIndexKeys.size() > 0)
                populateKeyIndices(rawGraphDB, rawGraphDB.index().getNodeAutoIndexer(), graphOperations.getAllNodes(), Vertex.class);
View Full Code Here

                pc.setProperty(property, pc.getProperty(property));
                count++;
                if (count >= 10000) {
                    count = 0;
                    tx.success();
                    tx.finish();
                    tx = rawGraphDB.beginTx();
                }
            }
        }
        tx.success();
View Full Code Here

                    tx = rawGraphDB.beginTx();
                }
            }
        }
        tx.success();
        tx.finish();
    }

    public String toString() {
        return StringFactory.graphString(this, this.rawGraph.toString());
    }
View Full Code Here

                tx.success();
            }
            finally
            {
                tx.finish();
            }
        }
    }
}
View Full Code Here

        Transaction tx = graphDb.beginTx();

        optimize(wayId, roadPartsToMerge);

        tx.success();
        tx.finish();

    }

    private void optimize(Long wayId, List<List<Relationship>> roadPartsToMerge) {
        for (List<Relationship> partToMerge : roadPartsToMerge) {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.