Claude Code x SteamNative MCP Server
21:28

Claude Code x SteamNative MCP Server

StreamNative 20.03.2026 61 просмотров 1 лайков

Machine-readable: Markdown · JSON API · Site index

Поделиться Telegram VK Бот
Транскрипт Скачать .md
Анализ с AI
Описание видео
In this demo, see how Claude Code—integrated with the StreamNative Model Context Protocol (MCP) server and the snctl CLI—can rapidly diagnose and resolve a critical data pipeline failure in real time. A routine schema update to a “food orders” topic introduces a breaking change that causes the backend order processing function to crash, creating a backlog and halting order fulfillment during peak hours. Using natural language prompts, Claude quickly identifies the root cause from system logs, updates the Java code to support the new schema, rebuilds and deploys the fix, and restores the pipeline to a healthy state. Watch how AI can streamline troubleshooting, automate code fixes, and accelerate recovery for production data systems.

Оглавление (5 сегментов)

Segment 1 (00:00 - 05:00)

That's great. — All right. Yeah. Thanks everyone for joining. Uh I want to start uh by asking like how many of you have been paged by the business on a Friday evening. Maybe you're out doing enjoying your weekend. Uh open up your dashboards and seen a function that's sitting at or your application you're consuming Pulsar application that's sitting at zero. Nothing's running. There's multiple restarts. Clearly it's broken. But when you go to find out why the exception that explains it is buried three pages deep in a wall of logs. There's one exception. That's it. of the dashboard tells you something that's wrong, but you just but it doesn't tell you why. So, that's the scenario I want to walk through today. This hypothetical scenario where uh I'll play the role two parts. The first one is you're a back-end developer. So, before you leave for a long weekend, you do a quick end of day check. Everything looks healthy. So, you head out around 5:00. uh on your way home uh at 5 5:45 a mobile app team uh a completely different team that's a producer on that topic pushes a change that they think is a routine uh schema update um they think it's a compatible it's a forward compatible change u but quickly it's a breaking change right by 5:46 orders have silently stopped flowing uh by 6:00 it's been elevated to say hey you know what's going on it's the dinner rush uh you know something's going on and the Slack message comes then for notifying you on your phone that something's going on from the team but you know asking you what's going wrong like hey my code hasn't changed in 3 weeks I don't know what's going on so to diagnose this we're going to give uh Claude two powerful tools the first is the stream native MCP server that coin talked about uh it exposes the full Pulsar admin API directly to Claude code so Claude can quickly query topic stats inspect schemas check function status and manage namespace policies through natural language without us having to write a single line of code not have to memorize what's the syntax for this admin command and how do I change that uh etc. It'll do it all for you. And the second is the SN cuddle tool which is the stream uh stream native command line interface tool uh which we use for one or two operations that fall outside of the MCP service uh specifically uploading compiled packages to the registry. That's something MCP does not do yet. And between these two tool to tools, Claude could go from I have no idea what's wrong to root cause uh confirmed and actually I'll even show you solving the problem uh in just a few uh prompts. Let's go ahead and get to it without further uh ado. Go ahead and move it here. So uh you know here's your pipeline you've had built for weeks. The system you've built uh and has been running for months. It's a food ordering backend. Very simple. It's a pretty simple data flow. On the left you have a food source connector uh generates food orders. uh every 3 seconds. This obviously simulates real food orders coming in uh from different sales channels, online mobile apps, kiosk, self- service kiosk inside the restaurant itself. Uh Door Dash, Uber Eatats, etc. piping in all this information, but it's a source where data comes in and drops it into a food orders topic. Um messages are Abro serialized uh using a specific schema, which I'll show you in a minute. Uh here shown down here, this V1 food order, it's a very flat structure. There's an order ID, customer name, an item, a quantity and price, uh, and a corresponding time stamp for when it got entered into the system. And then on the right is an order processing order processor function. This is what you as a backend developer responsible for. Uh, it reads those messages off the food orders topic, does some calculations, calculates maybe, you know, a total cost, does some tax on it, maybe validates credit card, etc. you can, you know, whatever sort of processing you need to do with these orders as they come in. Uh, and it writes a confirmation string to the order confirmations topic to say, hey, this is a, you know, this is a valid order. Go ahead and process it or maybe they get rejected and it does get into that process. So, it acts as a gate, a data validation thing. Again, very simple for that. And the green bar at the bottom just kind of shows you, you know, this is what you normally see. You see about, you know, three messages uh or one message every 3 seconds roughly coming in and out. There's no backlog, there's no exception, everything is healthy and running. Uh, also notice that here on the in the upper top corner, the schema compatibility is set to full and auto update is off. So, you set these yourself a few weeks ago to protect against exactly this kind of thing that's going to happen. Uh, auto update means consumer subscriptions are pinned to the schema version to register with and that choice is about to become very, very relevant very, very quickly. So, um, let's just go ahead and now I'm going to switch screens. Let's say it's the end of the day. You're the developer, right? It's 55 5:00 p. m. You're checking out for long weekend. Uh, again, the pipelines been running for 3 weeks, but before you head out, you want to do a quick sanity check. So, you go, you look at all your different This is the source coming in. Messages are coming in just great. You go check your function. This is your food order uh function here. You can see you have everything looks clean. I've got one instance running out of one topics are consuming. The messages processed equals the message received. There's no

