News for hackers. Stuff that matters.
Re:Ask HN: Have you ever used PL/pgSQL – the PostgreSQL prog... by mooreds on Sunday September 02, 2018 @09:32PM (#17899657)
How did you handle deployment and version control?
Re:Ask HN: Have you ever used PL/pgSQL – the PostgreSQL prog... by kennytilton on Sunday September 02, 2018 @10:00PM (#17899769)
I left before the system got much use, so grain of salt and all that. It was a Rails shop so deployment would have been by a migration. Not sure what you mean by version control. The source was in git. Had we refactored significantly we would have had to write a migration. But the system was in the end quite simple. I refer to it as "BPM" but real BPMN is a bloated monstrosity -- I just captured the essence, and that was dead simple. One fun thing I did not mention was implementing "funcall" in pgsql. That meant that edge cases could be covered by writing a custom pgsql function that would do exactly what was needed. That meant the rest of BPM could stay simple.
Re:Ask HN: Have you ever used PL/pgSQL – the PostgreSQL prog... by combatentropy on Sunday September 02, 2018 @11:26PM (#17900105)
Store the command to create the function in a file, and save the file in your version-control system. Make changes to the function only by first changing the file and then running the file through psql.