-
Notifications
You must be signed in to change notification settings - Fork 192
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OSMImporter: BatchInserter and GraphDatabaseService? #223
Comments
re-thinking it again, there might be a way so it won't be that ugly, making an inner interface and passing that as constructor parameter should be OK |
the inner interface idea perfectly solved it without a GraphDatabaseService passed in the constructor, sorry for bothering |
test whether a closed issue can still be commented |
ah ok, it's still possible to comment a closed issue, so if you're interested in my library project ask ahead |
I can make a related comment. The OSMImporter can also be called with a normal GraphDatabaseService, instead of the Batch version. This is slower, but has some advantages in being more reliable. The Batch importer is designed for initial import into the database, and is not ideal for importing at any point later on. I believe there are risks in doing that. I am certainly interested in your library project. Interesting to import shapefiles and OSM to the same database. |
so if you want to import mltiple files to the same database you should go for fileImporter.importFile().shutdown() each time (except for the last, especially if you want to make more stuff on the database) |
and there are some Neo4j-unrelated classes which can also be (more or less) useful, 2 of which (AdvancedList and NotApplicableException) are even used within the ConsistencyManager |
will most probably be labelled "question" I think
but might also be labelled "invalid" because I have no idea whether it belongs here or to the Neo4j forum
does the OSMImporter need the BatchInserter in a way that closes the graph database direction for all GraphDatabaseServices, or can a GraphDatabaseService be open while calling importFile()?
need to know because I'm making some kind of utility library based on Neo4j and Neo4j Spatial, and in this library there's also a FileImporter which can handle both shapefiles and OSM but internally it uses the original Spatial importers
which means, if there can be no GraphDatabaseService running while OSMImporter.importFile() is called I somehow have to pass a user-defined method that creates a (potentially custom) GraphDatabaseService, and I don't want to do that without need because I'm quite fed up with Reflect API after coding ConsistencyManager, so if it does work please let me know that I don't have to mess around with Method objects again (or Runnables, which is not much more convenient)
attached my FileImporter.java (SnippingTool PNG), so you can better understand why it's a problem
The text was updated successfully, but these errors were encountered: