<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Kıvanç Bilen on Medium]]></title>
        <description><![CDATA[Stories by Kıvanç Bilen on Medium]]></description>
        <link>https://medium.com/@kvanbilen?source=rss-6135d4d09e------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*Ypi-gH5NdIHIbQPI</url>
            <title>Stories by Kıvanç Bilen on Medium</title>
            <link>https://medium.com/@kvanbilen?source=rss-6135d4d09e------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 24 Nov 2026 08:44:58 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@kvanbilen/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Using NODE_DEBUG to see http calls and write them to txt file]]></title>
            <link>https://medium.com/@kvanbilen/using-node-debug-to-see-http-calls-and-write-them-to-txt-file-1ba81d3a7692?source=rss-6135d4d09e------2</link>
            <guid isPermaLink="false">https://medium.com/p/1ba81d3a7692</guid>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[debugging]]></category>
            <dc:creator><![CDATA[Kıvanç Bilen]]></dc:creator>
            <pubDate>Thu, 05 Oct 2023 21:15:57 GMT</pubDate>
            <atom:updated>2023-10-05T21:15:57.791Z</atom:updated>
            <content:encoded><![CDATA[<p>In our application I was trying test a case which authentication endpoint should not be called more than once. What I have done is write a small code to test our API and then run it with NODE_DEBUG flag</p><pre>NODE_DEBUG=http* node test.js</pre><p>This will show the debug logs of http which is a bit dangerous to use because authentication information might be leaked.</p><p>So I decided to write the output to a txt file which is also I am not recommending. It turns out the solution is to use 2&gt;log.txt</p><pre>NODE_DEBUG=http* node test.js 2&gt;log.txt</pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1ba81d3a7692" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to debug nodejs core both c++ and js code in M2 Mac]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://medium.com/@kvanbilen/how-to-debug-nodejs-core-both-c-and-js-code-in-m2-mac-1dcc76a17c2a?source=rss-6135d4d09e------2"><img src="https://cdn-images-1.medium.com/max/1024/1*E5jMV9BMs6DuekEnTuSzqA.png" width="1024"></a></p><p class="medium-feed-snippet">I was trying to debug some code in nodejs repository and somehow could not find any post about how to debug both js and c++ same time.</p><p class="medium-feed-link"><a href="https://medium.com/@kvanbilen/how-to-debug-nodejs-core-both-c-and-js-code-in-m2-mac-1dcc76a17c2a?source=rss-6135d4d09e------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://medium.com/@kvanbilen/how-to-debug-nodejs-core-both-c-and-js-code-in-m2-mac-1dcc76a17c2a?source=rss-6135d4d09e------2</link>
            <guid isPermaLink="false">https://medium.com/p/1dcc76a17c2a</guid>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[debugging]]></category>
            <category><![CDATA[cpp]]></category>
            <dc:creator><![CDATA[Kıvanç Bilen]]></dc:creator>
            <pubDate>Mon, 02 Oct 2023 19:45:53 GMT</pubDate>
            <atom:updated>2023-10-02T19:45:53.474Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[Listen AWS SNS through lambda websocket]]></title>
            <link>https://medium.com/@kvanbilen/listen-aws-sns-through-lambda-websocket-7e14fc1856b?source=rss-6135d4d09e------2</link>
            <guid isPermaLink="false">https://medium.com/p/7e14fc1856b</guid>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[aws-lambda]]></category>
            <category><![CDATA[websocket]]></category>
            <category><![CDATA[serverless]]></category>
            <category><![CDATA[sns]]></category>
            <dc:creator><![CDATA[Kıvanç Bilen]]></dc:creator>
            <pubDate>Tue, 02 Aug 2022 12:58:53 GMT</pubDate>
            <atom:updated>2022-08-02T12:58:53.072Z</atom:updated>
            <content:encoded><![CDATA[<p>With SNS you can send notifications to mobile apps, send emails and SMS s. However there is no built in websocket endpoint, so somehow you need to implement it.</p><p>What I have done is I have created a lambda websocket api which can be connected from browsers by using serverless framework. Then in SNS screen I have set this websocket api lambda function as subscriber. Topic ARN is ARN of your SNS topic, Protocol should be AWS Lambda and in endpoint field, websocket function’s function ARN should be written.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*tMARtuJVNXB3K9qV0X1KKw.jpeg" /></figure><p>In your websocket function, payload should be checked if it is coming from SNS or API Gateway. In my implementation if it is coming from SNS then message is forwarded to all connections.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1c9f62d17a0b10f2cab407ef9d423035/href">https://medium.com/media/1c9f62d17a0b10f2cab407ef9d423035/href</a></iframe><p>I have used Prisma as ORM and PostgreSQL as database but there are nice implementations with using DynamoDB, and I think it is also possible with using redis since these DBs have TTL (time to live) per record so you don’t need to remove old records frequently.</p><p>That’s all. Please reach me for corrections or suggestions.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7e14fc1856b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Apache Pulsar as a kind of alternative to AWS SQS]]></title>
            <link>https://awstip.com/apache-pulsar-as-a-kind-of-alternative-to-aws-sqs-55d390b4a1eb?source=rss-6135d4d09e------2</link>
            <guid isPermaLink="false">https://medium.com/p/55d390b4a1eb</guid>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[aws-lambda]]></category>
            <category><![CDATA[serverless]]></category>
            <category><![CDATA[apache-pulsar]]></category>
            <category><![CDATA[sqs]]></category>
            <dc:creator><![CDATA[Kıvanç Bilen]]></dc:creator>
            <pubDate>Wed, 27 Jul 2022 13:02:39 GMT</pubDate>
            <atom:updated>2022-08-02T08:57:40.197Z</atom:updated>
            <content:encoded><![CDATA[<p>I really liked using SQS, I was trying to develop a mobile game and wanted it to be async. Users change something and I will send the request to queue then queue will trigger the function which writes to database and then function sends a message to websocket and application will know that the message is processed so everything is in sync. I have implemented this logic,</p><ul><li>mobile app sends the message to SQS with calling an API</li><li>a lambda function is set as destination</li><li>that lambda function processes the message and sends websocket message</li></ul><p>It was working well, then I realized that I ran out of my 1million free SQS requests. Then I checked the consumptions, I had 3 SQS queues and for all of them I have set 1 lambda function as destination. (Please correct me if I am wrong) I saw that in every minute something fetching messages constantly and realized that these are my lambda functions. I was thinking SQS was pushing the messages to lambda by calling an API or something else but as I understand lambda is fetching the messages.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/741/1*93so6PAXmbBWTm17kGwVgg.png" /></figure><p>I am sure there must be a way to reduce these calls like long polling etc.. However I wanted to try something else, I remember that with Apache Pulsar I can be able to process messages and send them to a topic, so I wanted to give it a try. Then I saw this <a href="https://medium.com/building-the-open-data-stack/developing-and-running-serverless-apache-pulsar-functions-4980dd250068">article</a>. Created an account on Datastax and created a stream. The things I liked about Apache Pulsar</p><ul><li>stream can be reached via websocket</li><li>message can be processed via Pulsar functions</li></ul><p>So what I did is get the message and call my lambda function inside Pulsar function.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/741/1*lvoyCnsG6WhC3vsegIYebw.png" /></figure><p>For further development I will get the success result and send it to another or same topic in Pulsar that will complete the process.</p><p>Here is my pulsar function.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/3501f591f3962f59307abcb8f585753d/href">https://medium.com/media/3501f591f3962f59307abcb8f585753d/href</a></iframe><p>There is a pattern to match when sending messages via websocket in Datastax and I want to share it too.</p><pre>{&quot;payload&quot;:&quot;a2l2YW5j&quot;}</pre><p>This is an encoded string.</p><p>I really like this approach because I can do some other stuff with the message, send it to log topic, send it to other pub/sub these are all possible.</p><p>That’s all. Please reach me for corrections or suggestions.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=55d390b4a1eb" width="1" height="1" alt=""><hr><p><a href="https://awstip.com/apache-pulsar-as-a-kind-of-alternative-to-aws-sqs-55d390b4a1eb">Apache Pulsar as a kind of alternative to AWS SQS</a> was originally published in <a href="https://awstip.com/">AWS Tip</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Global error handler for Serverless Typescript using decorators]]></title>
            <link>https://awstip.com/global-error-handler-for-serverless-typescript-using-decorators-37b6ffead9b1?source=rss-6135d4d09e------2</link>
            <guid isPermaLink="false">https://medium.com/p/37b6ffead9b1</guid>
            <category><![CDATA[decorators]]></category>
            <category><![CDATA[aws-lambda]]></category>
            <category><![CDATA[serverless]]></category>
            <category><![CDATA[typescript]]></category>
            <dc:creator><![CDATA[Kıvanç Bilen]]></dc:creator>
            <pubDate>Thu, 21 Jul 2022 11:55:01 GMT</pubDate>
            <atom:updated>2022-08-06T11:12:11.472Z</atom:updated>
            <content:encoded><![CDATA[<p>When you start a new project with serverless framework using this command</p><pre>serverless create --template aws-nodejs-typescript --path &lt;project-name&gt;</pre><p>your handler.ts file will be looking like this</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7aae1b79605a83df7fadd1ae2205b4b7/href">https://medium.com/media/7aae1b79605a83df7fadd1ae2205b4b7/href</a></iframe><p>When you want to catch the errors and return a meaningful message you need to write it for each function. In some cases it is necessary but if all the functions are using the same code block it would be good to wrap them.</p><p>However typescript is only allowing using decorators for functions if the function is a part of the class.</p><p>What I did to use decorators is, define a class and a static function and add the decorator to that function. And you can return value from the decorator.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/08c6a563d0bcaeafcb87b9929e2c629a/href">https://medium.com/media/08c6a563d0bcaeafcb87b9929e2c629a/href</a></iframe><p>In that example it is returning the same error message if the functions which decorator is applied are throwing an exception.</p><p>That’s all. Please reach me for corrections or suggestions.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=37b6ffead9b1" width="1" height="1" alt=""><hr><p><a href="https://awstip.com/global-error-handler-for-serverless-typescript-using-decorators-37b6ffead9b1">Global error handler for Serverless Typescript using decorators</a> was originally published in <a href="https://awstip.com/">AWS Tip</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to deploy AWS Lambda functions created by Serverless Typescript using GitHub Actions]]></title>
            <link>https://awstip.com/how-to-deploy-aws-lambda-functions-created-by-serverless-typescript-using-github-actions-b19285e5933a?source=rss-6135d4d09e------2</link>
            <guid isPermaLink="false">https://medium.com/p/b19285e5933a</guid>
            <category><![CDATA[github-actions]]></category>
            <category><![CDATA[typescript]]></category>
            <category><![CDATA[aws-lambda]]></category>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[serverless]]></category>
            <dc:creator><![CDATA[Kıvanç Bilen]]></dc:creator>
            <pubDate>Fri, 15 Jul 2022 08:33:47 GMT</pubDate>
            <atom:updated>2022-08-01T10:56:48.882Z</atom:updated>
            <content:encoded><![CDATA[<p>I had a problem with my internet connection, somehow my upload speed was terrible and I could not be able to deploy serverless functions from my local. Therefore I thought this is a chance to take a look GitHub Actions and implemented one.</p><p>In my case I am using prisma and every time before deployment I wanted to run migrate deploy and generate commands.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/c6a5e6eef97a61705c7fd29be9c733b3/href">https://medium.com/media/c6a5e6eef97a61705c7fd29be9c733b3/href</a></iframe><p>It is pretty simple deployment action. You can check <a href="https://docs.github.com/en/actions/security-guides/encrypted-secrets">here</a> how to create secrets. At the end you can see that it is running</p><pre>npm run-script deploy</pre><p>my scripts section in package.json is like this</p><pre>&quot;scripts&quot;: {</pre><pre>      &quot;test&quot;: &quot;mocha -r ts-node/register src/**/*.test.ts&quot;,</pre><pre>      &quot;deploy&quot;: &quot;serverless deploy&quot;</pre><pre>}</pre><p>That’s all. Please reach me for corrections or suggestions.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b19285e5933a" width="1" height="1" alt=""><hr><p><a href="https://awstip.com/how-to-deploy-aws-lambda-functions-created-by-serverless-typescript-using-github-actions-b19285e5933a">How to deploy AWS Lambda functions created by Serverless Typescript using GitHub Actions</a> was originally published in <a href="https://awstip.com/">AWS Tip</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to create a step function in AWS with Workflow Studio]]></title>
            <link>https://medium.com/@kvanbilen/how-to-create-a-step-function-in-aws-with-workflow-studio-6f15c19f0807?source=rss-6135d4d09e------2</link>
            <guid isPermaLink="false">https://medium.com/p/6f15c19f0807</guid>
            <category><![CDATA[step-functions]]></category>
            <category><![CDATA[lambda]]></category>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[serverless]]></category>
            <category><![CDATA[workflow-studio]]></category>
            <dc:creator><![CDATA[Kıvanç Bilen]]></dc:creator>
            <pubDate>Wed, 06 Jul 2022 20:09:53 GMT</pubDate>
            <atom:updated>2022-07-06T20:09:53.542Z</atom:updated>
            <content:encoded><![CDATA[<p>In my project I need to run some lambdas every hour to be followed by a logic.</p><p>The functions are</p><ul><li>get todays games</li><li>get current games</li><li>next turn functions</li></ul><p>The logic is</p><ul><li>if get todays open games result is bigger than 0,</li><li>then it will check get current games</li><li>iterate over the current games and run the games and close them</li><li>if get todays open games result is 0,</li><li>then it will call next turn functions</li></ul><p>This is the overview of my step function.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*S4CTIzQks5vdn8nxhPhILw.png" /></figure><p>get today’s games and get current games have the same response layout.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/dc02a2801bb6fdfc18d4c399ee8c18eb/href">https://medium.com/media/dc02a2801bb6fdfc18d4c399ee8c18eb/href</a></iframe><p>At the pass state “today’s games to choice”, in Input section I have checked “Transform input with parameters” and enter this value</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/a4899412c1bd7f475bd59ff563aea3b5/href">https://medium.com/media/a4899412c1bd7f475bd59ff563aea3b5/href</a></iframe><p>Then at the choice , in Input section I have checked “Filter input with Input path” and set this value</p><pre>$.value</pre><p>Because in previous state, I have set “value” and in this state I have to use “value” field as Input.</p><p>Then there are 2 conditions in choice configuration</p><pre>$.count == 0</pre><p>and</p><pre>$.count &gt; 0</pre><p>If the “count” value is 0 then it will call other lambda functions in order.</p><p>If it is greater than 0. It is calling get current games. Pass state “get current games to map” is basically the same as other pass step. Input and the values are the same.</p><p>In map state I have set “Path to items array” value as</p><pre>$.value.message</pre><p>Because I want to iterate over message values.</p><p>And the last step of this branch is calling “run game” lambda function. This function is accepting a JSON body so I have to send parameters to function. Since I have used the <a href="https://www.serverless.com/">serverless </a>typescript template, my lambda functions are accepting an APIGatewayProxyEvent. In this step I have to send a JSON which is similar to this type.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/b18394fcd683afb1c0c5f90179ceaf23/href">https://medium.com/media/b18394fcd683afb1c0c5f90179ceaf23/href</a></iframe><p>first “$” sign indicates that it will reference a node in this state’s JSON input. If we don’t use it, it will just pass “$.id” as value. However when we use “id.$” the outcome will be</p><pre>{&quot;id&quot;:2}</pre><p>Map will do the iteration and it will call the “run game” function for all the messages.</p><p>That’s all. Please reach me for corrections or suggestions.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6f15c19f0807" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Send Message with MessageAttribute to SQS queue with REST]]></title>
            <link>https://medium.com/@kvanbilen/send-message-with-messageattribute-to-sqs-queue-with-rest-3b3caf9b4a01?source=rss-6135d4d09e------2</link>
            <guid isPermaLink="false">https://medium.com/p/3b3caf9b4a01</guid>
            <category><![CDATA[aws-lambda]]></category>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[sqs-lambda]]></category>
            <category><![CDATA[sqs]]></category>
            <dc:creator><![CDATA[Kıvanç Bilen]]></dc:creator>
            <pubDate>Thu, 09 Jun 2022 12:26:21 GMT</pubDate>
            <atom:updated>2022-06-09T12:26:21.492Z</atom:updated>
            <content:encoded><![CDATA[<p>In my situation, I have a SQS queue which is configured as FIFO and I want to trigger a lambda function.</p><p>This lambda function is already have API Gateway trigger so it is exposed as a REST API. I wanted to keep both bodies of SQS message and API call same, because I am sending some custom request headers in API call and want to send this information with SQS message too. Therefore I wanted to use MessageAttribute. Since I will call SQS from a website I wanted to make SQS REST call.</p><p>Here is the message I have sent from Postman.</p><pre>curl --location --request POST &#39;<a href="https://sqs.us-east-1.amazonaws.com/484588167641/squad.fifo?Action=SendMessage&amp;MessageBody=%7B%22email%22%3A%22kivanc%40kivanc.com%22%2C%22formation%22%3A%2212-1-7-19-25-3-9-21-27-11-21%22%7D&amp;MessageAttribute.1.Name=email&amp;MessageAttribute.1.Value.DataType=String&amp;MessageAttribute.1.Value.StringValue=kivanc%40kivanc.com&#39;">https://sqs.us-east-1.amazonaws.com/xxxx/xxxx.fifo?Action=SendMessage&amp;MessageBody=%7B%22email%22%3A%22kivanc%40kivanc.com%22%2C%22formation%22%3A%2212-1-7-19-25-3-9-21-27-11-21%22%7D&amp;MessageAttribute.1.Name=email&amp;MessageAttribute.1.Value.DataType=String&amp;MessageAttribute.1.Value.StringValue=kivanc%40kivanc.com&#39;</a></pre><p>When you want to add a new MessageAttribute then they will go with</p><pre>MessageAttribute.2.Name<br>MessageAttribute.2.Value.DataType<br>MessageAttribute.2.Value.StringValue</pre><p>“DataType” s are String,Number and Binary</p><p>And the message sent will be shown in receiver like this.</p><pre>{<br>    &quot;Records&quot;: [<br>        {<br>            &quot;messageId&quot;: &quot;df68b069-8e36-415c-a6df-d4124b02ca5f&quot;,<br>            &quot;receiptHandle&quot;: &quot;AQEBNLNy1uV0UB6GKfTwVSzrekqZ498PzeMSTcurqUTKsqQ8pEpqf1Hth30XOhUKroJgA0xbizOHnFSGHRKnvN5MYYW5SKp8z/uGZQ7ZvcD0tHy7GI+C9K098hauuCA31yFBw08Jki9guIfSYILDMsKfOUFWVgg6ZUp8F8x1856SZc3tPkv93Eac0gX6CffyY6nqZvIXVnFghrQLtYlrF3myLhTP/diWDWrKtnRBRE+4WsmcwtVnSQGhjm2LQepOb4ccC1vA2U/Xh8rM+wLB4EfhCA==&quot;,<br>            &quot;body&quot;: &quot;{\&quot;email\&quot;:\&quot;<a href="/service/mailto:kivanc@kivanc.com">kivanc@kivanc.com</a>\&quot;,\&quot;formation\&quot;:\&quot;12-1-7-19-25-3-9-21-27-11-21\&quot;}&quot;,<br>            &quot;attributes&quot;: {<br>                &quot;ApproximateReceiveCount&quot;: &quot;1&quot;,<br>                &quot;SentTimestamp&quot;: &quot;1654689595174&quot;,<br>                &quot;SequenceNumber&quot;: &quot;18870344610074096128&quot;,<br>                &quot;MessageGroupId&quot;: &quot;1&quot;,<br>                &quot;SenderId&quot;: &quot;xx.xx.xx.xx&quot;,<br>                &quot;MessageDeduplicationId&quot;: &quot;6540623f853d8502dc5ee595383f5447510b05cc05cfb3642df08544dca26ab9&quot;,<br>                &quot;ApproximateFirstReceiveTimestamp&quot;: &quot;1654689595174&quot;<br>            },<br>            &quot;messageAttributes&quot;: {<br>                &quot;email&quot;: {<br>                    &quot;stringValue&quot;: &quot;<a href="/service/mailto:kivanc@kivanc.com">kivanc@kivanc.com</a>&quot;,<br>                    &quot;stringListValues&quot;: [],<br>                    &quot;binaryListValues&quot;: [],<br>                    &quot;dataType&quot;: &quot;String&quot;<br>                }<br>            },<br>            &quot;md5OfMessageAttributes&quot;: &quot;f031b4fa10d5177d350a4ca4c36d00b4&quot;,<br>            &quot;md5OfBody&quot;: &quot;86a8e2dd088c78d71812ac55182bb67a&quot;,<br>            &quot;eventSource&quot;: &quot;aws:sqs&quot;,<br>            &quot;eventSourceARN&quot;: &quot;arn:aws:sqs:us-east-1:xxxx.fifo&quot;,<br>            &quot;awsRegion&quot;: &quot;us-east-1&quot;<br>        }<br>    ]<br>}</pre><p>Then you can process the message in your lambda function.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3b3caf9b4a01" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to push .NET 6 app to Cloud Foundry with zero downtime]]></title>
            <link>https://medium.com/@kvanbilen/how-to-push-net-6-app-to-cloud-foundry-with-zero-downtime-7de08963d9df?source=rss-6135d4d09e------2</link>
            <guid isPermaLink="false">https://medium.com/p/7de08963d9df</guid>
            <category><![CDATA[cloud-foundry]]></category>
            <category><![CDATA[ibm]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <category><![CDATA[ibm-cloud]]></category>
            <dc:creator><![CDATA[Kıvanç Bilen]]></dc:creator>
            <pubDate>Thu, 07 Apr 2022 11:45:09 GMT</pubDate>
            <atom:updated>2022-04-07T11:45:09.595Z</atom:updated>
            <content:encoded><![CDATA[<h3>How to push .NET 6 app to Cloud Foundry with zero downtime</h3><p>When you are using Cloud Foundry, you are only giving the application and CF is compiling and deploying the application. So I tried to push a .NET 6 app for testing. It was pretty straight-forward. Let’s start.</p><p>Let’s create a dotnet application.</p><pre>dotnet new webapi</pre><p>Then we should create a <em>buildpack.yml</em> file in main directory of project.It should contain these information.</p><pre>dotnet-core:<br>    sdk: 6.0.x</pre><p>Then you can push it using this command. “dotnet-test” should be the app name you choose.</p><pre>cf push dotnet-test -m 128M</pre><p>“-m’ is setting memory. Since I am using free tier, in order not to exceed the memory I am setting it as 128.</p><p>If you want to push the app with zero downtime there is a flag for it named “ — strategy rolling”</p><pre>cf push dotnet-test -m 128M  --strategy rolling</pre><p>You can see zero downtime when you make calls to <em>/WeatherForecast</em> endpoint per second in postman.</p><p>Hope it helps to whomever searching for a solution.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7de08963d9df" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Connect to IBM Cloud Foundry from your local]]></title>
            <link>https://medium.com/@kvanbilen/connect-to-ibm-cloud-foundry-from-your-local-3472d2f28980?source=rss-6135d4d09e------2</link>
            <guid isPermaLink="false">https://medium.com/p/3472d2f28980</guid>
            <category><![CDATA[ibm]]></category>
            <category><![CDATA[cloud-foundry]]></category>
            <category><![CDATA[cloud]]></category>
            <category><![CDATA[ibm-cloud]]></category>
            <dc:creator><![CDATA[Kıvanç Bilen]]></dc:creator>
            <pubDate>Thu, 31 Mar 2022 12:56:33 GMT</pubDate>
            <atom:updated>2022-03-31T12:56:33.509Z</atom:updated>
            <content:encoded><![CDATA[<p>I created a IBM cloud account and will try to learn Cloud Foundry like how apps can be published, how is auto-scaling done etc. . First step for me was to connect cloud foundry environment from my local. I tried first with one time passcode then it turns out that I was giving wrong api url. These are the steps i followed;</p><p>First go to <em>Account </em>section under <em>Manage</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SOpQNWB4A2dSyvbzL9749Q.jpeg" /></figure><p>Then click <em>Cloud Foundry orgs</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IYG5GsTCzeQ55BMDDoSqzQ.jpeg" /></figure><p>You should see your organization, if you don’t have you can create one here. Then click your organization to see spaces</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uxjkThGmexOwOWDfsggdJw.jpeg" /></figure><p>You can see your spaces under the organization you clicked, you can see the <em>Region </em>here which in my case is United Kingdom.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BT_jyvFZP4ydwPPEpdkjjw.jpeg" /></figure><p>Now you know your region, we can try to connect first with cloud shell, before that click on <em>Person </em>icon and then click <em>Log in to CLI and API</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*S3Bu-YslI44s3uJv1b6WIw.jpeg" /></figure><p>You will see this pop-up, click copy icon in IBM Cloud CLI</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/921/1*aE7p5znIK9zPpqurgRXPIQ.jpeg" /></figure><p>Then see the click <em>IBM Cloud Shell</em> which you can see below. It will open a cloud shell screen.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IESxHdqk3wGpvRMK68ZF-w.jpeg" /></figure><p>Paste the command that you copied from pop-up and run, it will ask you to select a region. In my case it was eu-gb because I saw that my space was at United Kingdom, so I selected 7.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/751/1*E2Vj2v9waNhmUd_Yh3ibBQ.jpeg" /></figure><p>Then the result should be seen like this.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/751/1*jUAM2G3M446Wo-wrPqNyOg.jpeg" /></figure><p>run this command and if you selected correct region <em>CF API endpoint</em>, <em>Org </em>and <em>Space </em>will be set correctly, now you have <em>CF API endpoint</em> note this URL because you will need it for connection from your local.</p><pre>ibmcloud target --cf</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/698/1*3JH1b9mJrCTkXc33XGGivw.jpeg" /></figure><p>To use cloud foundry cli in your computer you should install cli from this link</p><p><a href="https://github.com/cloudfoundry/cli/wiki/V8-CLI-Installation-Guide">V8 CLI Installation Guide · cloudfoundry/cli Wiki</a></p><p>Then you can run this command to login cloud foundry.</p><pre>cf login -a <a href="https://api.eu-gb.cf.cloud.ibm.com/">https://api.eu-gb.cf.cloud.ibm.com</a> -u <a href="/service/mailto:kivanc_bilen@hotmail.com">&lt;</a>username&gt; -p &lt;password&gt;</pre><p>parameter after -a is the endpoint that you get from previous step</p><p>username and password is the credentials that you use to log in to ibm cloud</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/915/1*3UzyGUx3o1Mk7FdqaPenmQ.jpeg" /></figure><p>You are connected. Hope it helps to anyone struggled to connect. Feel free to reach me for correction or comments.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3472d2f28980" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>