Join us on December 11 with Jeff Fritz for the next episode of Rockin' The Code World with dotNetDave - a weekly show to learn & live Q&A focused on .NET and other programming technologies.
Featuring Guest: Jeff Fritz (https://www.linkedin.com/in/jeffreytfritz/)
He is a Twitch and YouTube partner as well as the founder of the Live Coders stream team and a principal program manager in Microsoft's Developer Division on the .NET Community Team where he leads the organization of the online components of Microsoft's top developer events. The Live Coders is a community of 200 broadcasters making technical content available for free on Twitch through programming, game development, and fun interactions with chat. You can catch Jeff writing .NET Code on his video stream called ‘Fritz and Friends' at twitch.tv/csharpfritz
C# Corner - Community of Software and Data Developers
https://www.c-sharpcorner.com
#CSharpCorner #rockinthecodeworls #live #dotnet
Show More Show Less View Video Transcript
0:00
Thank you
0:29
Thank you
0:59
Thank you
1:29
Thank you
1:59
welcome geeks to another exciting episode of uh rocking the cold world with donna dave i almost
2:10
forgot the name of the show it's been so long since we've done a show in the last few weeks
2:14
i'm glad you're all back i hope you had enjoyed some of the time off that we were taking because
2:20
of the holidays and uh all that kind of stuff my birthday was a couple weeks ago and um so
2:27
welcome everybody back. Welcome, Paul. Welcome, Ganesh. I'm glad you're all here. Make sure you
2:33
get your questions ready because my very special guest today is Jeff Fritz from Microsoft. You
2:39
probably all heard about him. He's got a popular show all the time on the internet. He just came
2:45
back from speaking in Las Vegas. So it's great to have somebody back on the show. So I'm looking
2:51
forward to talking to Jeff in just a few minutes. I do kind of want to start out
3:01
I woke up this morning and found out that we had a devastating storm in America in the state of
3:08
Kentucky last night. And they're guessing that there's going to be probably 100 or more people
3:14
who have died because of that tornado storm that hit that state
3:19
It was like 250 miles long of devastating tornadoes all last night
3:25
So all my thoughts and prayers go out to everybody in that area
3:29
especially the families that have to deal with the aftermath of this. So send your thoughts and prayers to them
3:35
They're going to need help. And an Amazon warehouse got knocked offline
3:43
and parts of it was destroyed. So I'm sure that's going to impact
3:47
some of the holiday gifts people are ordering. But just remember, it's about the people
3:54
And so my thoughts go to all of the hundreds of families
3:58
who've been impacted by this devastating event. So I also want to say real quick
4:04
that I owe somebody some books in India. They're right over there
4:09
They're going out next week. So don't worry. I'm really, really sorry it's taken me so long
4:15
I just haven't been to the post office. But it's happening next week because I have some other things I need to ship to my grandkids and things like that
4:23
So I have to go to the post office. I don't like going because I don't like waiting in line
4:27
So that'll happen early next week. So don't worry. It's coming. And I'll throw in some goodies in there for you because you've waited so long for the books that I gave away on my anniversary show
4:40
Okay. Okay, so again, Jeff Fritz, Principal Program Manager for the .NET community is on today
4:49
So make sure you get your questions ready, especially about Blazor. That's what we're going to be talking about today
4:54
We're going to be talking about .NET 6 and Blazor with Azure Static Websites
4:59
And it'll be great to catch up with Jeff because I haven't talked to him in a year. Also, right now, I am picking sessions for the .NET virtual conference
5:09
That's happening January 24th through the 26th next month. It's only 40 some days away
5:16
So get ready. I'm almost to 100 sessions and I'm picking them right now
5:22
And I don't know if you noticed the tweet, but I have a newfound respect for people like Simon, who produces my show, that has to pick the sessions for a conference
5:32
Because it's pretty a daunting experience. I'm trying to pick the right ones
5:39
Which ones will people be interested in? Which ones do they need to be interested in
5:44
So I'm taking my time, but the CFP closes very soon on the 20th
5:51
So if you want to speak at the conference, please, please, please submit your papers
5:57
Simon, can you put up the link? I forgot to put up the link on the slide
6:01
So please submit your papers. There's only a handful of days left to do that
6:06
And if you're going to submit your papers, make sure you do more than two sentences of description
6:13
That's another thing I'm finding out that you speakers don't put enough information about your session
6:20
And it's hard for me to pick like two sentences. So please put a little bit more in there
6:27
It really helped me to pick the best sessions for the viewers for next month
6:33
Okay. So don't forget about that. Also, I'm wearing my .NET Run shirt
6:39
It finally came in, and I go encourage you all, if you can, to go buy one
6:45
It all profits Black Girls Code. So you go to that link there
6:49
Simon will put it up in the chat. And go buy your T-shirt now
6:55
I was thinking about this morning when I was getting dressed. If anybody from that organization, I know Scott Hanselman doesn't watch this show
7:04
but he's the one that was promoting it a lot. If any of you, if you put out a hat, I would love one
7:12
I would love a .NET Run hat. That would be awesome to wear on my shows
7:16
So do a hat, a nice one, not a trucker cap. Okay, so go help that
7:24
We need to encourage the kids to get you know excited about technology and programming And so this is one of the organizations in America that does that
7:36
So please, please help them out, especially during this holiday season. I have a new article out right now
7:44
How do you link? I asked all of you that follow me on Twitter what kind of article you want me to write
7:50
and what one was about performance. And so in this article, I'm kind of highlighting three different ways I see people write link queries in .NET
8:04
And there's only one way that's the most performant. So make sure you check out the article because maybe you've been doing this wrong
8:14
And you can go fix your code on Monday, I guess. But it's there
8:20
And I hope you check it out. So I thought I had a slide about this
8:30
but I'm getting ready for the next release of my open source projects and NuGet packages right now
8:37
I did final benchmark tests last night, which take a really long time to run
8:42
Just one of my benchmark test executables ran for almost 12 hours just to get one done
8:50
So SparGene is coming, a new version of SparGene is officially being released at the beginning of the month. I have
8:57
an article all lined up to be available as soon as that's released. And this week, you know
9:06
I don't know if you've been following my performance stuff or reading my articles or
9:10
my performance book, but if you read my performance book, you know, the best way to
9:15
iterate through a collection is by using four, right? Not four each. Four is the most performant
9:24
way of iterating through a collection. I found a faster way of four. I'm talking like almost
9:31
double the performance of four. I just happened to pawn this past week and it's going in its bar
9:38
gene. So it's going to make going through collections a lot faster as soon as the new
9:45
release of spar gene is out. So I'll help you check that out. And with that, I'd like to bring
9:50
on my guest. Jeff Fritz is a Twitch and YouTube partner, as well as a founder of Live CoderStream
9:57
team and principal program manager at Microsoft's developer division on the .NET community team
10:04
where he leads organization and online components of Microsoft Top Developer Events
10:11
The Live Coders is a community of 200 broadcasters making technical content available for free on Twitch
10:17
through programming, game development, fun air actions, and chat. You can catch Jeff writing .NET Code all week long
10:26
on his video stream called Fritz and Friends. And Simon can put up the link
10:32
Welcome, Jeff. Hey, there we are. How you doing there, Dave? Good to see you
10:38
Good to see you, too. How you doing? Not bad. It's good to finally be in December and see the light at the end of the tunnel
10:46
And it's January 1st. It's the year end. We can unwind a little bit as we get into the December holidays
10:56
I've got a couple weeks off schedule for the end of the year, and I'm looking forward to it
11:01
Yeah. Well, you deserve it. You spend all week long, I mean, all week, I mean, like almost seven days, you know, being on the thing live and coding and speaking
11:11
You just came back from Nevada speaking at a conference. Yep. And so I'm glad you're here
11:16
I was all worried this morning. Jeff probably woke up this morning going, oh, my God, I got to do another talk after talking all freaking week
11:25
I know you're used to it. Yeah, I'm very used to it
11:29
And honestly, this is what I enjoy doing. Um, so, so to be hanging out with you and certainly talking to all of you out there
11:38
the folks in the chat room, um, answering questions and making sure that you folks are successful
11:44
That's what I live for. That's what I really enjoy doing. Yeah
11:48
That's what I enjoy doing too. Um, I just don't have a gig at Microsoft doing that full time
11:53
I wish I did, but I do want to thank you for, uh, sending me my C-sharp house
11:59
Oh my gosh. Yes. it took a while but i got it so i'm one of the proud owners of the very few c-sharp hats that
12:06
are in existence yeah so i appreciate that i wanted to give a shout out to you i gave a
12:10
shout out to scott who was my last uh um guest scott hunter and uh because it was actually on
12:17
my very first show that i bugged him that i want one and then he contacted you going hey you jeff
12:22
you take care of dave and i finally got the finally got the hat and i wear it like every three shows
12:28
or I, I, I, cause I only have three hats and I need more people. And, but I try to wear that one
12:41
like when Microsoft people come on, you know, cause yeah. So I did want to ask you really quick
12:48
about, we talked about Vegas. I wanted to talk about something that you promoted this week
12:54
really quick before we get into Blazor. And everybody, yep, don't forget to ask Jeff
13:00
post your questions here. We'll ask Jeff while he's here. I wanted to talk about this milestone you hit this week
13:06
Oh, my God. Clip Talk. Yes. Because last year at this time
13:10
you were writing Clip Talk, right? Yeah. So first explain to everybody kind of what Clip Talk is
13:18
So if you're out there, you're watching on Twitch, you of course know what Twitch clips are
13:25
On YouTube there's things like shorts where we want to isolate and deliver a highlight
13:30
of a live stream. And that highlight is going to be about a minute long on Twitch
13:37
The problem on the Twitch platform is it's kind of hard to search through and find clips
13:43
that are going to be interesting for you. That are going to have content that is relevant to
13:48
something that you might be currently watching or something that you're interested in
13:52
And you really have to do it almost on a channel-by-channel basis. So an idea was presented to me that, hey, what if we could have a website
14:02
that allows you to search and discover and find clips easier than on Twitch
14:08
And with my experience, my expertise in building with Blazor, I felt like this was kind of a cool way to showcase Blazor
14:17
build a website that helps Twitch streamers while I'm live on Twitch
14:23
and take advantage of a bunch of Azure technologies. So I set forth building Blazor WebAssembly on an Azure static web app
14:34
and wired up a bunch of databases and search capabilities. And now we have ClipTalk, K-L-I-P-T-O-K.com
14:42
It launched about a year ago now. It was at the end of November 2020
14:47
And we this week we crossed 7 million clips indexed on the platform
14:54
Wow Oh I thought you I thought someone said 10 But even 7 million is Yeah That where we going next Yeah So it is still awesome I mean that it huge
15:05
Really great. The, um, what, what's, uh, really interesting, really compelling about this is that, um, I only loaded information about maybe 10, 15 channels, folks that I knew that I wanted to watch, but the engagement that's happened has come from other
15:24
other streamers other folks that are interested in engaging and getting this type of um indexing
15:31
and ability to to review and find um historical content going and loading some of their friends
15:37
some of their uh friends streamers channels and and see this community start to grow and it's it's
15:45
getting somewhere where we're picking up speed and i'm i'm very excited for what we're going to
15:52
be doing in 2022. So it's a web app right now, but very, very clearly mobile app is on the horizon
16:01
More artificial intelligence features on the horizon. So I'm, I'm really excited about where
16:08
I can take this because it's been, it's been a great learning experience about building
16:12
building with C sharp, building for the web and learning some of these integration points
16:16
with all kinds of different services to make browsing for searching for videos and and how
16:24
you build that social network to interact quickly easily and and as a one-man show so
16:32
really cool stuff because you wrote all that by yourself yes wow yes that's the power of
16:40
building with a fully mature framework, right? And services on, on Azure that have all these
16:48
things that we can light up quickly and, and able to browse around and interact with and see
16:56
yeah, how these pieces fit together. So I see Paul. That just gave me an idea that maybe we should have you on next, next year. And maybe after you
17:08
hit 10 million and kind of just walk everybody through the architecture and how you chose to do
17:14
those kinds of things. I'm sure you do it on your show, but it'd be nice to have a, like a one hour
17:18
summary of how you did all that. Because I think, I mean, me personally, as a seasoned developer
17:24
I guess, you know, it's one thing I don't see enough of is real world examples of here's exactly
17:32
how I did this for this app that you've all heard about, right? It's like, I wish we could hear more
17:39
from Amazon people, how they build that kind of stuff, you know? And, you know, I've had the guy
17:44
on that one of the really smart, credibly smart people on the Netflix team on my show. And, you
17:52
know, I love those kinds of sessions because here's the technology and here's exactly how we used it
17:58
And I think those are really, really valuable to people, especially even me, because I don't know about you, but every time I go to write something, I go into ysis paralysis
18:10
I go, okay, what do I use? There's so many things I could do, but which one do I do
18:17
But I did want to ask you, did you use Cosmos DB for your backend database
18:24
at so i'm actually on my third different database backing clip talk at this point
18:32
um i started with azure table storage i went to my sequel i then looked at cosmos and i ran into a
18:40
couple challenges with migrating to cosmos and and how my data would work over there and the the
18:47
capacity the usage pattern that i was running into with how i was going to work with cosmos
18:52
just wasn't a good fit. So I didn't move forward with Cosmos
18:57
and I actually have moved over and I'm using RavenDB as my storage mechanism for this
19:04
I have three nodes of Raven that are running in the cloud. I've got about 50 gig of data loaded in there
19:11
that you can search through and process. And Raven generates a whole bunch of indexes for me
19:17
and manages all them for me as clips are discovered and loaded into the application
19:24
So ClipTalk wakes up every minute and checks to see if there's new clips from channels
19:30
that it's identified and it's following on Twitch. So as those clips are identified
19:36
it's adding into these indexes and search engine capabilities so that you can find content later
19:45
It's pretty cool stuff. Well, I was asking because, you know, Mark Brown is going to be on the show next weekend
19:51
So great guy. Good friend. And actually, Mark wants to take a look at a little bit of how we've built Clip Talk and wants to see if there is a Cosmos equivalent that can be done
20:04
So I'm actually going to be talking to him over the next week or so about exactly that
20:09
Yeah, I like Mark. And he's going to be coming on. For those of you who want to watch next week, Mark is going to be on talking about all the new features
20:16
from Cosmos DB that just dropped. And I'm really interested in that show
20:21
because I really like Cosmos DB and I want to learn all the new stuff they're working on
20:25
So let's talk about Donut 6, Blazor, and Azure Static Websites. Where do you want to start
20:33
So, I mean, let's kind of walk back as a little bit of transition here
20:38
So Clip Talk is an Azure Static Website. So the idea is Blazor can run as WebAssembly, right
20:46
WebAssembly is that HTML5 technology that runs binary code live in the browser
20:52
And I immediately fell in love with it. I was frustrated and annoyed with chasing JavaScript frameworks since I'm a C-sharp developer
21:02
And I was already so used to building with component-based frameworks like ASP.NET Web Forms
21:09
It, it fit exactly the way that I thought about web applications so well when I looked at Blazor and the ability to say, well, I'm going to build this application like a single page application, like a spa, just like our friends that build with Angular or Vue or React and deploy
21:30
and it's all .NET code front to back by my server side operations
21:35
my client side operations, updating, managing the user interface. So why not build with Blazor
21:43
deploy static HTML, static CSS files, fonts, all that, and put that out on Azure somewhere
21:51
where I don't really need a server, right? It's just a file share
21:56
that's sitting out there effectively. But what Azure Static Websites does is it gives you the ability to partner with that file share that contains your Blazor content, Azure Functions
22:10
So now any business logic, database interactions, these things that you want to have isolated, protected
22:19
running on the server, they're running inside of an Azure Functions app right next to that share that hosts your Blazor application HTML and all that So it this really nice pattern of having my web application
22:36
and my server-side functions that I can build and think about as just little units of HTTP interactions
22:42
that maybe if I need more processing, I can push onto a queue or a service bus
22:48
or query from a database like Cosmos or Azure SQL or whatever it might be
22:54
I use Raven, I mentioned. So having that portability to be able to to push code into Azure functions that are simple and small and isolated and focus on delivering just the web content as C sharp and web content has been a very nice way for me to grow the application
23:17
and things that I've seen and worked on as part of this
23:22
I get staging environments for free. Dave, you've probably seen this and worked with it
23:28
When you're an app service, you have the staging slots. It's like, well, if I want to deploy stuff
23:34
and put it in that staging slot, it's not quite the same as I do
23:38
with my regular continuous integration. I have to point somewhere else and set it up properly
23:44
And what happens when I'm done with that staging slot? I have to clean it up and delete it or something
23:50
And it's a hassle. So what I really like that the Azure Static Websites does is when I set it up, I get a GitHub action script built for me by default
24:06
It comes with a template. So it knows how to deploy immediately to that static website
24:16
But when there's a pull request against my repository, it automatically sets up that staging environment and names it after the pull request
24:26
So now I can work on a feature, put it together in a feature branch and set up the pull request and don't actually accept the pull request
24:39
Just update that feature branch and GitHub will automatically deploy to Azure and set up this staging environment
24:47
each time there's a new update in the pull request and I can see live in exactly the same environment
24:56
that I would have in production, here's what the fix looks like
25:01
I get that smoke test ability. I can share that link with folks on stream
25:06
I can share that with colleagues and we can go take a look and see exactly how it's going to work
25:11
And then when I merged the pull request, it of course merges, redeploys my main branch
25:17
and knocks down that staging environment. I don't have to touch Azure for any of that
25:23
I'll go weeks without touching the Azure portal or the command line or any of that stuff
25:28
because it just manages it for me right from GitHub Actions. Yeah
25:34
Huge. I really enjoyed using that structure to build applications. Yeah, I've heard about that
25:40
but I haven't like talked to somebody one-on-one about that actually did it, right
25:45
And you could go back the other way too, If you put something up and there's a bug in it, you can immediately roll back to the previous version
25:53
Sure. If I submit a rollback in GitHub, if I roll back to a previous build and commit that and send it into my main branch, it'll patch and update that Azure website immediately
26:09
Really, really good stuff. yeah and that that to me is really powerful especially you know because you know i'm working
26:17
on a project that doesn't do anything normal by any stretch and and you know and because it was
26:24
written well over 10 years ago and you know the entire time i've been working on this project
26:29
for this company i've been going oh my gosh why can't we be doing this why can't we be doing that
26:35
is because they haven't kept up with anything in the last 10 years and so now they're kind of
26:39
of in this ketchup not even that they're just kind of frozen they can't do anything i mean
26:46
we can't even move to github you know because everything is so messed up you know when
26:51
i don't want to get into it but you know it's it's it's you know those kind of features like
26:58
you were just talking about that makes you know uh devops but even our lives so much easier because
27:04
you know it's just kind of automatic you can roll back if something happens that's really bad
27:09
and you can stage it, you can play around with it exactly like you were saying before it actually goes live
27:15
and then you can push it live. And yeah, it's pretty powerful stuff
27:19
And I wish more companies would use systems like that, work together like that
27:24
And that's one thing I've always liked about Azure and of course the Microsoft technology
27:30
is that everything just works well together, right? They might not all work perfectly
27:38
because that's just the way it is. But it works a lot better than trying to hodgepodge
27:44
all these different systems. And this one is free and this one's not
27:49
And this one doesn't really talk to this other one. So we got to do all this work to make it talk to each other
27:54
But in Azure land, everything just kind of talks to each other pretty well. So, I mean, I like what you're saying there
28:01
You're absolutely right. There's such an effort to make sure that Visual Studio and .NET and Azure
28:07
all work so well together. And in November, I made a commitment
28:13
to folks on my Twitch channel. I was going to spend the month of November
28:18
learning JavaScript. I'm not a Node developer. I mean, crumbs, right? I'm a C Sharp guy
28:25
And so learning Node for me was something new. All right, let's go in and let's try this out
28:31
And Dave, you're spot on with the, having to hodgepodge things together
28:39
NPM installing things in the Node ecosystem feels like walking through a landmine field
28:47
Like there's some things that work very well with others. And as you bring these things in and you go install
28:55
it's going to tell you immediately, well, here's some security warnings that we may have found on some of these packages you're using
29:03
And the first time I installed and was running and trying to build a node web server, I got eight high security warnings
29:14
Like, what am I supposed to do about that? I just said, give me the web server
29:19
And I've got eight security warnings. Like, okay, update it. Still have eight warnings
29:26
Is that something I want to bet my company on? Like, it's just me
29:31
Am I really going to deploy something? that I know has problems
29:37
that's a management nightmare that I don't want. And having that assurance that my technologies are going to work together
29:45
that I have a team of folks that are going to provide support and update those
29:50
packages for me and patch them and ensure that they support the latest
29:56
technologies, the HTML five, all the things going on, going on the web that are new and interesting
30:03
Well, now we're talking, that's where I want to go. And that's where, yeah, folks who are using Angular, right
30:10
You're going to rely on Google's managing this. If I live within Angular, Google is managing that stuff
30:17
in those Angular packages. So we can be assured it's going to be updated
30:23
because Google is using that. Same thing with React, right? React is going to be patched and updated
30:28
because we know Facebook is using that to build Facebook. There's value in staying within those ecosystems
30:39
And how far outside of them can we go? Are we willing to take that step and figure out
30:47
do we get into this hodgepodge, this Franken app of things that come from places that we don't know
30:55
Yeah. And that's what I've been dealing with, this Frankenstein apps, the last couple jobs I've been working on
31:02
And even the last one, they were using Node against my wishes for the front end
31:07
And I just remember the first time I deleted that folder that website was in and watched all the thousands of files that were being deleted that Node put in there
31:17
I'm going, how can this be fast when there's thousands of files to run this thing
31:24
It's crazy. it's the interpolation of all that content, right? It's interpreted code, interpolation, interpretation
31:34
It's interpreted code that, yeah, you're relying on that Chrome V8 engine
31:39
JavaScript engine to parse and load and get all that stuff cached in memory
31:44
Now, okay, you know what? That's pretty good for a single threaded application
31:50
that is going to deliver that. I'm always a fan of calling out the Tech Empower Benchmarks
31:57
that impartial organization out there that's measuring and showing. Gosh, just like you showed in your blog post there, Dave
32:05
they're showing just how fast some of these frameworks are so that we can make educated decisions
32:10
And I'm not going to lie, it helps encourage some of the folks
32:14
building some of those frameworks to improve their frameworks. but to see just how fast node is or just how fast asp net core or spring or choose your favorite web
32:25
framework ruby on rails well how fast is that and you see well here's what this consulting firm is
32:31
is testing and seeing when they run through all these frameworks and of course if you want to
32:37
build a a web application with c plus plus yes it's screaming fast sure but dave do you do you
32:44
really want to build a web app you want to take that time how much time do you have
32:48
like you're opening yourself up to right stack overflow buffer overflows all that stuff yeah so
32:56
and when you're building a game when you're building low level stuff makes perfect sense
33:01
sure sure but yeah high level web application yeah let's get some of the protection that's
33:07
filled in with some of these other frameworks yeah and and you should always pick the right
33:12
framework for the job, right? I've always believed in that in my career. And whatever that framework
33:18
is, of course, you and I love Microsoft, but whatever it is. But my big thing, it kind of
33:24
goes back to what you were talking about just a minute ago, was staying within the ecosystem
33:29
because that's where I see a lot of companies get into problems because they're trying to save money
33:35
or in the case of my last job, the CTO wakes up one day and doesn't like Microsoft anymore. And
33:40
Now everything's being changed to Java for no reason, you know? And so it's, but even before that
33:47
it was still a hodgepodge of all these things that barely even work together, right
33:52
And as a developer, it's so frustrating to spend a lot of time just dealing with this stuff
33:59
as opposed to writing code or writing business logic, right? And gosh, man, what a segue
34:07
way that takes me right into what i think about with dot net six and how i don't want all that
34:13
ceremony and nonsense around configuring my application and code that i need to maintain
34:21
that's really framework stuff and that's why i've really latched on to and i really enjoyed using
34:27
minimal apis with dot net six and asp course six because i can get right to well let me just map a
34:36
request from, from this folder, from this folder structure. And I'm going to return data in this
34:43
way, or I'm going to post data in this way and handle it and do whatever business processing
34:48
I don't have to worry about setting up configuration and how, how the web server
34:54
needs to run and all these other things. I'm literally four lines into my, my program CS
35:01
file in C sharp with dot net six and I'm I'm writing map get and issuing calls to interact
35:08
with things it's it's been such a enjoyable way to write code to deliver deliver a microservice
35:16
in one file with dot net of course you have a csproj file but a csproj with a program cs
35:23
and I I have a sample that I show that's 20 lines of code uh throw a docker file next to that and
35:30
And it sits out there in an Alpine hosted Linux container at a hundred meg
35:37
Like now I'm ready to take the Pepsi challenge against those folks that
35:41
that, that are so happy to use node and deliver and run their applications as microservices
35:47
10, 20 lines of code, a hundred meg Docker container. And it runs the fastest framework available out there on the smallest Alpine
35:58
Linux container. That's what I'm talking about when I think about portability, the speed, the efficiency of Docker and .NET
36:09
And coming back to, like you were saying, bring together the whole ecosystem
36:14
I can put that into an Azure container app and it'll run only as needed and shut off completely when it's not being used. Mm-hmm
36:23
It's a great time to be a developer in the Microsoft ecosystem, especially if you're using .NET
36:31
Yeah. There's a, you know, when I do my cloud talk, you know, I show one of my microservices that I wrote in Azure Functions
36:43
And that uses Cosmos DB, you know, just takes something off the queue and, you know, does something with it and sticks in the Cosmos DB
36:51
But, you know, I show them this code that it's almost unbelievable because it's, and this was years ago, right
36:57
To me, when you can, and I'm saying this because, you know, I started out in AWS because I had to
37:06
And I went through all that pain of trying to get things to work in AWS
37:12
Okay. And to look at like a microservice in Azure where that whole database orchestration, everything, I don't even set it up
37:21
Right. It's literally an attribute. Right And that whole orchestration between the queue and the database and all that stuff is taken care of And I show them the code and I go there really only like five lines of code in this if you take away the logging and all that stuff
37:38
And come on. And all I do is publish it and it's done
37:42
I don't have to go to Azure. I don't have to do anything. It just works. Right
37:48
And the connection string, all those things to configure, where it's getting and interacting with that
37:56
put all that into an Azure Key Vault. It's being injected into the application
38:02
You don't have to think about it. It's being maintained by someone else sitting over there
38:06
and you can deploy updates easily to all of that if you need to move connection strings
38:13
you need to rotate certificates, all that stuff. you're absolutely right. Let's make developers' jobs
38:21
not about maintaining the Azure services, setting up and managing the structure
38:28
and the plumbing underneath the application. No. As a developer, I want to focus on the business logic
38:34
of my application. I don't want to deal with any of that other nonsense
38:38
The fact that I have to wire things up and send it over to a service bus
38:43
and think through that architecture, Okay, I get it. That's something that is going to help me scale
38:51
But once I get past that initial configuration, to exactly your point, Dave, I don't want to think about it
38:57
Let me put triggers and things around my functions so I can just say, okay, here's an iCollector for that service bus topic
39:08
Go send it over there. Here, here's a, it's a blob container that's linked in my Azure function
39:15
Just create a new stream and stick it in there. And I don't have to think about the wire up of all those things because I can focus on just my logic
39:25
It's great stuff. Yeah. I, and you know, the, the, the AWS, AWS teams I've been on, sorry about the light, everybody
39:34
It's the sun's, the sun's decided to come out. California. It's going right in my window. My sliding glass door window's over there. But
39:45
what was I going to say? Yeah, coming from the AWS, on the AWS teams I've worked on
39:52
I basically say, I'll write the code, but someone else has to take care of all that other stuff
39:56
because it's just too hard to do it. I don't want to become an AWS expert. I'm a coder
40:02
right? I want to code and get the job done. Let the DevOps guys, you know, take care of all that
40:07
stuff and I can give it to them and go, you guys are the experts, you do it. And that's actually
40:12
what I recommend for companies that are looking into AWS and they're, oh, we're thinking about
40:17
AWS or Microsoft or whatever. And I go, well, let me tell you, you know, if you go to AWS
40:21
you're going to have to hire a full-time DevOps person, right? Because it's the only way you can
40:26
get this stuff to work consistently, right? To have someone dedicated just to do that all day
40:32
long. And at one company they did. And the guy sat right next to me and I'm so glad I didn't have to
40:37
do his job because all he did was writing scripts and tweaking scripts. And he was using VS code for
40:45
it luckily, but he just was constantly just dealing with these issues and trying to wire
40:51
things up in AWS where in Azure, it's pretty simple. Small companies could get away with not
41:00
a DevOps person is kind of what I'm trying to say. Look, you're the whole thing, right
41:05
For ClipTalk. Exactly. ClipTalk is 100% me, top to bottom. I've had a couple folks drop in
41:11
to help out with user interface. I had one or two folks help out
41:16
with wiring up some of the business logic that we've built on the backend
41:21
optimizing that. And it's been helpful. It's been very cool to see
41:27
At some point, I know I need to bring in more folks. But for right now, for what I'm trying to achieve, we're okay moving at this pace
41:36
Yeah, yeah. And you can do that. And I like that just because as a developer, I can play around with that stuff real easily
41:44
And I don't have to become an expert at DevOps to get something working, right
41:51
That's kind of my point is that we can actually do it. You know, we might not be able to do the really crazy, crazy things depending on our experience
41:58
but pretty much anybody can set that stuff up in Azure, right
42:02
If you're a programmer, you can set it up. And I don't want to get crazy deep into the setups like you're saying
42:10
There's tons of ways that you can wire up and set up deployments
42:16
But the staging environments that I get out of the box, the interactions that I get with my code
42:22
I can add unit testing in if I want. I'm cool with that
42:27
at some point i want to run integration tests as part of like a nightly build right yeah or right
42:34
before that pull request is merged i want to run an integration test well how do i run an integration
42:39
test it's going to be something like playwright so where does that run how do i deploy that um
42:46
how do i how do i get that all integrated and report back to the github action that yes this
42:53
is ready to go those are devops things that i should i should be able to set up once and not
43:00
have to not have to um care and feed for right there it is there's how it runs i can add more
43:08
tests to it and it does its thing but i want to configure it once and forget about it when you
43:14
have to do that constant touching and massaging and feeding then then your process is like a puppy
43:20
i i don't want to a puppet set it i want it to be a rotisserie turkey set it and forget it come
43:29
back in a couple hours and my application is deployed my application is tested whatever it
43:35
might be that's what i want as a developer um and don't get me wrong ops folks do amazing things
43:42
that improve how our applications feel and look and behave out there when you have a significant
43:52
application out there. When it's just you and there's one little website, and ClipTalk literally
43:58
is five pages that are all data-driven. But I mean, when we start talking about getting into
44:04
larger applications, more things to manage, now you want an ops person. Now you want somebody who's
44:10
going to be able to coordinate those and take advantage of all the deployment strategies
44:15
sizing your hosting services properly, all that stuff. I'm not ready for it yet
44:24
I don't want to grow up. I'm a developer kid. Me too
44:29
So how many microservices does Clip Talk use? So I have the Azure Functions app that comes with the Azure static website
44:44
And that's all HTTP endpoints. You can't set up queues and things in there
44:49
Let me pop open the source code over here and just take a quick peek and see what we got
44:54
Welcome John from New Jersey I hope you didn hit that big storm isn coming your way that hit kentucky last night so it uh it been kind of dreary here yeah in in the delaware valley so
45:09
philadelphia new jersey region just kind of you know yeah um i was watching all that news this
45:17
morning oh awful to say just terrible yes yes so um one two three four i have five different
45:31
services with a bunch of different functions running them underneath them things to manage
45:36
clips manage um log in log out and your preferences um and i have a whole series of
45:46
functions that are running that do transcriptions of those video clips. It's something that, that not a lot of folks thought about
45:53
And I dove into and really wanted to make sure to, I wanted to set the service apart where when it's one thing to
46:04
to search for and say, well, gosh, I want to, I want to go find that clip where, where Dave was
46:09
where he hosted Scott Hunter and go see what they were talking about
46:14
But it's another thing to say, you know what? Dave was talking to Scott Hunter about .NET 6. And they mentioned, I don't know, they mentioned a Windows Forms thing. I didn't see the show. You know, I want to search for that and find it. And if the clip isn't named exactly what you're looking for, you're not going to find it
46:38
Right. But on Clip Talk, you can search for the words that folks said and find that content
46:45
So I've got a whole series of microservices that build and do that interaction
46:51
Now, I think that's some of the, you know, the news channels do that now, too
46:55
Like they can quickly find videos that someone said some kind of word in the past and they can, you know, find the video pretty quickly, I think, these days
47:04
Yeah. It's a lot of that. All that stuff is being, you know. the words put to it afterwards, right
47:10
Sure, sure, right? Or they're already doing closed captioning as it's being delivered
47:15
So they'll index their own content for that so they can go
47:19
Yeah, that's the only way you can find it. So this senator said this words in 15 years ago
47:26
I mean, how are you supposed to find that if you don't remember they actually did it, right
47:30
Oh yeah, absolutely, right? So to have that search index at your fingertips
47:37
is really valuable. And that kind of thing is not something publicly available
47:44
But I do have that. My back office processes that do the fetch of clips
47:52
and syncing of the information there and handling the transcription chores and managing the search indexes
47:59
I've got 15 different microservices that do that. And each one has a bunch of different tasks
48:06
different Azure functions that are sitting out there. And I'm, I'm counting each of my classes
48:10
I break my Azure functions up into series of different classes that have
48:17
related functions so that I can have, you know, here's where all the clip management is
48:22
Here's where all of your follower information is. So we keep track of here's the folks that you follow on Twitch
48:29
So I can recommend to you on clip talk. Well, here's some cool clips that came up on, you know
48:35
one of your friends channels that you want to go take a look at and catch up on
48:40
So those of you, you know, I did want to bring up real, really quick, just about microservices of people haven't written microservices yet
48:48
that it's, it's a way to dramatically improve performance of your backend, you know, website and other services too
48:56
And let me just give you a quick example. I've talked about this and I've written about this because I did this at one company a while ago that
49:05
you know, this company, when I started there, this is the reason they hired me was, you know
49:10
it was taking 70 seconds to ingest 60, 600 K of data. Right. And that I know, I know
49:18
was really bad. Right. And, and because of that, they couldn't, they couldn't sell contracts to
49:25
big sports teams. You know, like the, I think one of the, one of the first sports teams they
49:30
worked with was the Houston Astros, I think, because one of the players came to our company
49:35
one day. And they were going, yeah, this doesn't work because it's just too long for us to do our
49:43
batting practice and then go back and look at the results. It doesn't work. And so we're not going
49:47
to do it. And so just by setting some microservices in front of their still legacy code, I didn't
49:54
change their legacy code. All I did was use queues and microservices in AWS to improve the
50:02
performance. I got that down to 250 milliseconds or less. The same exact processing, 250 milliseconds
50:10
as opposed to 70 seconds. And this is the power, if you do it right, of course, of microservices
50:18
Don't go way overboard on them either. I know people, I've been seeing tweets about that lately
50:22
too, which I predicted years ago, it's going to happen. But, you know, if you really architect
50:29
it correctly, you can really, really improve the experience of your users. And I go back to
50:36
gosh, Dave, when we were building monolithic web applications, right, you would set up
50:42
some kind of anything that you were doing significant processing on, you would set up
50:46
that thread pool, right, where you would start allocating threads and, right, doing it old school
50:52
way. Oh, create, create five threads and put them into a collection over here. And I'm going to start
50:57
passing into them work to do it, or they wake up and pull things out of an internal queue in memory
51:02
to go and do that. And, and I think of exactly what you're describing of set up a microservice
51:09
set up some queues, and I can now scale that dynamically by just adding more instances of
51:17
those microservices so that I have more workers pulling content off the queue, processing and
51:24
handing things off. Right. When we think Azure functions, you can specify how many, a maximum
51:29
number of instances that gets spun up. And I, I love that for my queue triggers that I know I can
51:36
have up to, I think I set mine at like 20. So if the queue gets backed up and it's taking a little
51:41
bit of time, it starts spinning up more instances and it's going to pick up speed and empty that
51:47
queue quickly. Yeah. And if something, and the, the, the beauty of queues, which I love queues
51:53
is that if something fails, it'll just come back around again. Right. It, it, it doesn't like
51:58
disappear, you know, except after it tries a few times and it might go into the dead letter queue
52:04
But other than that, I mean, you're like, like what happened this week at AWS, right
52:09
But the AWS goes down, and if you're using queues, well, if the whole thing goes down, I guess you're kind of screwed anyway
52:17
But if you using queues that can just kind of stack up and then as soon as the servers comes back up they can start sending all the data through It alleviates a lot of work from us I think I don know about the AWS queues but I know Azure queues are storage storage
52:35
So even if the data center goes down, whatever was in the queue is going to be there
52:40
when it comes back. Yeah, yeah. So, but to another bit towards your point of
52:47
well, I can replicate that queue across multiple data centers. So, okay, if it's not here
52:52
then it's over there we can start processing from different locations. So I have to ask a question from my boss, of course, Mahesh
53:01
He's on the line today. And he says, Jeff, what's the cost look like for these searches
53:08
and which AI services are you using? So I was using for the search
53:15
I was using MySQL as my primary relational database. So I was putting all of my data for the various clip records over into MySQL, and I was placing the content that was going to be transcribed and the results of the transcription into Azure Table Storage, which was being loaded into Azure Search
53:43
Azure Search runs great if you're pointing to Microsoft SQL database, to Azure Table Storage
53:49
And it's just parsing that data and putting it into the index so you can query it quickly
53:55
The problem I ran into was the initial, the basic search service
54:03
You can allocate two gig of data and it's a $70 cost
54:09
So here I was paying $70 for Azure Search. I was paying a couple hundred bucks for the MySQL database, two, three hundred bucks
54:17
And I was also paying another hundred bucks for and growing for the Azure table storage that had all of the transcription data
54:26
So all up, I was paying 500 bucks for up to two gigabytes of storage
54:32
And I got into August and saw how quickly I was growing and knew that I needed to move before October or else I would have to drag that slider, that capacity slider on Azure from 2 gig to the next one, which was 30 gig was the maximum size
54:50
Now, it doesn't matter how much data you're storing. You're charged the same amount per hour that it's used
54:55
And it's constantly re-indexing because I'm constantly generating new content. the cost change was going to be
55:04
it was going to quadruple my search cost. So I was still going to have the 300 some bucks
55:11
for MySQL. I was going to have 100, 150 bucks for Azure Table Storage
55:17
And I was going to see 300 bucks for Azure Search. So I was looking at that cost just to run that
55:24
running up to 700, 800 bucks, just to be able to run the transcription search
55:29
and I was managing three databases. Dave, I don't know about you
55:36
but when I hear three databases to manage one data set, I want to cringe
55:44
I want to run the other way. I get scared. And this is why I went to RavenDB
55:49
because I could take all three of those things and put it into one service
55:56
Get that NoSQL data storage. get the ability to search because Raven's based on Lucene
56:05
And I would also be able to get replication where I need it
56:09
So I could take all three of those services that were going to be 800 bucks and put it into three nodes
56:15
that are replicated in a data center collaborating together. So load balancing, all that stuff
56:21
And I see about $250 is my Raven costs right now. fantastic that as as my data storage grows that cost will go up and that that's fine um that's
56:35
kind of to be expected but i'm i'm literally saving 60 percent of what my costs would have
56:44
been if i had stuck with my with my completely azure-based solution and run with it um but
56:51
i had the flexibility to be able to say well let's explore and try out these other solutions
56:55
And since Raven runs on Azure, it's sitting in the same data center as the rest of my application
57:03
Let's do it. That works great for me. Yeah. Is Raven DB outside of Azure
57:10
It is. So Raven will run in their cloud instance. It's provisioned
57:19
It's charged outside of Azure. You can't exactly go into Azure and say, give me one of these
57:23
but they manage it on their own on the side. So, but you can get it to run on AWS
57:30
Google Cloud and on Azure. And they are running it. It's not in the same resource group
57:36
as the rest of my service, but it is in the same, in my case, East US 2 data center for Azure
57:44
Well, great. And I have to wrap it up because Simon needs to go to bed
57:49
and uh so that's one thing about having a producer in india uh so ganesh i'm sorry we're not going to
57:56
get to your last question but please feel free to reach out to jeff especially on his uh twitch show
58:01
and uh ask him those things there you go and uh so i'm sorry i didn't get to it uh you know we just
58:07
kind of lost i lost track of time and we got to go so um jeff i really appreciate you coming back
58:14
on the show. It's great to chat with you again. And, uh, cause I don't get to see you in person
58:19
for a number of years now. And so, um, it's, it's really great to see you again and I hope
58:25
you and your family have a wonderful Christmas. Oh, thank you. And, uh, and I, you know, and I
58:31
really would like you to come back on the show maybe next year and talk about just the architecture
58:36
itself that you did and how you came up with those decisions and things like that. You talked a little
58:41
bit about it today, but I'd like to hear the whole thing maybe next year. Absolutely. I'd be happy to
58:46
That's great. I got you on video. He's coming back, everybody. All right. Well, thanks very
58:53
much and have a great weekend. Simon's got to go, so we can't
58:59
really hang out after the show. But have fun opening your mysterious package
59:04
on your show. We'll see what that is next week, hopefully. All righty. Thanks a lot, Jeff
59:11
Yep, we'll see you. See you. Well, that was a great session with Jeff again
59:16
Jeff is a great guy and really knowledgeable. And I know he's heard me say this again
59:21
I wish I had his job. You listening, Microsoft? So anyway, I want to get moving
59:29
because we only have a couple of minutes left because I want to let Simon close up
59:33
and do all that stuff. So I've mentioned this before. I have a brand new performance section on my website
59:40
that I'm posting a lot of new articles about performance and I'm constantly working on them
59:46
So I hope you go to that URL there and check them out. All the benchmark performance data is from .NET 5 and .NET 6
59:56
And I guarantee you some of the things you thought was the right way to do things at .NET is not
1:00:03
And so make sure you check out that. As every week, everybody wins a copy of CodeRush from DevExpress
1:00:14
CodeRush is the only refactoring tool I've used since Visual Studio has been out
1:00:19
I use it every day. And let me tell you, I've been doing a lot of coding lately
1:00:23
not a lot of architecting. And I can just tell you that CodeRush just saves me so much time
1:00:29
And so if you don't have a refractoring tool, and I'm not talking about the one in Visual Studio because that's very minimal, you need to get one
1:00:35
And so here's how you can get a real copy, not stripped down for free, by just going to devexpress.com slash done at date
1:00:43
Okay? And if you download it, like it, let me know. And I'd love to hear about it
1:00:51
Also, my latest coding standards book is out there, codingstandardsformicrosoft.net. I hope you go pick it up
1:00:59
My book sales have been down the last couple of months. And so there's my plug to go buy my book
1:01:05
Also, I'm doing something for the next couple of weeks. It's been going on for over a month, I think
1:01:11
I have a new campaign going on right now to help the kids from Voice of Slum, who I visited
1:01:18
a couple of years ago. The last time I was in India, I'm really bummed I haven't been able to go because I want to
1:01:25
see how the money I've been sending to them has been helping them
1:01:29
But I have a new thing now because my friends all of you all of them you saw on the panel on the agile panel show who are getting after me about my long hair So I said okay I do a fund me site If I reach my goal by the end of this year
1:01:47
I will cut on air all my hair off. And I mean, all of it, bald, everything. So if you want me
1:01:54
to cut off my hair, please donate. And if you don't want me to cut off my hair, donate anyway
1:01:59
because it will be fun if it actually happens. So please go there and help the kids from India
1:02:07
especially during the holiday times. Thanks for watching. I mentioned at the beginning of the show
1:02:14
next week, the last show of the year, will be Mark Brown, Principal Program Manager at Microsoft
1:02:20
and he's the lead program manager for Cosmos DB. So he's going to be sharing all the new, latest, greatest stuff
1:02:28
that's been announced from Cosmos DB next month. So I hope you come back for that
1:02:35
because those kinds of databases are the future of our world. And so it's good to get on the bandwagon now
1:02:43
At least that's what I think of the future is. We'll see in 10 years if it really is
1:02:47
Please go listen to your medical professionals about COVID. You know, we're not over this
1:02:53
You know, we're still, we got a new variant now and things are really ticking up here in America
1:02:59
I don't know how it's going on for where you live, but they're ticking up here
1:03:03
And it's going to be another tough holiday season if you want to spend it with people
1:03:09
you don hang around with a lot So and on that note I like to give a shout out to sorry I can read his name on the little graphic there So somebody from India actually went and did the same type of blood donation that I did in India and tweeted this to me
1:03:26
And so I'm so grateful you did that. If you did it because of listening to me, I'm even more grateful
1:03:35
But get more people donating blood like you did. And what he's doing is what I do
1:03:40
And that's being hooked up to a machine for two hours. You don't have to do that to donate blood
1:03:44
This is special super donation stuff. You just need like 30 minutes if you just want to donate blood
1:03:50
So please donate blood. It'll help your fellow humans. And all the blood banks in the world are in shortage right now
1:03:58
And so I think it's everybody's responsibility to go donate blood. because someday if a tornado hits in your state
1:04:08
you might need some blood. So please go donate. I can't stress this enough
1:04:13
And it doesn't cost you a dime. Maybe some fuel to drive there, but that's it
1:04:19
Okay? So thanks very much for watching the show. We've been off for a number of weeks
1:04:26
and we're back at least for one more show after this. Please email me your suggestions and requests
1:04:32
and guests. I'm trying to come up with guests for next year. So if you want me to invite somebody
1:04:37
please email me, let me know, or tweet at me. And there's my email address. And with that
1:04:43
I'll see you next week. Thanks a lot. Thank you
1:05:17
Thank you
1:05:47
Thank you
1:06:17
Thank you
#Windows & .NET


