|
MALE SHOEGAZE posted:What in the heck is liquibase i've heard people talk about liquibase at my job. i don't know what it is.
|
# ? Nov 22, 2014 00:07 |
|
|
# ? May 20, 2024 22:19 |
|
it might have something to do with databases though???
|
# ? Nov 22, 2014 00:08 |
|
if i wanted to version control my database i would check the sqlite.db into svn
|
# ? Nov 22, 2014 00:08 |
|
Bloody posted:if i wanted to version control my database i would check the sqlite.db into svn lol
|
# ? Nov 22, 2014 00:15 |
|
i dont understand why you would want to version control a data base. code is meant to be versioned and static, databases are dynamic. have some code that you want to be able to change on the fly in production? stick it in a database field and eval it. now you can write code, dynamically, without having to restart your web app
|
# ? Nov 22, 2014 00:30 |
|
St Evan Echoes posted:i still have my course notes and materials from the db course i took a while back if you give me an email address that'd be great, my email is listed in my profile
|
# ? Nov 22, 2014 00:42 |
|
the 3rd year database class is the only class i have failed
|
# ? Nov 22, 2014 00:49 |
|
MALE SHOEGAZE posted:What in the heck is liquibase it's a migrations library for java it helps you track schema changes and generate deployment/rollback plans to migrate the data among schema versions MALE SHOEGAZE posted:i dont understand why you would want to version control a data base. code is meant to be versioned and static, databases are dynamic. have some code that you want to be able to change on the fly in production? stick it in a database field and eval it. now you can write code, dynamically, without having to restart your web app the data is highly dynamic the schema is not
|
# ? Nov 22, 2014 00:50 |
|
Notorious b.s.d. posted:it's a migrations library for java ah so its like "south" in python then?
|
# ? Nov 22, 2014 00:50 |
|
Snapchat A Titty posted:if it interfaces with the db, it is db code. put the entire application in the database this was something people actually did in the 80s and 90s. dbase, oracle forms, etc when you read old Byte articles from the 90s and they're talking about the "client-server" revolution they're talking about running the application in a separate process from the database this was a rly big deal at the time
|
# ? Nov 22, 2014 00:51 |
|
Valeyard posted:ah so its like "south" in python then? yeah it's exactly like south except that the people who wrote it accounted for corner cases and actually knew what the gently caress they were doing
|
# ? Nov 22, 2014 00:51 |
|
south is a piece of poo poo, I'll give you that
|
# ? Nov 22, 2014 00:56 |
|
Notorious b.s.d. posted:yeah it's exactly like south except that the people who wrote it accounted for corner cases and actually knew what the gently caress they were doing Symbolic Butt posted:south is a piece of poo poo, I'll give you that the first time i used south it managed to get the database into such a state that it was easier to delete (in a dev enviroment on a stupid uni project) the database than try to figure out why south was complaining about it being unrecoverable Valeyard fucked around with this message at 01:02 on Nov 22, 2014 |
# ? Nov 22, 2014 00:57 |
|
Notorious b.s.d. posted:it's a migrations library for java not if you have code that generates new tables on the fly!
|
# ? Nov 22, 2014 01:01 |
|
Space Whale posted:Through CTCI, brain teasers, code rust, being good at selling myself, and being acceptable at code monkey things, I managed to get myself a mid level job. Woo hoo! Why did I post this? So the messaging queue goes from "hey let's just back up and stop and need to be restarted" to "let's look like everything is fine with no pending messages... and fail silently as poo poo." Me and the other FNG keep going "wtf?" at this. Still don't know what's up. I still don't know what the messages are or what is actually going on yet, but I only today got everything set up to even get into code and get on the dev/QA/UAT/production servers. IIS doesn't want to work on my windows 8 machine. I am the first dev using windows 8. The guys using windows 7 had to beat it into working. I now just went "ok gently caress it IIS Express I'll make sure I remember to not check in the web.config changes." Let's see if I do. Our entire team and for that matter our office and equipment is new as poo poo, 5 months at the oldest, and still growing. We still don't have deployment or provisioning automated for setting up a new dev machine. OTOH I'm already helping other devs with stuff so I'm not useless What can I do besides bring up "hey X is a good idea" while things are still so new?
|
# ? Nov 22, 2014 01:23 |
|
St Evan Echoes posted:i still have my course notes and materials from the db course i took a while back if you give me an email address hell yeah, got it and thanks
|
# ? Nov 22, 2014 01:24 |
|
Space Whale posted:Why did I post this? are you on drugs?
|
# ? Nov 22, 2014 01:51 |
|
fst(valeyard.mom)
|
# ? Nov 22, 2014 02:19 |
|
Captain Foo posted:fst(valeyard.mom) fst (mom valeyard) :sperg:
|
# ? Nov 22, 2014 02:26 |
|
almsot done with this thing curious why this doesnt work: code:
by "doesnt work" i mean it returns False instead of True edit1: I realised I had to escape the $ symbol, doh a more pressing issue is how to have a string tabbed edit2: i realised i could just put literally 8 spaces or whatever, that should do for now anyway Valeyard fucked around with this message at 05:14 on Nov 22, 2014 |
# ? Nov 22, 2014 02:49 |
|
MALE SHOEGAZE posted:not if you have code that generates new tables on the fly! temp tables are not part of the schema if you are actually creating schema changes on the fly, you need to stop doing that. either move to a non-sql database w/ an explicitly additive schema, or fix your g-d app ignoring the clarity issue, it's just a bad idea. creating a table is an expensive operation on most SQL DBs. global locks and poo poo
|
# ? Nov 22, 2014 06:24 |
|
Notorious b.s.d. posted:yeah it's exactly like south except that the people who wrote it accounted for corner cases and actually knew what the gently caress they were doing yeah, given the fuckload of different relational databases they have to account for, they've done a pretty drat good job. Liquibase is awesome for version control of course, but it also lets you do sweet stuff like spin up a local H2 database just-in-time to run database integration tests or your local server against. It also keeps track of your schema in a way that is database impl-agnostic (mostly) so you can be sure your poo poo isn't coupled to a particular vendor (or at least you know what part of it is coupled) (not a rep for LB I promise) (LB is not quite SVN or Git, so if you implement it don't let any dumbfuck dev mess with it, they will drop all of your tables I guarantee)
|
# ? Nov 22, 2014 15:57 |
|
liquibase is still really bad, it's just shitloads better than south or activerecord migrations. a low bar to clear. i don't know of any better way to do what liquibase does. versioning schemas and migrating data just sucks
|
# ? Nov 22, 2014 16:28 |
|
Notorious b.s.d. posted:liquibase is still really bad, it's just shitloads better than south or activerecord migrations. a low bar to clear. Like what are you complaints about it?
|
# ? Nov 22, 2014 18:19 |
|
Janitor Prime posted:Like what are you complaints about it? Most of my complaints are more tied to the reality of versioning database objects than with Liquibase itself. E.g. if you want to replace a method in typical code, you remove that method, update references to whatever new method you're using, and commit. It's merged to trunk immediately and at worst you have to do a quick manual merge if your VC can't figure it out. If you want to replace a table in your Liquibase changelog, you're dropping all constraints against that table, making sure the table's data is cleared or migrated, recreating the table, recreating the constraints, and repopulating data if you need to. And all of that, what a traditional VC would manage behind the scenes (all of the little actions that it takes to version code) lives explicitly in your gigantic Liquibase changelog. If everything goes happy path you might never have to look at all those changesets again, but good luck with that. I do have some complaints with the tool itself, it doesn't handle cross-schema dependencies well (although you could argue cross-schema dependencies are often not a great design choice anyway) and the diff is just useful enough to tempt people to use it to manage changes (via a "canonical" non-used schema) but sucks just enough to cause major fuckups when you rely on it (it sees renames as drop+add, misses some types of database objects entirely). But really those also just come down to the suckiness of database object versioning. Lord Of Texas fucked around with this message at 18:40 on Nov 22, 2014 |
# ? Nov 22, 2014 18:35 |
|
looks like a loving nightmare
|
# ? Nov 22, 2014 18:41 |
|
Seaside Loafer posted:looks like a loving nightmare It's a "best of lovely options" situation. If your database is frequently changing Liquibase is a much better option than versioning DDL through text files on Sharepoint or a notepad on some guy's desk.
|
# ? Nov 22, 2014 18:48 |
|
well i suppose but i really would have thought that a good system design would pretty much nail down the db structure before even starting work, is this is for these opensource projects where every arsehole is changing things to their hearts content without bothering to ask anyone else?
|
# ? Nov 22, 2014 19:12 |
|
Seaside Loafer posted:well i suppose but i really would have thought that a good system design would pretty much nail down the db structure before even starting work the first design, yes. there will be many iterations of that design sometimes those changes are simple (e.g. add a new table, add a new column to an existing table). sometimes they are hard (make a 1:1 into a many:many by breaking a column into a pair of new tables). sometimes they're nightmarish (anything with versioning sprocs)
|
# ? Nov 22, 2014 20:45 |
|
i hate it when people want to move poo poo into sprocs. it's the hardest code to version, test, or debug, but it's also likely to be the most performance sensitive and widely-used it's 2014. embrace soa and n-tier. a set of sprocs and views in oracle is not a satisfactory API endpoint.
|
# ? Nov 22, 2014 20:47 |
|
Seaside Loafer posted:well i suppose but i really would have thought that a good system design would pretty much nail down the db structure before even starting work, is this is for these opensource projects where every arsehole is changing things to their hearts content without bothering to ask anyone else? The overall architecture? Yes that's "nailed down" (are we using ORM, are we using stored procs, views, naming conventions, DB vendor, etc.) individual database objects? Sometimes you get it "right" the first time, but frequently you don't and frequently you couldn't have even hoped to because you didn't identify a requirement until you released to prod and got user feedback
|
# ? Nov 22, 2014 23:01 |
|
something++; idk
|
# ? Nov 23, 2014 02:56 |
|
another haskell question i have a list of strings. i need to search through each string, check if it contains a certain substring. and then ideally i need to modify that string i came accross the function findIndex, and also the function isInfixOf. I feel like if I could combine these somehow then it would let me find which strings have the subtring im looking for (using isInfixOf) and then return the index of it using the findIndex function. but i cant really figure out how/if thats the best way
|
# ? Nov 23, 2014 19:57 |
|
Valeyard posted:another haskell question everything is immutable in haskell so you cant change those strings even if you want to you're stuck with them forever. now if you want to apply a tranformation to set of string data maybe we can do something DONT THREAD ON ME fucked around with this message at 20:05 on Nov 23, 2014 |
# ? Nov 23, 2014 20:02 |
|
MALE SHOEGAZE posted:everything is immutable in haskell so you cant change those strings even if you want to you're stuck with them forever well i know that, but i recreate the string and then recreate the list i am thinking i can take my list of strings, zip it with a list of numbers from 0 to size of list - 1. then use list comprehension to go through each string in the list, check if it contains the substring using isInfixOf, and then return a list of indices that has that substring once i have that, i can create a function that takes those indices and does all the lovely work of trying to trim them to get very specific, i am talking about a list of source code like [... "blah", " real(kind=4), dimension(kp+2) :: z2 !$acc argmode read", "blah" ...] where I am looking for that "!$acc argmode read" flag at the end, and then I would like to drop it to become just " real(kind=4), dimension(kp+2) :: z2" Valeyard fucked around with this message at 20:08 on Nov 23, 2014 |
# ? Nov 23, 2014 20:05 |
|
Valeyard posted:another haskell question wouldn't you just want to use a map function with the isInfixOf function? I'm not a haskell programmer though so whatever
|
# ? Nov 23, 2014 20:15 |
|
Valeyard posted:another haskell question these are where strings really start to be bad. i think the easiest (and least terrible) way is to use Data.Text's replace to turn the target string into the empty string, with pack and unpack to turn a string into a text and back. the language extension OverloadedStrings will let you use string literals for text values instead of having to pack them yourself
|
# ? Nov 23, 2014 20:16 |
|
since it's a cw i'm not going to write it for you though (it's 1 line if you use function composition instead of naming everything) e: then as MeruFM said, just map your new dropFlag function across your list of strings gonadic io fucked around with this message at 20:22 on Nov 23, 2014 |
# ? Nov 23, 2014 20:18 |
|
AlsoD posted:e: then as MeruFM said, just map your new dropFlag function across your list of strings its not as simple as that though, i only want to drop the flag on lines where it actually exists i know how to get a list of indices of lines it exists code:
code:
e: since this exercise wont be marked on elegance or efficiency of code i am not concerned at all with doing this kind of thing in one liners. i feel like the exercise isnt well suited to haskell anyway, so any which way its done is kind of..bad Valeyard fucked around with this message at 21:46 on Nov 23, 2014 |
# ? Nov 23, 2014 21:42 |
|
|
# ? May 20, 2024 22:19 |
|
can we all jsut take a moment to appreciate the irony of valeyard posting in the safezone
|
# ? Nov 23, 2014 21:50 |