📜 ⬆️ ⬇️

Akka.NET Bootcamp



Welcome to Akka.NET Bootcamp. This is a free self-study course prepared by the guys from Petabridge .

The training course is divided into three parts, during which you will learn how to create fully-functional, real-world programs using the Akka.NET actors and many other parts from the Akka.NET framework.
')
We will start with some of the main actors and will gradually approach larger and more complex examples.

This course is for self-study - you can perform it at any pace at your discretion. You can subscribe here and every day receive one Akka.NET lesson to your email (in English from translation) if you want.

NOTE: Currently the course is designed to use C # as a programming language.
We intend to add support for F # in the future.
(We also accept F # pull requests)


What do you learn


In the Akka.NET course, you will learn how to use the Akka.NET actors to create reactive, parallel systems. You will learn how to create applications that may have seemed impossible or very, very difficult before learning Akka.NET. After the training course, you will feel more confident in solving complex and big problems than before.

Part 1


In the first part, you will learn the basics of how the model of actors and Akka.NET work.

In * NIX systems there is a tail utility, built-in monitoring of changes in the file, which Windows does not have. We will re-create tail for Windows and in the process we will learn fundamental things.

In the first part, we learn:
  1. How to create your own ActorSystem and actors.
  2. How to send messages to actors and how to handle different types of messages.
  3. How to use Props and ActorRef in building loosely coupled systems
  4. How to use paths of actors, their addresses, and ActorSelection to send messages to actors
  5. How to create descendants of actors (child actors) and a hierarchy of actors, and how to control descendants using SupervisionStrategy
  6. How to use the life cycle of an actor to control the behavior of starting, shutting down and restarting an actor


Part 2


In the second part, we will get closer to the features of Akka.NET for building more complex applications than we did in the first part.

In the second part, we learn:

  1. How to use HOCON settings to configure your actors via App.config and Web.config
  2. How to set up your actors' Dispathcer to run them in a UI stream so that actors can perform operations directly on UI elements without the need to switch context
  3. How to handle more complex message types using pattern matching and ReceiveActor
  4. How to use Scheduler to send recurring messages to actors
  5. How to use the publish-subscribe pattern (pub-sub) pattern between actors
  6. How and why to switch the behavior of actors in runtime
  7. How to use Stash to save messages for further processing


Part 3


In the third part, we will learn how to use actors for concurrency and scaling using Octokit and data from Github!

In the third part, we learn:

  1. How to do work asynchronously inside your actors using PipeTo
  2. How to use Ask inside an actor to wait for a response to your messages
  3. How to use ReceiveTimeout for responses from other actors
  4. How to use Group routers to share work between your actors
  5. How to use Pool routers to automatically create and manage actor pools (pools of actors)
  6. How to use HOCON to configure your routers


Where to begin


This is how Akka.NET Bootcamp works.

Use Github to make life easier.


This Github repository contains Visual Studio solutions and other elements you need to complete the training course.

Thus, if you want to continue the training course, we recommend the following:

  1. Sign up on Github if you haven't done so already.
  2. Fork this repository and clone your fork to the local machine.
  3. While you are doing the lessons, leave the web browser tab open on Akka.NET Bootcamp ReadMes , so you can read all the instructions clearly and easily.

Bootcamp structure


Akka.NET Bootcamp consists of 3 modules:


Each module contains the following structure (using Part 1 as an example :)

src\Unit1\README.MD - table of contents and instructions for the module src\Unit1\DoThis\ - contains the .SLN and project files that you will use through all lessons -- lesson 1 src\Unit1\Lesson1\README.MD - README explaining lesson1 src\Unit1\Lesson1\DoThis\ - C# classes, images, text files, and other junk you'll need to complete lesson1 src\Unit1\Lesson1\Completed\ - Got stuck on lesson1? This folder shows the "expected" output for the lesson -- repeat for all lessons 


Start with the first lesson in each part and follow the instructions described in the README (or here in Habré :) from translation) .

Lesson structure


Each Akka.NET Bootcamp lesson contains a description that explains the following:



When you do the lessons ...

A few things to keep in mind when you follow the step-by-step instructions:



Documentation


We will give explanations of all key concepts during each lesson, but, of course, you should bookmark (and feel free to use them!) Using the Akka.NET documentation

Tools / Prerequisites


This course expects from you:

  1. Some programming experience and familiar with C #
  2. Github account and basic git knowledge
  3. You are using Visual Studio ( it is now free! )


About Petabridge




Petabridge is a company created specifically to make the life of .NET developers easier to build distributed applications.

Petabridge also offers Akka.NET consultation and training .

Source: https://habr.com/ru/post/253547/


All Articles