Segment 2 (05:00 - 10:00)

backlog. Every message is coming in is being processed very cleanly. There's no exceptions, no restarts, no anything. Everything looks very good. Again, no exceptions whatsoever. Quickly, you want to peek in the logs just to keep an eye on what's going on, right? So, every uh you know, everything coming in uh looks fine. You should see something like uh you know, like the following different orders being processed. receive food orders here. Orders getting processed. So everything is good. Just info warnings or info messages rather. Everything's working just great. Uh you know occasionally the messages coming in, right? So this is good. Nothing but successfully processing uh processed entries. Every order that comes in gets processed. A confirmation is written to the topics. Right? You see topics are coming out. Order confirmations are getting topic messages are coming in and out. No problem. Uh there's no lines again showing errors or warnings or log or any issues in the logs whatsoever. So it's great. You get ready to go home uh head out for the night. You know, everything is h you know, healthy. It's a it's a sanity check, right? So you're good. Your job is done. Now switching roles for a minute. See if I can get back control of the screen. One second. There we go. Now switching teams. So now there's another team, a mobile app team that uh missed their deadline. They're rushing to get a change in real quick. They've been uh you know, it's around 5:45 in the afternoon now. They're anxious to get out the door as well. It's a Friday. They want to get home. They got lives to get back to. Uh they've been working on a new feature adding uh combo meal support where single order can include multiple items. Uh they've gone through the code review process. The code everything the build is green. Uh it's time for them to do what they think is a routine deployment, right? And they're going to and you know change the code. So just quickly show you this is you know they had this food order source. This is what they originally had here. You can see it's producing food order items. It's generating some random values of what the items are and the prices. Uh and it's always just generating, you know, food orders over and over again and publishing those out to the topic. If you look at that schema type, as we talked about before, nothing new here than what I showed you before. Order ID, customer name, quantity, price, and order time stamp. and they're generating these events. Our code, the order processing function is accepting these food orders and that's fine and it's doing some confirmations on it right now. Just print out the details, sum up the total cost, etc. Record some metrics related to that. But again, you could do more complex things. Validation, credit card validation, customer loyalty point adds on, whatever you wanted to do here. But just to show you that this is dependent on the food order type. Now what the mobile team is going to do is like hey we have to change this new schema type right so they are going to introduce a breaking change they have you know they should have you know would be backward compatible in normal circumstances and they're operating under that assumption but in our case we have full compatibility which is going to be why it breaks but nonetheless they've changed some field names they've removed items item to replace it with items as a list they've removed the price field and put it inside this items as Well, they've changed customer name to custom customer, right? So, they've modified this quite a bit. They've added some special instructions things as well, which is a reasonable uh schema changes for this type of upgrade. They've added a new order item type with item name and quantity customizations inside of it as well. So, they're going to uh update this. They supported the UI to take all these things to the fields and now they want to publish it out. And you can see that they're using that for their new source is going to produce messages of this type, right? So, they're happy with this. Everything's ready to go. Uh, those types of things. They're going to go ahead and deploy it. Uh, deploy it here at 545. So, hopefully I can I kept this in here. So, they're going to go ahead and deploy it. This is just a CLI script that's going to do a release upgrading everything there. Updating uh, you know, going to make it so it deploys in. They force it to do uh, get deployed here. walking through that scenario, right? So everything is fine, right? Go ahead and deploy this thing and then they'll I'll show you I'll start get to the MCP stuff first over this works. So this is going to compile everything, upload everything. Again, this is all through a script. So nothing MCPish here yet deploying it as me. That's great. Now I'm going to go into plaud and I'm going to ask it. This is where the first thing we do and say, "Okay, I've deployed it. Can you check the status of this food order service connector I just deployed? Show me the first five messages I want to look at to make sure it's following the new schema I've changed here as well. You can see it went and checked the number of instances running. " It says, "Hey, it's running. Everything is working. The status is ready here. " It's

