3

I have strong web-developer background, where in order to show client a demo I've uploaded a solution to demo environment and sent over a link. If case client asked to make changes, I did them in PhpStorm, dev-tested on local env, deployed in one-click from IDE and asked them to reload the page. In was that simple and very efficient.

Now, I am working in Java and I deeply miss those efficiency I had with PHP. Demo deployment stays simple, but changes are a total mess. I need to:

  1. Rebuild the bundle with Maven;
  2. Upload 100Mb to Nexus;
  3. Run a deployment via a specialized tool, which downloads 100Mb, erases old deployment and deploys everything again.

Most of the JARs inside the bundle - 3rd party libs - never change. Redeploying them seems inefficient.

I could use JRebel or tools of that kind, but I am not in the position to make the organization buy proprietary software.

I believe there are teams out there that couldn't rely on paid software too. How to do dev-deploy-test cycle faster by implementing smart architecture and using free tools?

Update: Take my apologies, if the question tastes a bit ranty. What I'd like to know is How do you dev-deploy-test at wherever you work? Only non-interpreted Java-like programming eco-systems are in scope of the question.

user1065145
  • 167
  • 4

1 Answers1

3

You can do patching yourself if you know what you're doing. But if you script that, you'll definitively have a problem: on each release you'll have to list every single changed files.

The goal of maven if to provide a full packaged delivery, so of course by default you'll have a 100mb war. This is the default behaviour because it's the easiest and the safest. But if you don't want to have always a 100MB delivery you can do the following:

  1. Get all the jar inside your current war that aren't from your code
  2. Put them in the library folder of your web server
  3. Set all your dependencies to the scope "provided".

This is a way to go, but if you ever update one of those provided components and forget to upgrade it on the server, you may have a failure and will probably have some trouble tracking it back from the update of the library.

But personnaly I consider that as long you don't have to upload 100MB yourself on each compilation for your own dev environment this doesn't worth any trouble, you're not supposed to deliver things that often so you can just wait a minute or two. I'll add this is why i use tomcat and not application server, I don't have any conflicts of already embedded library in the server. JBoss gave me a lot of trouble when I wanted to use a more recent version of jackson on it.

Walfrat
  • 3,536