Oliver Tonnhofer schrieb am Tuesday, den 18. December um 08:44 Uhr:
> I think an option to `imposm run` to exit after one import is a nicer
> solution. This way you can integrate Imposm into your script, instead of
> adding a "process management" to Imposm. You can do this already with the
> undocumented IMPOSM3_SINGLE_DIFF environment (IMPOSM3_SINGLE_DIFF=1 imposm
> run).
Looks reasonable.
Instead of just calling "imposm run -config config.json" I would
instead build a wrapperscript with an endless loop calling imposm and some
post-update stuff in an endless loop.
> Another solution would be to make Imposm to call arbitrary SQL commands
> after an import/update. This makes it more complex, but the commands can
> run in the same SQL transaction, giving you a clean all-or-nothing.
Frankly, this is what I tried to implement first, but as a complete Go noob
I did not understand how to execute raw SQL from this database abstraction
layer. Likely also only a few lines of code in process.go, right?
Sven
--
# Turn on/off security. Off is currently the default
(found in MongoDB default configfile)