Segment 3 (10:00 - 15:00)

going to hear. Okay, no problem. It recovers here in a second. Hopefully, it's using the MCP server. Just trying to get some information. Uh redo the lookup. There we go. So it recovered it. It was going to the wrong scheme at first, but here's what it's found. Right. The source connector and this is the MCP server itself. We just use M the MCP server from streaming native can now validate for the mobile team that their application got is running. Uh everything is you know connectors running but shows received yet. So we can verify everything is running. Let's go ahead and uh there we go. Nothing but live demos. Everything fails. We have it MCP server to diagnose it on the fly. Um can you check this again? Everything's got deployed and running. Everything's up there. Let's see if it's finally generating some uh messages. I want to see some messages coming in from here. There we go. Okay. So, it started to process some messages now. It's sending everything out. Uh everything is working to go. There's starting to be some backlog on the messengers going on here. Right. So the source it's notice that the source is actually producing. Uh it's already identified that there's uh no active consumers and the connector has been restarted. So good to go. Right. So it walks away. It says hey everything's running. I'm producing messages. Check the messages. Uh show me the messages again. So from its perspective, it's a successful deployment, right? They've deployed the application. Uh it's running. It's generating messages. Hopefully, it's going to generate some messages here in more time. It's why you never do a live demo. No matter how many times you test it, it always fails right when you're on screen. So there we go. Just thinking about it some more. It's going to consume everything. It's going to revert to SN cuddle because MCP server is having some issues connecting to the broker, but that's okay. That's a good fallback. Uh, now we're going to peak some messages. See what's going on. There we go. Now it's starting a consumer. It's getting some messages coming in and it should des serialize those from Avro for you automatically. Right. And then you should be good to go. All right. While this thing is deploying, get some messages here. There we go. So, you can see that is now using the new food order 2. You're producing some messages, some things, people are ordering some different things. uh adding special instructions multiple items so it's aligned with that. Uh so you know they go home everything is fine uh right there's no problem there. So problem is what they've not realized is that this v2 schema that they push is a breaking change relative to v1. when these first v2 messages arrive uh on the consumer and try to des serialize them. It's going to fail with a serialization exception, right? The function is going to crash, it's going to try and restart and it's going to crash again enter a crash loop back off death spiral, right? It's not going to be able to restart for multiple reasons, right? So the So what you're going to see in real life is you're going to be sitting there at the soccer field or whoever on your way home and get a Slack notification from the operations team saying, "Hey, orders have completely stopped. What's going on with your function? We're at a dinner rush. Customers are complaining. We're not able to fulfill orders. Our business has come to a complete halt. " Uh what we're going to walk you through is because you theoretically you could do this because Claude has a desktop application. You could diagnose it from while you're there at your kids's soccer game uh or driving home or sitting on the subway whatever and type in and you know ask it a prompt like what's going on my order processor is here backlog's growing what's going on uh and it will use MCP server which you plugged in and basically say hey this is the problem right and you can get into how do I fix it uh from that code process right so it's all one very clean process and we'll go through this uh there right So, let's go ahead and go over to the console now. And you're going to, you know, you get back and you'd say what's going on with my order processor function. Right now, you diagnosed the problem. You could ask it here. You could theoretically do this on your phone app as well. Again, I'm I can't demo on a webinar a phone app interface, but it's

Segment 4 (15:00 - 20:00)

