Skip to content

AlexandraFolvaiter/e-office

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 

Repository files navigation

e-office | Redis Hackathon on Dev

Link to the application

Link to the application

Overview video

Youtube

Project description

eOffice is human resources platform that provides processes to onboard a new employee and to manage the benefits of the employees distributing the responsibilities between the different rolls.

Functionalities

  • See all onboardings
  • Create an onboarding
  • See details of an onboarding
  • See all system accounts requests
  • Resolve a system account request

Architecture and technologies

a03d589d-d34d-403d-86fd-13e09f55e688

  • Presentation project: Server Blazor Application using .Net 6.0
  • Microservices: Web API using .Net 6.0
  • Databases: SQL Server
  • Microservices communication: Redis pub/sub

Flow diagrams:

  1. Create the onboarding CreateOnboarding Flow

  2. Resolve a system account request resolve-sysytem-accounts-request-flow

How to run it locally?

Prerequisites

  1. .Net 6.0
  2. 3 SQL server databases
  3. A redis database

Local installation

  1. Add the connection strings in the appsettings.josn for each module for the databases
  2. Set as startup projects: eOffice, eOffice.Onboardings.API, eOffice.Leave.API, eOffice.SystemAccounts.API
  3. Run the projects

How it works

How the data is stored:

The microservices are communicating with each other using the pub/sub from redis, for each type of communication a different channel will be used. 3 channels

  • SystemAccount_Channel
    • Publisher: Onboardings Module
    • Subscriber: SystemAccounts Module
  • Leave_Channel
    • Publisher: Onboardings Module
    • Subscriber: LeaveBalance Module
  • Onboarding_Channel
    • Publisher: SystemAccounts Module, LeaveBalance Module
    • Subscriber: Onboardings Module

Publis code

var modelAsString = JsonConvert.SerializeObject(model);
_pubSub.Publish("channel_name", modelAsString);

Subscribe code

connection.GetSubscriber()
    .Subscribe("channel_name", (channel, message) =>
    {
        // DO something
    });

Deployment

The services are deployed in Azure in App Service. The database are deployed in Azure. The redis connection is created using Redis stack.

More Information about Redis Stack

Here some resources to help you quickly get started using Redis Stack. If you still have questions, feel free to ask them in the Redis Discord or on Twitter.

Getting Started

  1. Sign up for a free Redis Cloud account using this link and use the Redis Stack database in the cloud.
  2. Based on the language/framework you want to use, you will find the following client libraries:

The above videos and guides should be enough to get you started in your desired language/framework. From there you can expand and develop your app. Use the resources below to help guide you further:

  1. Developer Hub - The main developer page for Redis, where you can find information on building using Redis with sample projects, guides, and tutorials.
  2. Redis Stack getting started page - Lists all the Redis Stack features. From there you can find relevant docs and tutorials for all the capabilities of Redis Stack.
  3. Redis Rediscover - Provides use-cases for Redis as well as real-world examples and educational material
  4. RedisInsight - Desktop GUI tool - Use this to connect to Redis to visually see the data. It also has a CLI inside it that lets you send Redis CLI commands. It also has a profiler so you can see commands that are run on your Redis instance in real-time
  5. Youtube Videos

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published