Currently I understand flyway has commandline support. We, as developer (or devops :)) we deploy automatically with jenkins and standard tool chain we have.
Issues is when we do application release, We have to apply DB patches. We can definitely automate them; But process at our organization says "we have DBA that needs to review your sql before you apply".
We know its relatively useless, But we still need to support that. Can you suggest a way of doing these ? I mean can / does flyway have hooks that tell us list of migration sql will be applied ? and print on screen or something ,then DBA can execute the same ?
Or can we do some addon to do the same ?
Would really appreciate help here from flyway team.
This is only thing stops us from using flyway in real application.
This answer is about 6 months too late, sorry, and it's a 'you're doing the wrong thing' answer.
Code review is generally accepted as being a good thing, and this applies to database scripts just as much as java/es/go/c++/cobol/whatever code. However, to be effective, the review should be done as soon as possible after the code is written. Doing a review as part of application release -- to any environment -- is way too late. By then the code is probably cold, further, it's way past the point where development and changes are happening. Basically, it's too late to be doing reviews at this stage.
Rather than do this you need to engage your DBAs to do the review as part of the development process -- as early as possible in fact. This way they'll never be in the position of trying to run an unreviewed script, and you'll be able to fully automate using flyway (or any other tool you like).
Hope this helps.
Related
I searched through a couple of questions on the topic "What to use .NET's Windows Workflow for?", (like this and this) and they got me started in grasping the big picture.
But one of the posts mentioned this article, which mentions the term "Process server". More specifically, here's its quote:
It seems like the most obvious use of WF in projects so far is when
you’re building a process server product.
I have been trying to find a clear definition of what a process server is, but did not succeed yet.
One will end up in browsing IBM's WebSphere Process Server, which offers a very short overview of it's purpose, among other links - but I could find no clear and precise definition for Process Server (wikipedia has none).
Could anyone help fill the gap?
The word Process might be closely mapped to something like a Workflow. If you reckon that a workflow needs to be executed, separately, by some entity, you will usually have a Server doing it. So there you go, a process server is something that executes workflows.
Btw, as you can read in one of your links, IBM's WebSphere Process Server at some point changed it's name (and backend apparently) to Business Process Manager. So, continuing with the same line of thinking, and this is me speculating on why they've chosen that name, maybe they thought they were not only executing but also enabling customers to manage workflows. Manage ends up being a more broad and inclusive word (and prettier for the sales guys to use as well :).
WF4 knows how to execute workflows so, yes, it can be used to implement a Process Server.
See, this is my very loose definition of it, it might be greatly improved and completely open to discussion. It really depends on which path you want to take on that discussion.
I am new and I am not sure if this is a place to ask this question.
I developed a web site alone using wordpress framework.
Now, I got a guy who I don't know much to join me to develop the site. We live in different countries and we decide to use Bitbucket for code management.
I do not have any experiences in team working, Bitbucket.
My concerns are:
1. Do I need to upload both source code and database to Bitbucket?
Do you think he will just take all the source code and database and make his own website and become my competitor?
What should I be careful when working in a team? I mean sharing code.
I know maybe I am quite small-minded. I am worried about security problems.
But definitely, I need to have someone to work with me to develop the site.
Please advice and write any sources that are useful for this problem.
Thank you.
I'm not an expert in Wordpress, but the concept still applies:
Source code: yes. Database: no, only the database schema/ SQL scripts to recreate it.
Depends on his ethics. You should reach an agreement with him that guarantees that he won't do so, by writing a contract for example.
Take the following into consideration: coding standards, conventions are followed in naming variables, pages, urls, etc, repository privacy is set correctly, repository privileges are distributed to enable the contributors to do only what they're supposed to do.
I'll leave the rest to you and other fellows on this website to figure out depending on your experience :)
I'm interested to find out what would be the good way to make changes to production database and source code in web application (ASP.NET, SQL Server 2008).
A little bit more details, we develop on local machines, and then we need to transfer the code and database changes to production (pretty much standard story).
At the moment we do it in the evening, change the database directly from management studio on production server, and then just overwrite the existing asp.net code (copy/past).
You're talking about Release management. What you're asking about is a big subject with a LOT of different answers. The best solution for you is not something we can tell you. There are trade offs to consider.
For example, what you're describing is a very basic release management process that would be considered an "immature" process.... It does not take into account rollback plans, versioning, separation of concerns, proper testing, or any of a hundred other factors that a "mature" release management process involves.
A mature process is very good, but if you don't have the resources, it's not feasible.
To get to the point, I don't think you question can be answered fully here. I'd suggest starting to research "change management", "release management", "Application Lifecycle management", and "Applicaiton Development Lifecycle". I'll have a few good starter links for you in a minute.
Just a forewarning, though, you are asking a question that's going to open your eyes and your world in ways you probably haven't considered. There are things like automated builds to consider, tools to do it for you (high priced, free, and everything in between)
http://en.wikipedia.org/wiki/Release_management
http://en.wikipedia.org/wiki/Application_lifecycle_management
A few simple options for JUST what you're asking about can be found here:
http://msdn.microsoft.com/en-us/library/7hd4c0x3(VS.80).aspx
Also, since you talked about source code without mentioning which source control you're using, I need to say... if you're not already using source control, you need to. You'll wonder how you ever lived without it once you start using it.
Depends on whether it's the first deployment of a new app, or an update to the app.
For small updates, record all your database changes as sql scripts. You must strictly enforce that all changes to development are applied as sql scripts. Put the scripts in source control. Deploy the update by running the scripts on production.
For new apps you may have thousands of scripts. You can't run them individually. Consolidating them into a master script takes too much time. (although you still want to check EVERY script into source control). In this case you reach a milestone in development then FREEZE the development database, and declare it a baseline. Use the database tools to generate a master script(s). Deploy production by running this script(s). Manually create data scripts for your lookup tables to keep it separate from junk dev data.
Avoid a database copy. Avoid changing by hand through the GUI. Scripts are the way. How you go about collecting the scripts, consolidating to master scripts, generating the scripts, etc is another story.
I have very little PeopleSoft experience but have been put in a position to support an install. This question could straddles serverfault but is certainly developer oriented.
On a daily basis, we have a PeopleSoft "developer" who writes scripts to fix records/journal entries/approval status etc. To me this screams "bad install" and botched customizations. Is this normal? Is it best practice to have an employee having to write scripts daily just to keep things running?
Note: there is no fraud happening here, he has the full approval of the accounting department when doing this.
It is unlikely that it is the installation. Likely causes:
Bad customization
Missing patches
Bugs in the delivered code
If you only have one admin, though, and you have only one developer, I would be shocked to hear that there is much in the way of custom code.
Back to the question: It is not normal to need to do SQL updates regularly to fix data. Yes, it happens, but not too often. It is also possible that the end users could fix it from the application, but do not for some reason.
Ad-hoc SQL updates can be dangerous and the SQL may change on every request. It is difficult to fully test ad-hoc scripts due to the turnaround they typically require.
I assume these "fixes" are in fact making changes not implemented by the system.
It would be more sensible to either:
Build a custom page to "fix" the entries (or less sensible: modify the delivered pages).
Build and thoroughly test a paramater-driven App Engine to perform the most commonly made changes. It could potentially be run as part of the batch stream.
Watch out on your next upgrade: application tables have had a lot of changes in recent releases.
While the economy has been in the shitter, I've written possibly the most coolest site EVER for unemployed developers looking to buzzword-ify their resumes. (Don't hate the player, hate the game.)
The only problem is, it needs a scheduled task to run once a day to do some data mining. I spent many, many hours a few months ago researching solutions, but nothing seemed sure-fire.
If I have shared hosting and cannot remote in (e.g. mstsc and create a Schedule Task), how can I create a task that will run once a day on the backend of an ASP.NET website?
After all the research I did, I don't think it's possible. Per my last analysis, someone has to visit the site at least once a day to instantiate an instance of HttpApplication.
Does anyone have any solution to making sure an operation runs automatically, no matter whether anyone visits the site, and without anything but FTP access to the website?
Like I said, I've done A LOT of looking into this in the past, and it didn't seem possible. IF YOU HAVE EXPERIENCE implementing a solution, please, contribute your advice! But not postulating or conjecturing needed--it's far more nuanced and difficult than you're surely imagining.
I had a similar problem. I wrote a cheap utility that issued a web request from my desktop to my web app on a regular schedule.
How To: Send Data Using the WebRequest Class
You could have a look at Quartz.NET for scheduling jobs.
DotNetNuke which is a popular open source .net content management system does this. You can download the source and see exactly how they did it.
I agree with HackedByChinese, but if you don't want to run it from your desktop, you could get something like http://aremysitesup.com/ to ping your site for you.
Can you schedule a task in SQL Server that could call a CLR function? Your hosting provider may not allow either ot both of those, but if they do, then you are golden.
You can use ATrigger scheduling service. A .Net library is also available to create scheduled tasks without overhead.
You can set to call your datamining URL every 1day.
Related example: http://atrigger.com/docs/wiki/17/use-case-delayed-processing
Benefits:
Reporting
Error Log
Tasks List
Great Timing Features
Disclaimer: I was among the ATrigger team. It's a freeware and I have not any commercial purpose.