clawed, so you can ask it the same things, right? Uh it's basically telling you what's going on. It's a crash loop like I started. Everything is crashing. It's restarted multiple times. It's even a diagnosis successfully that this is a schema mismatch, right? And it's pinned to that. So it's nothing that it's the backlog is growing and this is why everything is going down, right? So it's going to tell you that's it. You know, everything is going on. Uh this failure note is generally hard to understand. And so you just say, okay, I want to next thing you tell Claude is, you know, hey, what's going on here, right? You want to say, I want to fix this function. It's already said, hey, function for you using this the schema. Uh, go ahead and make the fix. Right? So, it's going to go ahead read your code because I'm in the directory with the codebase. It can find that new version. It says, hey, I found this, you know, v2 version here. Now, I have everything I need. And it's going to make a the code is going to make the ch uh cloud recommended changes for you. Uh everything you would basically do yourself, right? It's going to say I've updated the new schema. I've done I update the message signature for the API. I do some changes now to iterate through the items instead of take the one item in itself. Update my output status a little bit as well. I change the call to get customer from customer name to get customer. Uh remove all those items as well. So basically reads your code well and says I know what to do. You want me to make this changes to the function? You say yep. Go ahead and make that for me if you don't mind. And it's going to go ahead and do that. Next steps to deploy it. Right. So it's told you what it's going to do and you say, "Yep, could you please upload this function? " So this is where it has to use the SNL cuddle tool uh to do that. But it will do the build locally, right? Maven clean package build everything build the new artifacts uh first and then it's going to like it says upload the new jar file with cuddle update the function via mcp and that'll be it. So it's going to go ahead and do this for you automatically. Again you can be standing somewhere say with your laptop out of on the subway getting all this stuff done while it does all this information for you very quickly. Gives you successful status updates. Yep. I built the artifact. No problem. I was able to upload it successfully. I'm going to reenable the schema to auto update so I can uh get around the lock schema. Uh then update the function. All these sorts of things here. Come on. That's all right. It's going to adjust itself here. It's going to update it. Going to set auto act to true. So we need that. There we go. And now it's deployed it, but it's not started running yet. It's giving you feedback on the cluster's uh created state. It's spinning up. Patience. It's going to wait patiently for it to come up. And there it was. Now it's verified that it is up and running again. And it gives you the function is healthy. It's already consumed all the backlog messages. There's no errors. Schema fits is working. So it's done. The backlog is drained and the pipe load is fixing again. Right? So uh with using claude and two tools MCP and essence cuddle uh you were able to basically diagnose the problem fix the code for you and redeploy it uh with a very short uh amount of time right so fantastic go back here look at this function again can now see everything is running it's reprocessing things you can see where it dropped off for a second and now it's recovered you can go back in the logs and see we're back to normal There might have been an error buried. There's one error message in here somewhere when it's had the schema change, but it you can see how hard it would be to diagnose this in the UI, right? That there was right of all these messages, this was the one error that was a breaking change. So, this is very this is the proverbial needle in the haststack. MCP server helps you find that very quickly. Uh it doesn't repeat. It does one time error. So, it's very uh clever and it recovered. So, that's great. So you went from this scenario right where you were operations got alerted everything has stopped you're losing revenue it's quantifiable nothing has changed you don't know the root cause to you know and having everything running to things crashing uh and you don't know why to go basically having with one prompt I was

Segment 5 (20:00 - 21:00)

able to identify the entire root cause right that's how powerful the MCP server is powered with claude it went and query the function status It got the top topic stats and realized, hey, something is down. It saw message backlog was climbing. It validated, went to the schema registry to figure out the schema incompatibility issues. It found the schema difference uh you know which was required. It was a breaking change. It was able to successfully navigate the namespace policies to allow it to deploy a function because you had to change that setting. If you tried to do it manually without changing that setting, it would fail. There'd be errors with that. Um and then it was able to confirm that the root cause uh very easily uh and then was able to fix it. Right? So MCP identified the problem, made all the edits for you, build the built the code for you, redeployed it, and everything works. And now be going from a backlog to everything working. Uh, and all you had to do is MCP server SNL cuddle uh, and cloud code and skip all the gripping of the logs, checking your dashboards, calling the mobile app team to figure out who made a change and where, you know, who broke what, uh, to having everything up and working. So, you know, that's it. One prompt to diagnose, u, one session to fix. Hopefully, uh, thanks everyone. Hopefully, uh, everybody enjoyed that. And if I'm happy to take any questions uh in the chat before I hand it back over to Kumen to wrap up the

Другие видео автора — StreamNative

Ctrl+V

Экстракт Знаний в Telegram

Экстракты и дистилляты из лучших YouTube-каналов — сразу после публикации.

Подписаться

Дайджест Экстрактов

Лучшие методички за неделю — каждый понедельник