﻿
{"id":20423,"date":"2021-01-02T23:44:16","date_gmt":"2021-01-02T23:44:16","guid":{"rendered":"https:\/\/www.gencayyildiz.com\/blog\/?p=20423"},"modified":"2021-01-02T23:44:16","modified_gmt":"2021-01-02T23:44:16","slug":"grpcde-client-ve-server-uygulamalari-proto-dosyasi-ve-servislerin-olusturulmasi","status":"publish","type":"post","link":"https:\/\/www.gencayyildiz.com\/blog\/grpcde-client-ve-server-uygulamalari-proto-dosyasi-ve-servislerin-olusturulmasi\/","title":{"rendered":"gRPC&#8217;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131"},"content":{"rendered":"<div id=\"fb-root\"><\/div>\n<p>Merhaba,<\/p>\n<p>Bir \u00f6nceki <a href=\"https:\/\/www.gencayyildiz.com\/blog\/grpc-nedir-ne-amacla-ve-nasil-kullanilir\/\" rel=\"noopener noreferrer\" target=\"_blank\">gRPC Nedir? Ne Ama\u00e7la ve Nas\u0131l Kullan\u0131l\u0131r?<\/a> ba\u015fl\u0131kl\u0131 makalemizde gRPC&#8217;nin ne oldu\u011funa ve ne ama\u00e7la kullan\u0131ld\u0131\u011f\u0131na teorik de\u011finmi\u015ftik. Bu i\u00e7eri\u011fimizde ise gRPC ile client ve server uygulamalar\u0131n\u0131n nas\u0131l geli\u015ftirildi\u011fini, servislerin ve mesaj t\u00fcrlerinin nas\u0131l generate edildi\u011fini, her iki uygulama aras\u0131nda ileti\u015fimin nas\u0131l sa\u011fland\u0131\u011f\u0131n\u0131 ve gRPC&#8217;de ki temel yap\u0131ta\u015f\u0131 olan proto dosyalar\u0131n\u0131n fiziksel olarak ne oldu\u011funu inceleyece\u011fiz. Hadi gelin vakit kaybetmeden ba\u015flayal\u0131m.<\/p>\n<h3 style=\"color:green;\">gRPC Server Projesi Olu\u015fturma<\/h3>\n<p>\u0130lk olarak bir gRPC server projesi olu\u015fturarak ba\u015flayal\u0131m.<br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"490\" height=\"233\" class=\"aligncenter size-full wp-image-20424\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi.png 490w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-300x143.png 300w\" sizes=\"auto, (max-width: 490px) 100vw, 490px\" \/><\/a><br \/>\nMalumunuz istifade edece\u011fimiz ortam Visual Studio \ud83d\ude42 Dolay\u0131s\u0131yla &#8216;gRPC Service&#8217; se\u00e7erek platformumuzu belirtiyor ve ard\u0131ndan proje ismini belirtiyoruz.<br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-1.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-1.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"449\" height=\"195\" class=\"aligncenter size-full wp-image-20425\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-1.png 449w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-1-300x130.png 300w\" sizes=\"auto, (max-width: 449px) 100vw, 449px\" \/><\/a><br \/>\nEee art\u0131k framework olarak <code style=\"font-size:12px;\">.NET 5.0<\/code>&#8216;da olu\u015fturmak i\u015fin farz\u0131 oldu.<\/p>\n<h3 style=\"color:green;\">gRPC Server Proje Dosyalar\u0131n\u0131 \u0130nceleme<\/h3>\n<p><a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-2.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-2.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"165\" height=\"217\" class=\"alignleft size-full wp-image-20430\" \/><\/a>Olu\u015fturulan gRPC server projesinin dosyalar\u0131n\u0131 incelersek e\u011fer g\u00f6r\u00fcld\u00fc\u011f\u00fc \u00fczere klasik .NET Core temellerinde bir projeyle kar\u015f\u0131la\u015fmaktay\u0131z. Sadece ekstradan &#8216;Protos&#8217; klas\u00f6r\u00fc ve alt\u0131ndaki &#8216;greet.proto&#8217; dosyas\u0131 g\u00f6z\u00fcm\u00fcze \u00e7arpmaktad\u0131r. Bu dosya, client ile server aras\u0131ndaki kontrat i\u015flevini \u00fcstlenecek olan ve i\u00e7eri\u011fimizin seyrinde daha detayl\u0131 ele alaca\u011f\u0131m\u0131z bir dosyad\u0131r. \u015eimdi her \u015feyden \u00f6nce bir gRPC uygulamas\u0131n\u0131n &#8216;Startup.cs&#8217; dosyas\u0131n\u0131 inceleyerek ba\u015flayal\u0131m.<br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-3.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-3-300x280.png\" alt=\"\" width=\"300\" height=\"280\" class=\"alignright size-medium wp-image-20434\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-3-300x280.png 300w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-3.png 520w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a>Yandaki g\u00f6rselde bir gRPC projesinin &#8216;Startup.cs&#8217; i\u00e7eri\u011fini g\u00f6zlemlemekteyiz. Taraf\u0131mca vurgulanan iki noktaya nazar\u0131n\u0131z\u0131 \u00e7ekmek istiyorum. \u0130lki k\u0131rm\u0131z\u0131 ile vurgulad\u0131\u011f\u0131m <code style=\"color:red;font-size:12px;\">services.AddGrpc()<\/code> komutu ile servisin eklenmesi gerekti\u011fidir. Evet, bir uygulaman\u0131n gRPC olmas\u0131 i\u00e7in bu \u015fekilde servisin eklenmesi gerekmektedir. \u0130kincisi ise ye\u015fil ile vurgulad\u0131\u011f\u0131m &#8216;UseEndpoints&#8217;i i\u00e7erisindeki <code style=\"color:green;font-size:12px;\">endpoints.MapGrpcService<GreeterService>()<\/code> middleware&#8217;idir. Bu middleware ile server&#8217;\u0131n aksiyonlar\u0131n\u0131 belirledi\u011fi servis belirlenmi\u015ftir. B\u00f6ylece client&#8217;tan bir metodu tetiklemek i\u00e7in gelen istek neticesinde o metodu hangi servisin kar\u015f\u0131layaca\u011f\u0131 ve tetikleyece\u011fi buradan bildirilmektedir. Bu servis proje dosyalar\u0131na g\u00f6z atarsan\u0131z &#8216;Services&#8217; klas\u00f6r\u00fc i\u00e7erisinde &#8216;GreeterService&#8217; olarak tutulmaktad\u0131r. Velhas\u0131l, bu servis meselesini i\u00e7eri\u011fimizin devam\u0131nda daha da detayland\u0131rm\u0131\u015f olaca\u011f\u0131z. \u015eimdilik ge\u00e7iyorum&#8230;<\/p>\n<h3 style=\"color:green;\">proto Dosyas\u0131 \u0130nceleme<\/h3>\n<p><a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-4.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-4.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"339\" height=\"329\" class=\"alignleft size-full wp-image-20441\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-4.png 339w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-4-300x291.png 300w\" sizes=\"auto, (max-width: 339px) 100vw, 339px\" \/><\/a>Gelelim proto dosyas\u0131na. Ne demi\u015ftik, server ile client aras\u0131nda kontrat\u0131 proto dosyas\u0131 ile sa\u011flamaktay\u0131z. \u0130\u00e7eri\u011fine bakarsak e\u011fer &#8216;service&#8217; ve &#8216;message&#8217; tan\u0131mlamalar\u0131 olan ve &#8216;syntax&#8217;, &#8216;option&#8217; ve &#8216;package&#8217; gibi keywordler bar\u0131nd\u0131ran karman \u00e7orman bir dosya \ud83d\ude42 Hii\u00e7\u00e7\u00e7 panik yapmay\u0131n. Birazdan bu dosyay\u0131 ve i\u00e7eri\u011findekilerin ne anlam ifade etti\u011fini ad\u0131n\u0131z ve soyad\u0131n\u0131z gibi \u00f6\u011frenmi\u015f olacaks\u0131n\u0131z.<\/p>\n<p>\u0130lk olarak dosyan\u0131n yukar\u0131s\u0131nda tan\u0131mlanan keywordleri ele alal\u0131m. Sonra alttaki &#8216;service&#8217; ve &#8216;message&#8217; yap\u0131lar\u0131n\u0131 inceleyecelim;<\/p>\n<ul>\n<li><em style=\"color:purple;\"><u>syntax<\/u><\/em><br \/>\nProto s\u00fcr\u00fcm\u00fcn\u00fc ifade eder.\n<\/li>\n<li><em style=\"color:purple;\"><u>option<\/u><\/em><br \/>\nGenerate edilecek servis yap\u0131lanmas\u0131n\u0131n olu\u015fturulaca\u011f\u0131 namespace ad\u0131n\u0131 ifade eder.\n<\/li>\n<li><em style=\"color:purple;\"><u>package<\/u><\/em><br \/>\nGenerate edilecek servis dosyalar\u0131nda kullan\u0131lacak paketleri ifade eder. Yani bildi\u011finiz k\u00fct\u00fcphanelerdir.\n<\/li>\n<li><em style=\"color:purple;\"><u>service<\/u><\/em><br \/>\nUygulamadaki generate edilecek servisin ad\u0131n\u0131 ve i\u00e7erisindeki metot imzas\u0131n\u0131 ifade etmektedir. Yani i\u00e7eriksel a\u00e7\u0131dan olduk\u00e7a \u00f6nemlidir. Yukar\u0131daki \u00f6rnek proto&#8217;da ki service yap\u0131lanmas\u0131n\u0131 ele al\u0131rsak e\u011fer;<br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-5.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-5.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"652\" height=\"420\" class=\"aligncenter size-full wp-image-20447\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-5.png 652w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-5-300x193.png 300w\" sizes=\"auto, (max-width: 652px) 100vw, 652px\" \/><\/a>\u015feklinde genel yap\u0131lanmay\u0131 izah edebiliriz. Buradan yola \u00e7\u0131karak genel prototipi de a\u015fa\u011f\u0131daki gibi varsayabiliriz.<br \/>\n<div id=\"attachment_20449\" style=\"width: 611px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-6.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-20449\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-6.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"601\" height=\"127\" class=\"size-full wp-image-20449\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-6.png 601w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-6-300x63.png 300w\" sizes=\"auto, (max-width: 601px) 100vw, 601px\" \/><\/a><p id=\"caption-attachment-20449\" class=\"wp-caption-text\">Proto dosyas\u0131 servis prototipi&#8230;<\/p><\/div>\n<\/li>\n<li><em style=\"color:purple;\"><u>message<\/u><\/em><br \/>\nClient ile server aras\u0131ndaki veri iletiminde kullan\u0131lacak mesaj t\u00fcr\u00fcn\u00fc ifade etmektedir. Yukar\u0131daki \u00f6rnek proto dosyas\u0131nda &#8216;HelloRequest&#8217; ve &#8216;HelloReply&#8217; mesaj t\u00fcrlerine kar\u015f\u0131l\u0131k gelmektedir. \u0130lgili t\u00fcrlerin i\u00e7erisinde s\u0131ras\u0131yla &#8216;string&#8217; t\u00fcrde &#8216;name&#8217; ve &#8216;message&#8217; alanlar\u0131 mevcuttur. Yani bu demek oluyor ki, bu mesajlar i\u00e7lerinde bu property&#8217;leri(C# dilinde) ta\u015f\u0131yacakt\u0131rlar.\n<\/li>\n<\/ul>\n<blockquote><p><em style=\"color:orange;\">Bu \u015fekilde bir service tasar\u0131m\u0131 esas\u0131nda tek request&#8217;e tek response oldu\u011fundan dolay\u0131 Unary y\u00f6ntemi olarak nitelendirilmektedir.<\/em><\/p><\/blockquote>\n<p>Tabi, olu\u015fturulan bir gRPC uygulamas\u0131ndaki bu &#8216;Greeter&#8217; servisi \u00f6rnek ama\u00e7l\u0131 olu\u015fturulmu\u015ftur. Dolay\u0131s\u0131yla \u00f6zelle\u015ftirilebilmektedir. Sonraki i\u00e7eriklerimizde servisleri ve mesaj t\u00fcrlerini yer yer \u00f6zelle\u015ftirecek ve \u00f6ylece pratikte inceliyor olaca\u011f\u0131z.<\/p>\n<h3 style=\"color:green;\">proto Dosyas\u0131n\u0131n Derlenmesi &#8211; Servis ve Mesaj T\u00fcrlerinin Generate Edilmesi<\/h3>\n<p><a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-7.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-7.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"240\" height=\"305\" class=\"alignright size-full wp-image-20461\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-7.png 240w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-7-236x300.png 236w\" sizes=\"auto, (max-width: 240px) 100vw, 240px\" \/><\/a>Velhas\u0131l, proto dosyas\u0131 i\u00e7erisinde tan\u0131mlanan servis ve mesaj t\u00fcrlerini generate edebilmek i\u00e7in uygulaman\u0131n derlenmesi gerekmektedir. Bu derleme neticesinde yanda g\u00f6r\u00fcld\u00fc\u011f\u00fc \u00fczere uygulaman\u0131n \u00e7\u0131kt\u0131lar\u0131ndan<br \/>\n<code style=\"font-size:15px;color:blue;\">'obj' -> 'Debug' -> 'net5.0' -> 'Protos'<\/code><br \/>\nkombinasyonuna gelirseniz e\u011fer ilgili servise kar\u015f\u0131l\u0131k s\u0131n\u0131flar\u0131n olu\u015fturuldu\u011funu g\u00f6receksiniz.<\/p>\n<p>Dikkat ederseniz e\u011fer &#8216;Greater&#8217; servisi ile birlikte &#8216;HelloRequest&#8217; ve &#8216;HelloReply&#8217; mesaj t\u00fcrleri olu\u015fturulmu\u015ftur. Bu s\u0131n\u0131flardan herhangi birine g\u00f6z atarsak e\u011fer;<br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-8.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-8.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"928\" height=\"557\" class=\"aligncenter size-full wp-image-20465\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-8.png 928w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-8-300x180.png 300w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-8-768x461.png 768w\" sizes=\"auto, (max-width: 928px) 100vw, 928px\" \/><\/a>G\u00f6r\u00fcld\u00fc\u011f\u00fc \u00fczere generate edilen s\u0131n\u0131f(Greeter) biraz ileri derecede dil yetene\u011fi gerektirecek \u015fekilde olu\u015fturulmu\u015ftur. Bu generate edilen dosyalarda s\u00fcrekli g\u00f6z\u00fcn\u00fcze \u00e7arpan ya da bir ba\u015fka deyi\u015fle \u00e7arpacak olan <code>global<\/code> ve <code>::<\/code> operat\u00f6rlerinin ne oldu\u011funu anlayabilmek i\u00e7in <a href=\"https:\/\/www.gencayyildiz.com\/blog\/cta-operatoru\/\" rel=\"noopener noreferrer\" target=\"_blank\">C#\u2019ta :: Operat\u00f6r\u00fc<\/a> ba\u015fl\u0131kl\u0131 yaz\u0131ma g\u00f6z atabilirsiniz. Do\u011frusu bu dosyalar\u0131 esas\u0131nda anlamak ve anlamland\u0131rmak mecburiyetinde de\u011filsiniz. Nihayetinde protoc compiler sayesinde generate edilmektedir ve \u00fczerinde bile herhangi bir fiziksel de\u011fi\u015fiklik kal\u0131c\u0131l\u0131k sergilemeyecektir. Dolay\u0131s\u0131yla i\u00e7erik a\u00e7\u0131s\u0131ndan sizi pek ilgilendirmeyecek bu s\u0131n\u0131flar\u0131 sadece kullanmaya odakl\u0131 bir \u015fekilde de\u011ferlendireceksiniz.<\/p>\n<h3 style=\"color:green;\">Generate Edilen T\u00fcrlerin Kullan\u0131lmas\u0131<\/h3>\n<p>Art\u0131k servis ile birlikte mesaj t\u00fcrleri olu\u015fturulmu\u015f oldu\u011funa g\u00f6re bunlar\u0131 kullanacak olan bir servis&#8217;in yarat\u0131lmas\u0131 gerekmektedir. Bunun i\u00e7in mimari bize &#8216;Services&#8217; klas\u00f6r\u00fcndeki &#8216;GreeterService&#8217; class&#8217;\u0131n\u0131 \u00f6rnek olarak sunmaktad\u0131r. \u0130lgili class&#8217;\u0131 incelersek e\u011fer;<br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-9.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-9.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"743\" height=\"365\" class=\"aligncenter size-full wp-image-20470\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-9.png 743w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-9-300x147.png 300w\" sizes=\"auto, (max-width: 743px) 100vw, 743px\" \/><\/a>Yukar\u0131daki servis g\u00f6rseline dikkat ederseniz, olu\u015fturulan servis&#8217;in &#8216;name[Base]&#8217; \u015feklinde isimlendirilerek generate edilen bir class&#8217;tan inherit edildi\u011fini g\u00f6rmekteyiz. Haliyle ilgili base class i\u00e7erisinde proto dosyas\u0131 sayesinde generate edilerek virtual olarak tan\u0131mlanm\u0131\u015f olan  &#8216;SayHello&#8217; metodu override edilerek, gelecek istek neticesinde yap\u0131lacak operasyon ger\u00e7ekle\u015ftirilmektedir. <\/p>\n<h3 style=\"color:green;\">gRPC Server Uygulamas\u0131n\u0131n .csproj Dosyas\u0131n\u0131n \u0130ncelenmesi<\/h3>\n<p><a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-10.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-10-300x160.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"300\" height=\"160\" class=\"alignleft size-medium wp-image-20481\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-10-300x160.png 300w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-10.png 528w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a>gRPC Server uygulamas\u0131n\u0131n .csproj dosyas\u0131na da g\u00f6z atmakta fayda olacakt\u0131r. Haliyle yandaki g\u00f6rseli incelerseniz e\u011fer, bir gRPC server uygulamas\u0131nda olmas\u0131 gereken paketleri ve temel konfig\u00fcrasyonlar\u0131 g\u00f6rebilmekteyiz. Dikkat ederseniz gRPC protoc compiler i\u015flemlerini ger\u00e7ekle\u015ftirebilmek i\u00e7in &#8216;Grpc.AspNetCore&#8217; paketi referans edilmi\u015ftir. Ayr\u0131ca &#8216;Protobuf&#8217; olarak &#8216;Protos\\greet.proto&#8217; bildirilmi\u015f ve &#8216;GrpcServices&#8217; \u00f6zelli\u011fi de &#8216;Server&#8217; olarak nitelendirilmi\u015ftir. Tabi ki de t\u00fcm proto dosyalar\u0131 burada ayn\u0131 \u015fekilde bildirilmelidir.<\/p>\n<h3 style=\"color:green;\">gRPC Client Projesi Olu\u015fturma<\/h3>\n<p>Art\u0131k s\u0131ra gRPC \u00fczerinden server&#8217;a istek g\u00f6nderebilmesi i\u00e7in client uygulamas\u0131n\u0131n geli\u015ftirilmesine gelmi\u015ftir. Bunun i\u00e7in web, mobil, windows form yahut console platformlar\u0131ndan herhangi birini tercih edebilirsiniz. Biz bu i\u00e7eri\u011fimizde, \u00f6rneklendirmeye pratiksel a\u00e7\u0131dan en yatk\u0131n olan console uygulamas\u0131 \u00fczerinden client olu\u015fturmay\u0131 tercih edece\u011fiz.<\/p>\n<p>\u015eimdi bu client uygulamas\u0131nda ilk yapmam\u0131z gereken, server&#8217;da ki proto dosyas\u0131n\u0131n birebir ayn\u0131 i\u00e7eriklisini olu\u015fturmakt\u0131r. Nihayetinde server&#8217;la client&#8217;\u0131n haberle\u015febilmesi i\u00e7in aralar\u0131ndaki kontrat\u0131 bu proto dosyalar\u0131 sa\u011flayacak ve her iki uygulamada da gerekli s\u0131n\u0131f ve t\u00fcrlerin generate operasyonunu \u00fcstlenecektir.<br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-11.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-11-300x183.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"300\" height=\"183\" class=\"alignleft size-medium wp-image-20488\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-11-300x183.png 300w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-11.png 660w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a>G\u00f6r\u00fcld\u00fc\u011f\u00fc \u00fczere ilgili proto dosyas\u0131 &#8216;csharp_namespace&#8217; de\u011feri d\u0131\u015f\u0131nda hi\u00e7bir de\u011fi\u015fiklik yap\u0131lmaks\u0131z\u0131n olu\u015fturulmu\u015ftur. Namespace de\u011ferinin de\u011fi\u015ftirilme sebebi ise client&#8217;a uygun bir isimlendirme yap\u0131lmas\u0131d\u0131r. Eee o kadar da olacak art\u0131k \ud83d\ude42<\/p>\n<p><strong><em>Peki hocam, console uygulamas\u0131nda bu proto dosyas\u0131n\u0131 ne ile compile edecek ve gerekli servis s\u0131n\u0131f ve t\u00fcrlerini olu\u015fturaca\u011f\u0131z?<\/em><\/strong> \u015feklindeki olas\u0131 sorunuzu duyar gibiyim&#8230; Evet, hakl\u0131 olarak gelen bu soruya kar\u015f\u0131 a\u015fa\u011f\u0131daki y\u00fcklenmesi gereken k\u00fct\u00fcphaneleri cevap olarak verebiliriz.<br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-12.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-12.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"826\" height=\"392\" class=\"aligncenter size-full wp-image-20493\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-12.png 826w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-12-300x142.png 300w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-12-768x364.png 768w\" sizes=\"auto, (max-width: 826px) 100vw, 826px\" \/><\/a>Evet, g\u00f6r\u00fcld\u00fc\u011f\u00fc \u00fczere client uygulamas\u0131nda <a href=\"https:\/\/www.nuget.org\/packages\/Google.Protobuf\" rel=\"noopener noreferrer\" target=\"_blank\">Google.Protobuf<\/a>, <a href=\"https:\/\/www.nuget.org\/packages\/Grpc.Net.Client\" rel=\"noopener noreferrer\" target=\"_blank\">Grpc.Net.Client<\/a> ve <a href=\"https:\/\/www.nuget.org\/packages\/Grpc.Tools\/\" rel=\"noopener noreferrer\" target=\"_blank\">Grpc.Tools<\/a> k\u00fct\u00fcphanelerinin y\u00fckl\u00fc olmas\u0131 gerekmektedir. Bu k\u00fct\u00fcphanelerin i\u015flevsel sorumluluklar\u0131n\u0131 s\u0131ras\u0131yla izah edersek e\u011fer;<\/p>\n<ul>\n<li><strong><em>Google.Protobuf<\/em><\/strong><br \/>\nProtobuf serialization ve deserialization i\u015flemleri i\u00e7in gerekli k\u00fct\u00fcphanedir.\n<\/li>\n<li><strong><em>Grpc.Net.Client<\/em><\/strong><br \/>\n.NET mimarilerine uygun gRPC k\u00fct\u00fcphanesidir.\n<\/li>\n<li><strong><em>Grpc.Tools<\/em><\/strong><br \/>\nProto dosyalar\u0131n\u0131 derlemek i\u00e7in gerekli compiler&#8217;\u0131 ve di\u011fer ara\u00e7lar\u0131 i\u00e7eren k\u00fct\u00fcphanedir.\n<\/li>\n<\/ul>\n<p>Ayr\u0131ca client&#8217;\u0131n .csproj dosyas\u0131na dikkat ederseniz ilgili proto dosyas\u0131 &#8216;Protobuf&#8217; olarak eklenmi\u015ftir ve &#8216;GrpcServices&#8217; \u00f6zelli\u011fine bu sefer &#8216;Client&#8217; niteli\u011fi verilmi\u015ftir.<br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-13.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-13.png\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"287\" height=\"352\" class=\"alignleft size-full wp-image-20502\" srcset=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-13.png 287w, https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi-13-245x300.png 245w\" sizes=\"auto, (max-width: 287px) 100vw, 287px\" \/><\/a><br \/>\nVelhas\u0131l, ilgili client uygulamas\u0131nda da gerekli servis ve mesaj t\u00fcrlerini generate edebilmemiz i\u00e7in uygulaman\u0131n derlenmesi gerekmektedir. Derleme neticesinde<br \/>\n<code style=\"font-size:15px;color:blue;\">'obj' -> 'Debug' -> 'net5.0'<\/code><br \/>\ndizininde yandaki gibi ilgili s\u0131n\u0131flar\u0131n olu\u015fturuldu\u011funu g\u00f6rebilmekteyiz.<\/p>\n<p>Art\u0131k tek yap\u0131lmas\u0131 gereken client&#8217;tan server&#8217;a istekte bulunmak ve response&#8217;u elde etmek. Bunun i\u00e7in console uygulamas\u0131n\u0131n &#8216;Program.cs&#8217; dosyas\u0131nda a\u015fa\u011f\u0131daki \u00e7al\u0131\u015fman\u0131n yap\u0131lmas\u0131 yeterli olacakt\u0131r.<\/p>\n<pre class=\"brush: jscript; title: ; notranslate\" title=\"\">\r\n    class Program\r\n    {\r\n        static async Task Main(string&#x5B;] args)\r\n        {\r\n            var channel = GrpcChannel.ForAddress(&quot;https:\/\/localhost:5001&quot;);\r\n            var greetClient = new Greeter.GreeterClient(channel);\r\n            HelloReply response = await greetClient.SayHelloAsync(new HelloRequest { Name = &quot;Gen\u00e7ay&quot; });\r\n            Console.WriteLine($&quot;Gelen Cevap : {response.Message}&quot;);\r\n        }\r\n    }\r\n<\/pre>\n<p>Yukar\u0131daki kod blo\u011funu incelerseniz e\u011fer; gRPC server&#8217;a istek g\u00f6nderebilmek i\u00e7in ilgili server&#8217;\u0131n adresini dinleyen bir channel olu\u015fturulmakta ve bu channel \u00fczerinden client \u00fcretilip, aya\u011fa kald\u0131r\u0131lmaktad\u0131r. Ard\u0131ndan client \u00fczerinden server&#8217;da ki metot(SayHello) istedi\u011fi &#8216;HelloRequest&#8217; nesnesiyle birlikte tetiklenmekte ve neticede &#8216;HelloReply&#8217; response&#8217;u elde edilmektedir.<\/p>\n<h4 style=\"color:purple;\">Test Edelim<\/h4>\n<p>Uygulamay\u0131 test edebilmek i\u00e7in client ve server uygulamalar\u0131n\u0131 derleyip, aya\u011fa kald\u0131ral\u0131m ve a\u015fa\u011f\u0131daki ekran g\u00f6r\u00fcnt\u00fcs\u00fcnde oldu\u011fu gibi sonucu g\u00f6zlemleyelim:<br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi.gif\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCde-Client-ve-Server-Uygulamalari-Proto-Dosyasi-ve-Servislerin-Olusturulmasi.gif\" alt=\"gRPC&#039;de Client ve Server Uygulamalar\u0131, Proto Dosyas\u0131 ve Servislerin Olu\u015fturulmas\u0131\" width=\"800\" height=\"344\" class=\"aligncenter size-full wp-image-20508\" \/><\/a><br \/>\nEvet&#8230; G\u00f6r\u00fcld\u00fc\u011f\u00fc \u00fczere client taraf\u0131ndan yap\u0131lan istek server taraf\u0131ndan kar\u015f\u0131land\u0131 ve beklenen sonu\u00e7 elde edilmi\u015f oldu \ud83d\ude42 Tabi ki t\u00fcm bu s\u00fcre\u00e7 Http\/2 protokol\u00fc \u00fczerinden yakla\u015f\u0131k 2.5 kat daha h\u0131zl\u0131 bir \u015fekilde ceyran etti \ud83d\ude42<\/p>\n<p>Harika de\u011fil mi&#8230;<\/p>\n<p>Nihai olarak;<br \/>\nBu i\u00e7eri\u011fimizde, bir gRPC operasyonunun nas\u0131l ger\u00e7ekle\u015ftirildi\u011fini hem server hem de client tabanl\u0131 olmak \u00fczere t\u00fcm incelikleriyle ele alm\u0131\u015f ve incelemi\u015f bulunmaktay\u0131z. Sonraki i\u00e7eriklerimizde ise gRPC&#8217;de veri iletim y\u00f6ntemlerini \u00f6zelle\u015ftirilmi\u015f proto dosyalar\u0131 \u00fczerinden tek tek ele al\u0131yor olaca\u011f\u0131z.<\/p>\n<p>O halde en k\u0131sa zamanda g\u00f6r\u00fc\u015fmek \u00fczere diyelim \ud83d\ude42<\/p>\n<p>\u0130lgilenenlerin faydalanmas\u0131 dile\u011fiyle&#8230;<br \/>\n\u0130yi \u00e7al\u0131\u015fmalar&#8230;<\/p>\n<p>Not : \u00d6rnek \u00e7al\u0131\u015fma projelerini indirebilmek i\u00e7in a\u015fa\u011f\u0131daki linklere t\u0131klay\u0131n\u0131z.<br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCClientExample.zip\">gRPCClientExample<\/a><br \/>\n<a href=\"https:\/\/www.gencayyildiz.com\/blog\/wp-content\/uploads\/2021\/01\/gRPCExample.zip\">gRPCExample<\/a><\/p>\n<!-- AddThis Advanced Settings generic via filter on the_content --><!-- AddThis Share Buttons generic via filter on the_content -->","protected":false},"excerpt":{"rendered":"<p>Merhaba, Bir \u00f6nceki gRPC Nedir? Ne Ama\u00e7la ve Nas\u0131l Kullan\u0131l\u0131r? ba\u015fl\u0131kl\u0131 makalemizde gRPC&#8217;nin ne oldu\u011funa ve ne ama\u00e7la kullan\u0131ld\u0131\u011f\u0131na teorik de\u011finmi\u015ftik. Bu i\u00e7eri\u011fimizde ise gRPC ile client ve server uygulamalar\u0131n\u0131n nas\u0131l geli\u015ftirildi\u011fini, servislerin ve&#46;&#46;&#46;<!-- AddThis Advanced Settings generic via filter on get_the_excerpt --><!-- AddThis Share Buttons generic via filter on get_the_excerpt --><\/p>\n","protected":false},"author":1,"featured_media":20414,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4032],"tags":[4065,4068,4072,4074,4070,4069,4073,4071],"class_list":["post-20423","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-grpc","tag-grpc","tag-grpc-client-uygulamasi","tag-grpc-proje-dosyalari","tag-grpc-proto","tag-grpc-proto-dosyasi","tag-grpc-server-uygulamasi","tag-grpc-servislerin-olusturulmasi","tag-proto-dosyasi-nedir"],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/posts\/20423","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/comments?post=20423"}],"version-history":[{"count":75,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/posts\/20423\/revisions"}],"predecessor-version":[{"id":20516,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/posts\/20423\/revisions\/20516"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/media\/20414"}],"wp:attachment":[{"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/media?parent=20423"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/categories?post=20423"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/tags?post=20423"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}