4 ms·
Im surprised there is no mention of foreign data wrappers, easily one of the best but lesser known features. Would i use them in production? no. Are they fun t
by tbrock 5y ago
Im surprised there is no mention of foreign data wrappers, easily one of the best but lesser known features.
Would i use them in production? no. Are they fun to play around with? Yes!
- iaabtpbtpnn 5y agoWe use them in production, they work fine. You probably want to enable use_remote_estimate for postgres_fdw though.
- hyzyla 5y agoCould you describe for what use case are you using foreign data wrapper in production?
- shawn-butler 5y agoI used a foreign data wrapper to query elasticsearch indexes from within postgres.[0] It pushed alot of complexity down away from higher-level app developers not familiar with ES patterns. [0]: https://github.com/matthewfranglen/postgres-elasticsearch-fdw https://github.com/matthewfranglen/postgres-elasticsearch-fd...
- adgjlsfhk1 5y agoone place they are great in production is as part of a data migration. if you have an old database system with application code on top that you want to move to pure postgres, fdws provide a way to incrementally rewrite the application logic without ever having to do a hard cutover.
- laurent92 5y agoAtlassian gives us sales figures as a large CSV. Nothing better than loading the CSV as a Postgres view with a foreign data wrapper, and performing pivots/joins/anything on it. Replace the file with a more recent one, and you even have versioning!