Learning Library

← Back to Library

Hybrid Cloud Modernization: UI Migration

Key Points

  • Sai Venom, an IBM Developer Advocate, introduces Part 2 of the hybrid‑cloud architecture series, which focuses on modernizing legacy monolithic applications.
  • The sample “stock‑trader” app is described as a Java‑EE monolith using a service‑oriented design with a UI front‑end, portfolio service, loyalty service, message queue, and an on‑premises database that pulls stock data from an external REST API.
  • As the fictional company expands globally, users experience increased latency, prompting architects to consider breaking the monolith and leveraging public‑cloud resources.
  • The first step in deconstruction is to identify the component to extract; the UI (including its backend logic) is chosen because it can be replicated in multiple geographic locations without tightly coupling to other services.
  • Moving the UI to the cloud allows a small, low‑risk start to the migration and sets the foundation for further incremental refactoring of the monolith.

Full Transcript

# Hybrid Cloud Modernization: UI Migration **Source:** [https://www.youtube.com/watch?v=iZR0TJPmj_U](https://www.youtube.com/watch?v=iZR0TJPmj_U) **Duration:** 00:11:22 ## Summary - Sai Venom, an IBM Developer Advocate, introduces Part 2 of the hybrid‑cloud architecture series, which focuses on modernizing legacy monolithic applications. - The sample “stock‑trader” app is described as a Java‑EE monolith using a service‑oriented design with a UI front‑end, portfolio service, loyalty service, message queue, and an on‑premises database that pulls stock data from an external REST API. - As the fictional company expands globally, users experience increased latency, prompting architects to consider breaking the monolith and leveraging public‑cloud resources. - The first step in deconstruction is to identify the component to extract; the UI (including its backend logic) is chosen because it can be replicated in multiple geographic locations without tightly coupling to other services. - Moving the UI to the cloud allows a small, low‑risk start to the migration and sets the foundation for further incremental refactoring of the monolith. ## Sections - [00:00:00](https://www.youtube.com/watch?v=iZR0TJPmj_U&t=0s) **Legacy Monolith Overview for Modernization** - Sai Venom outlines the on‑prem, Java‑EE based Stock Trader monolith architecture—including UI, external API calls, on‑prem database, loyalty service, and message queue—as the foundation for hybrid‑cloud modernization strategies. ## Full Transcript
0:00hi everyone my name is sai venom and I'm 0:02a developer advocate with IBM today 0:05we're gonna start with part two of the 0:07hybrid cloud architecture series 0:08strategies to modernize legacy or 0:11monolithic applications in part one of 0:13the series we talked about hybrid cloud 0:15connectivity and we used a similar 0:17sample application stock trader this 0:20time around we're taking a step back in 0:22time to when stock trader was still a 0:24monolithic application running on Prem 0:26on VMs but the architecture is mostly 0:30the same it's using an SOA or 0:32service-oriented architecture it's 0:34actually a precursor to micro services 0:36based architectures so very simply 0:38within the monolith itself you can 0:40imagine this is something like Java EE 0:42based application we've got the 0:44front-end the UI application that works 0:46with the portfolio basically manages 0:48your different portfolios and keeps 0:51track of the stock prices so to get 0:54those stock prices it actually hits 0:55another service which goes out to the 0:58investors exchange public rest API 1:01endpoint all of that data and the 1:04portfolio information is stored in an 1:05on-prem database and then we've also got 1:09a couple of services here so we've got 1:11the loyalty service which keeps track of 1:13you know loyalty with specific stocks 1:15that you might have in your portfolio 1:16and it notifies users as well on that 1:19loyalty whenever it changes like taken 1:21advantage of a message queue service 1:22which notifies the user through 1:25something like email so that's a very 1:27simple overview of the architecture and 1:29this is something that's worked quite 1:31well for for that fictional company 1:33stock trader it's worked well for them 1:36and they've seen growth and expanded and 1:38potentially you know maybe they become 1:40an international company so what they've 1:43noticed is certain users that are using 1:44this application are seeing increased 1:47latency so the architects on the stock 1:50trader side decided you know it's time 1:52to get rid of the monolith it's time to 1:53start deconstructing it and stick taking 1:56advantage of the public cloud so let's 1:59talk about how they can do that the 2:00first step of the process to 2:02deconstructing it's going to be to 2:04identify the piece that we want to break 2:10out of the monolith so a couple ideas we 2:13can 2:13out here for example we don't want to 2:15move the portfolio service to the public 2:17cloud because you know it's tied so 2:19deeply to the other services fact is 2:21actually also talking to the loyalty 2:23service so you know if we move that 2:25portion there'd be a lot of unnecessary 2:27Network hops probably making the issue 2:30even worse for our users put the best 2:33portion to break out it's gonna be the 2:35UI or the front end that allows us to 2:37put the front end in multiple geographic 2:39locations just just a quick 2:42clarification that UI is not only a 2:44front-end component but the backend for 2:46that front end which kind of makes calls 2:48to all of these other back-end services 2:50to render data so yeah so I think UI is 2:54a great piece to start with it's it 2:56allows us to start small and sets us up 2:58for better kind of deconstruction in the 3:01future but okay so the first thing we've 3:03done we've identified the resource the 3:05second thing we want to do is refactor 3:08so we can't simply just move that 3:11portion out of the monolith into the 3:13cloud and and and there's a lot of 3:15reasons for that but the main one being 3:17that communication between these 3:19services doesn't do well on public 3:20Internet it's it's software-based calls 3:22it's based within the SOA architecture 3:25within the Java platform we need to take 3:27advantage of something like rest as 3:29something that performs well over the 3:30public Internet so first thing we need 3:33to do is create glue code essentially we 3:35need to create endpoints that the UI can 3:39access that portfolio and in addition we 3:41have to expose REST API endpoints on the 3:44portfolio on the loyalty side so the UI 3:46can access it itself this is essentially 3:49what we call glue code because it allows 3:51us to kind of keep that same pathway of 3:54communication between services but we 3:56enable it to work over the public 3:58Internet so that's that second step we 4:00refactor it and that once we've done 4:03that we can actually go ahead and deploy 4:05that into the public cloud so third step 4:09gonna be deploy so we take that UI and 4:15we put it in the public cloud and 4:17basically what we need to do is expose a 4:20point for access of it and you know 4:23we've got the same thing over here where 4:25the UI is exposed from the monolith 4:27the legacy API flow you know when a user 4:30traditionally hits this application 4:31comes from their browsers hits that 4:34model at the application this continues 4:37to work great you know we've we've 4:38verified it that the glue code that we 4:40put in place isn't breaking anything and 4:43then here's the here's the important 4:44step we want to make sure that that new 4:47API flow the one that's directly 4:49accessing the UI in the public cloud 4:50continues to work now a good strategy 4:53here is to initially maybe do 10% of 4:56your user traffic goes to the public 4:57cloud UI whereas the remaining percent 4:59goes to the on Prem allows you to kind 5:01of make sure catch issues in production 5:04make sure a lot of your users aren't 5:05affected eventually you catch all the 5:08errors you make sure the public cloud is 5:09error-free that's when you deprecated 5:12the older UI portion you know just get 5:15rid of the whole thing and take 5:17advantage of the UI on the public cloud 5:19side so the last step is repeat once 5:27you've successfully broken out a part of 5:30the monolith and into the public cloud 5:32we can start thinking about next things 5:34that we want to break out so so far 5:38we've removed the UI to the public cloud 5:40and let's say that things are going 5:42great you know all the international 5:44users are getting better response times 5:45when they're accessing the applications 5:47things are going well and and we may not 5:50have a need to further our 5:52deconstruction of the monolith I think 5:54this is something very important to 5:55think about doing this refactor is a 5:58ssin and and and converting services 6:00into micro services it's a expensive 6:03approach and until you feel the need to 6:04do so it might make sense to keep your 6:07monolith as is but regardless let's say 6:10that this application is continuing to 6:12grow and we have a new bottleneck and 6:15that's going to be the stock price so 6:17with all of these portfolios and all of 6:19these different users using it you know 6:21we don't need to scale out these other 6:23portions as much but maybe the stock 6:25price you know we're hitting that so 6:27many times we're using the investors 6:29exchange to get those stock prices and 6:31we want to scale that out unfortunately 6:33with our monolithic architecture if we 6:35want to scale stock price up we have to 6:37scale everything out and then on Prem we 6:40don't have enough resources to do 6:41so our users are getting bad experiences 6:44again as our user base grows and we want 6:47to move that stock price to take 6:48advantage of the public cloud 6:50scalability but let's say that we don't 6:53have time right so users are already 6:55having a bad experience we don't have 6:57time to refactor that stock price out 6:59and create a micro service that's where 7:01we can take advantage of lift and shift 7:03essentially take this entire monolith 7:06and move it over to the public cloud so 7:10you can imagine you know let's take that 7:12entire monolith a stock trader 7:15but you know although we have the whole 7:17portion here the piece that we really 7:19want to scale out is a stock price so 7:22although this is the entire monolith we 7:26want to only use the getting the stock 7:28price portion so inside here you know we 7:31have a smaller portion to get stock 7:35prices so now that we've effectively 7:38kind of lifted and shifted the entire 7:40monolith out to the public cloud we can 7:42start taking advantage of scalability we 7:46can maybe scale it out eight times as an 7:48example taken advantage of public cloud 7:50resources now I understand that this is 7:52not the best approach but with the 7:55limitations since we needed to go to 7:56market by container izing the monolith 7:58and moving it to the public cloud we can 8:01really start taking advantage of the 8:02resources there and then start thinking 8:04about the next step of our kind of 8:07modernization process one thing I want 8:10to mention here 8:11so my next line here innovate and 8:14improve you always want to find ways to 8:16improve your application well we've 8:18noticed here is that you know the UI is 8:20in the public cloud but kind of the 8:22communication channel for it essentially 8:24the UI is always kind of going back to 8:27the monolith to take advantage of the 8:30portfolio loyalty and whatever other 8:33services might be there right so the 8:36first thing we notice is that the UI 8:38hits the portfolio which then has to 8:41come back out here to hit the the 8:44monolith in the public cloud to get the 8:45stock prices that in turn goes back to 8:48the portfolio and then back out to the 8:49UI that's a lot of unnecessary Network 8:52hops we can always innovate and improve 8:55throughout this process of modernization 8:57why don't we get the stock prices 9:00directly in the UI and then offload all 9:03of the kind of database storage kind of 9:05activities asynchronously 9:07well that's one easy way to innovate and 9:10improve on our existing architecture 9:12let's refactor these applications of the 9:14UI is talking directly to the monolith 9:17in the public cloud to get those stock 9:19prices so that's one example of kind of 9:22always innovating and always improving 9:24when doing this kind of migration 9:26another thing so we talked about how 9:29using the whole monolith in the public 9:32cloud it's not the best approach but a 9:34lot of speed with go to market let's 9:37take advantage of some new technology 9:39say server lists for example so we want 9:43to factor out this one portion right 9:45here and take advantage as serverless 9:48capabilities to get stock prices so by 9:51using the server list platform on a 9:53cloud we can then take functions as a 9:56service which in turn goes and hits the 10:00investors exchange public api's so we'll 10:05take advantage of the IE acts public api 10:07s-- using server lists and then what we 10:09want to do again so same four-step 10:12process we've identified the piece get 10:14we've refactored it into a service 10:16action we've deployed it into production 10:18and then what we want to do is test it 10:20there right so legacy and new API flows 10:24so again this is the legacy flow and 10:27then the new API flow it's gonna hit 10:29that circle as action directly once we 10:32verified that this flow works well we 10:35can entirely cut out that monolithic 10:37architecture that we pulled into the 10:38public cloud first simply just stock 10:41prices so again we've kind of talked 10:44about how we take advantage of these 10:47four step process to break out 10:49individual portions out of a monolithic 10:51architecture and move it into a public 10:53cloud these three things deconstruction 10:56of monoliths lifting and shifting so 10:58it's always innovating and improving 10:59we're gonna set you up for success when 11:02you're monitoring modernizing your 11:03monolithic applications as always we 11:06check for feedback so drop a comment 11:07below in the neck 11:09part of the hybrid cloud architecture 11:10series we'll be talking about security 11:12so definitely subscribe and stay tuned 11:14if you want more information about what 11:16we talked about today check the related 11:18information for links below thank you