All Projects → AntonioFalcao → Dotnet5.Elasticsearch

AntonioFalcao / Dotnet5.Elasticsearch

Licence: MIT License
This project aims to explore how NEST works with Elasticsearch in .NET 5 projects.

Programming Languages

C#
18002 projects
Dockerfile
14818 projects

Projects that are alternatives of or similar to Dotnet5.Elasticsearch

homebridge-google-nest-sdm
A Homebridge plugin for Google Nest devices that uses the Google Smart Device Management API. Supports Cameras, Doorbells, Displays, and Thermostats.
Stars: ✭ 16 (+33.33%)
Mutual labels:  nest
nestjs-cookie-session
Idiomatic Cookie Session Module for NestJS. Built on top of `cookie-session` 😻
Stars: ✭ 35 (+191.67%)
Mutual labels:  nest
automapper-nartc
(Deprecated) An automapper-ts fork (by Bert Loedeman)
Stars: ✭ 21 (+75%)
Mutual labels:  automapper
ynest
ynest, 是一個幫助項目開始的腳手架,目前包含了 nest.js、flutter 項目,內置 CI/CD 等自動化腳本設定。
Stars: ✭ 17 (+41.67%)
Mutual labels:  nest
nx-ng-nest-universal
Nx Workspace with a seperated Nest App for Angular Universal SSR.
Stars: ✭ 32 (+166.67%)
Mutual labels:  nest
Kodkod
https://github.com/alirizaadiyahsi/Nucleus Web API layered architecture startup template with ASP.NET Core 2.1, EF Core 2.1 and Vue Client
Stars: ✭ 45 (+275%)
Mutual labels:  automapper
nest-blog-api
B站全栈之巅:基于TypeScript的NodeJs框架:NestJs开发博客API (node.js+nest.js)
Stars: ✭ 34 (+183.33%)
Mutual labels:  nest
kopo-cli
🐶 A Deno registry browser in the terminal
Stars: ✭ 15 (+25%)
Mutual labels:  nest
node-nestjs-structure
Node.js framework NestJS project structure
Stars: ✭ 258 (+2050%)
Mutual labels:  nest
nest-typed-config
Intuitive, type-safe configuration module for Nest framework ✨
Stars: ✭ 47 (+291.67%)
Mutual labels:  nest
angular-nest-starter
A simple Angular with Nest starter kit
Stars: ✭ 15 (+25%)
Mutual labels:  nest
QueryNinja
Framework for dynamic query building regardless of the source and target.
Stars: ✭ 19 (+58.33%)
Mutual labels:  nest
Nest-Js-Boiler-Plate
Nest Js Boilerplate with JWT authentication, CRUD functions and payment gateways.
Stars: ✭ 14 (+16.67%)
Mutual labels:  nest
blog3.0
博客V3.0 目前使用的技术(Nuxtjs + Nestjs + Vue + Element ui + vuetify),存储(MongoDB + Redis + COS)
Stars: ✭ 37 (+208.33%)
Mutual labels:  nest
mysql-dotnet-core
ASP.NET Core 5.0 Web Application using MySQL with Entity Framework
Stars: ✭ 95 (+691.67%)
Mutual labels:  dotnet5
mom
Proof of concept for Message-Oriented-Middleware based architecture.
Stars: ✭ 39 (+225%)
Mutual labels:  nest
whip
Simple fast http server for nim based on httpbeast and nest for high performance routing
Stars: ✭ 55 (+358.33%)
Mutual labels:  nest
OpenCoreMMO
Open-source MMORPG server emulator written in C#
Stars: ✭ 157 (+1208.33%)
Mutual labels:  dotnet5
AspNetCore.BookStore
ASP.NET Core application using Command Pattern and Repository Pattern
Stars: ✭ 121 (+908.33%)
Mutual labels:  automapper
nestjs-pgpromise
A Module for Utilizing Pg-promise with NestJS
Stars: ✭ 24 (+100%)
Mutual labels:  nest

.NET 5 + Elasticsearch + NEST

.NET Core

This project aims to explore how NEST works with Elasticsearch in .NET 5 projects.

Getting Started

After the project clone follow the steps described in the installing.

HTTPS

git clone https://github.com/AntonioFalcao/Dotnet5.Elasticsearch.git

SSH

git clone [email protected]:AntonioFalcao/Dotnet5.Elasticsearch.git

Prerequisites

To check this functionality:

dotnet --version

For more details

dotnet --info
  • Docker - The container platform used

To check this functionality:

docker --version

Installing

With the use of containerization, we can practically orchestrate the necessary infrastructure.

You will need an Elastic Search cluster + Kibana , to meet the need for Search Engine, so you must run the respective docker-compose on your Elasticsearch server.

cd ./.elasticsearch/
docker-compose up -d

Is important to say, if occurrence problems with max virtual memory area:

docker logs es01

# abbreviated

ERROR: [1] bootstrap checks failed
[1]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]

It's possible to increase to at least [262144]:

sudo sysctl -w vm.max_map_count=262144

More details about in this link

The Kibana service will be available in default host http://localhost:5601, as defined on compose.

  kib01:
    image: docker.elastic.co/kibana/kibana:7.6.0
    container_name: kib01
    ports:
      - 5601:5601
    environment:
      ELASTICSEARCH_URL: http://es01:9200
      ELASTICSEARCH_HOSTS: http://es01:9200

# abbreviated

App settings

After providing the necessary infrastructure, we need to define the cluster index and nodes addresses on the appsettings from the Elasticsearch.Client.WebApi project.

{
  "Elasticsearch": {
    "index": "card",
    "node1Uri": "http://192.168.0.27:9200/",
    "node2Uri": "http://192.168.0.27:9201/",
    "node3Uri": "http://192.168.0.27:9202/"
  }
}

And then set the HTTP client host on appsettings from Elasticsearch.Stressor.WebApi project.

{
  "ElasticsearchClient": {
    "Url": "http://localhost:5000"
  }
}

Running

The respective compose provide the client and stressor services:

docker-compose up -d

Stressor and Client services

The Stressor service provide resources to request generate, modify, and remove data from Elasticsearch through the client service.

Is just run the compose from the app to up both of then in the same network. In this way is possible to use services names on the appsettings.

The Client routing uses the default http://hostname:port/api/v{version}/controller,
where /v1 is Synchronous and /v2 is Asynchronous.

The Stressor routing uses the default http://hostname:port/controller/action.

To make API calls, you can use the file ./basic-api-call.http through extension REST Client:

# STRESSOR
###
GET http://localhost:6000/stressor/generate?amount=10
###
GET http://localhost:6000/stressor/modify?amount=10
###
GET http://localhost:6000/stressor/exclude?amount=10
# CLIENT
###
GET http://localhost:5000/api/v2/card
###
GET http://localhost:5000/api/v2/card/f694491b-bc98-45bc-af97-67f7ac460908

Built With

.NET Stack

Elasticsearch Stack

  • Elasticsearch - Search Engine used.
  • NEST - Elasticsearch client for .NET
  • Kibana - Elasticsearch visualize and analyze service

Contributing

Available soon!

Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

Authors

See also the list of contributors who participated in this project.

License

This project is licensed under the MIT License - see the LICENSE file for details

Acknowledgments

  • Nothing more, for now.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].