Learn, Build, and Scale with Elastic
- Elastic Cloud で快適なアプリ開発を実現しよう!-https://event.shoeisha.jp/devsumi/20210218/session/3062/
Power Apps x .NET ~ Transforming Business Applications with Fusion DevelopmentShotaro Suzuki
タイトル:Power Apps x .NET ~ フュージョン開発によるビジネス アプリケーションの変革
概要:企業、政府自治体に限らず、Fusion Team = 市民開発者とプロの開発者がコラボしてアプリを作っていこうという気運が高まってきています。
今回は Power Apps、 .NET 6、OpenAPI 対応 Web API、Azure API Management 等の組み合わせでアプリを作ってみます。
https://dotnetlab.connpass.com/event/254374/
Protect Your IoT Data with UbiBot's Private Platform.pptxユビボット 株式会社
Our on-premise IoT platform offers a secure and scalable solution for businesses, with features such as real-time monitoring, customizable alerts and open API support, and can be deployed on your own servers to ensure complete data privacy and control.
64. Model の作成
• Elasticsearch のデータ
から JSON にシリアライズ
のため必要
• Book という名のクラスを
追加
public class Book
{
public string Title { get; set; }
public string Isbn { get; set; }
public int PageCount { get; set; }
public string ThumbnailUrl { get; set; }
public string ShortDescription { get; set; }
public string LongDescription { get; set; }
public string Status { get; set; }
public string Authors { get; set; }
public string Categories { get; set; }
}
65. Elasticsearch への接続を作成
• NEST ライブラリ追加
• Startup.cs のサービス構成メソッド( )内に接続を作成
dotnet add package NEST
using Elasticsearch.Net;
using Nest;
===
var pool = new SingleNodeConnectionPool
(new Uri(“http://localhost:9200”)); //ローカル実⾏の場合
var settings = new ConnectionSettings(pool)
.DefaultIndex("books");
var client = new ElasticClient(settings);
services.AddSingleton(client);
66. Elasticsearch への接続を作成 - Elastic Cloud ⽤
•
var pool = new SingleNodeConnectionPool
(new Uri(http://localhost:9200/));
// Elastic Cloud デプロイ時に取得した値3つ (例)
https://elastic:oRHGj80iJUO6CF7WBUMiwyu1x@8009bf95
8b6w5923b3c56983d4048df824.japaneast.azure.elastic
-cloud.com:9243