Automating JDA WMS Environment DevOps — database refresh

Working on JDA WMS for the last 4 years has taught me a lot. Once you understand the architecture of JDA WMS Application, some tasks become menial and repetitive. So why not write scripts around it and spend time in automating such tasks?

Some examples can be:

  1. You are working on developing a cumulative rollout for a client or distribution site or database conversion for an upgrade and would like to rollback the entire database and application. Though the rollout process in itself is automated and takes only a couple of minutes at the most. But if you ever have to rollback from a rollout, it takes time — especially when there are database changes. While this cannot be done easily in Production systems unless you have Oracle Enterprise Edition with flashback enabled, but it is very easy to do for a lower environment like Unit Test.
  2. You need to set up a new environment for testing — Cloning an environment.
  3. Refresh a lower environment from Production
  4. Cloning a database in SQL Server or Schema in Oracle.
  5. Stopping/Starting MOCA and Portal Services

Today, I will give you a simple example of refreshing a database in SQL Server 201x. In larger organizations, you generally have to raise a ticket in ServiceNow (or any other ticketing tool), get approval and then the relevant resource or team performs the task. At a minimum, this task that takes a maximum of 5–10 minutes to perform will now take 2–3 days for a developer — depending on the workload of the database team. To me, that is 2–3 days wasted. So why not automate such processes and make life easier for developers and technical consultants?

Initially, the script validates if the WM and Portal services are running before dropping and restoring the database from backup.

Then the script drops the database, restores from backup.

In the end, the script catches any errors and report to the user.

You can even go a step ahead with this script and add the stop/start MOCA and Portal services functionality to fully automate it. This script took me less than a day to create from start to end, but now saves developers a lot of time during their testing. Hopefully, I have intrigued you enough to do something similar.

--

--

--

I am an experienced IT Consultant who has a knack to solve complex problems. Want to connect? Reach out to me on: http://www.linkedin.com/in/ali-ahmed-jdawms

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

A note on the problem of not being able to clone in GitLab

Some good Java libraries

How to Download and Install Pycharm on Linux(Ubuntu 18) with GUI

Learn Java With Me: Day 2

Trying to set up a F@#% ELK stack

Running Drupal’s PHPUnit test suites on DDEV

Thumbnail

Day 6— Learning everyday

An illustration of a woman reading a book

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Ali Ahmed

Ali Ahmed

I am an experienced IT Consultant who has a knack to solve complex problems. Want to connect? Reach out to me on: http://www.linkedin.com/in/ali-ahmed-jdawms

More from Medium

OCI Data Integration, REST APIs and and sFTP

How to check the apache httpd processes running in Linux

How To Install ELK Stack On Windows Server 2019 With Let’s Encrypt SSL

Standards vs Standardization in DevOps: The fine line between streamlining processes and hindering…

Standards vs Standardization in DevOps: The fine line between streamlining processes and hindering innovation