-
I'm wondering how to combine multiple configs best, without conflicting. The current way of creating one config with all the topics can have problems. Two configs could conflict in two ways
For the schemas, For the latter, I'm not sure how to handle it. Better yet would be a way to take two config files and combine the two automatically, rather than making one config file with all the topics. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Regarding schemas: You can reset the schema with Regarding conflicts when modifying objects: Don't do that. Topics should only rarely change objects. The I don't think adding combining two config files is the way to go. You then need a third config file to tell osm2pgsql how to combine them, for instance by using schemas. But there could be other ways, for instance you can using table name prefixes. Or use schemas only on those tables with overlapping names. But this is all Lua so you can write a small wrapper that does the combining for you. |
Beta Was this translation helpful? Give feedback.
Regarding schemas: You can reset the schema with
set_option
any time. I thought it was easier that way instead of having to set the schema on alladd_topic
calls. So set it once for some topics, then include them, then set the schema to something else and then add the rest of the topics. But it should be no problem to add functionality to also allow setting with an option on theadd_topic()
call.Regarding conflicts when modifying objects: Don't do that. Topics should only rarely change objects. The
core/clean-tags
topic is the rare exception here. Most topics should leave the input untouched. They can always amend it by adding data to the second parameter of the processing function. So y…