<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Sandeep Reddy Alalla</title>
    <description>The latest articles on DEV Community by Sandeep Reddy Alalla (@sandeep1201).</description>
    <link>https://dev.to/sandeep1201</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F167465%2Fe3f2580d-fd2b-4bd4-9ea2-b6643f3bf684.jpg</url>
      <title>DEV Community: Sandeep Reddy Alalla</title>
      <link>https://dev.to/sandeep1201</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/sandeep1201"/>
    <language>en</language>
    <item>
      <title>Orchestrating a Seamless Data Ingestion Workflow with AWS Step Functions</title>
      <dc:creator>Sandeep Reddy Alalla</dc:creator>
      <pubDate>Wed, 21 Feb 2024 16:40:00 +0000</pubDate>
      <link>https://dev.to/aws-builders/orchestrating-a-seamless-data-ingestion-workflow-with-aws-step-functions-11kc</link>
      <guid>https://dev.to/aws-builders/orchestrating-a-seamless-data-ingestion-workflow-with-aws-step-functions-11kc</guid>
      <description>&lt;p&gt;Introduction:&lt;/p&gt;

&lt;p&gt;In today's data-driven world, businesses rely heavily on efficiently processing and analyzing vast amounts of data. However, orchestrating complex workflows involving data ingestion, transformation, and analysis can be challenging. Enter AWS Step Functions, a powerful service that allows you to easily coordinate and visualize workflows while simplifying the development and maintenance process. In this tech blog, we will delve into how AWS Step Functions can be employed effectively to orchestrate a seamless data ingestion workflow, ensuring reliable and scalable data processing.&lt;/p&gt;

&lt;p&gt;What are AWS Step Functions?&lt;/p&gt;

&lt;p&gt;AWS Step Functions is a managed service that enables you to build serverless workflows using a visual interface. It allows you to coordinate multiple AWS services and custom applications, making it ideal for orchestrating data ingestion workflows. With Step Functions, you can create complex workflows with conditional branching, retries, error handling, and parallel processing, all while providing a clear visualization of the entire process.&lt;/p&gt;

&lt;p&gt;Data Ingestion Workflow Overview:&lt;/p&gt;

&lt;p&gt;Before we dive into Step Functions, let's establish a high-level understanding of the data ingestion workflow we aim to orchestrate. Typically, a data ingestion workflow involves the following stages:&lt;/p&gt;

&lt;p&gt;1. Data Collection: Gathering data from various sources like databases, APIs, or external systems.&lt;/p&gt;

&lt;p&gt;2. Data Validation/Cleansing: Performing data validation to ensure quality and consistency.&lt;/p&gt;

&lt;p&gt;3. Data Transformation: Converting data into a suitable format or structure for downstream processing.&lt;/p&gt;

&lt;p&gt;4. Data Storage: Storing processed data into a suitable storage solution like Amazon S3 or a database.&lt;/p&gt;

&lt;p&gt;5. Notification: Sending notifications to relevant stakeholders upon workflow completion or failure.&lt;/p&gt;

&lt;p&gt;AWS Step Functions Orchestration:&lt;/p&gt;

&lt;p&gt;Now, let's explore how AWS Step Functions fits into this data ingestion workflow and enables seamless orchestration:&lt;/p&gt;

&lt;p&gt;1. Defining States:&lt;/p&gt;

&lt;p&gt;AWS Step Functions allows you to define each stage of the workflow as an individual state. For example, states can include "Collect Data," "Validate Data," "Transform Data," "Store Data," and "Notify Stakeholders." Each state can be associated with specific AWS services or custom code, giving you flexibility in integrating different components.&lt;/p&gt;

&lt;p&gt;2. Conditions and Branching:&lt;/p&gt;

&lt;p&gt;Step Functions supports conditional branching, allowing you to define different paths based on specific conditions. This feature is particularly useful when handling different data sources or error scenarios. For instance, if data validation fails, the workflow can take an alternative branch for error handling and notifying concerned parties.&lt;/p&gt;

&lt;p&gt;3. Error Handling and Retries:&lt;/p&gt;

&lt;p&gt;AWS Step Functions provides built-in error handling, enabling you to define how the workflow should handle errors or exceptions. You can configure retries with exponential backoff to handle transient failures in data collection or transformation stages. Additionally, error-handling states can be defined to gracefully handle and recover from failures.&lt;/p&gt;

&lt;p&gt;4. Parallelism:&lt;/p&gt;

&lt;p&gt;Parallelizing tasks within a workflow can significantly improve processing time. With Step Functions, you can leverage parallel state types, enabling concurrent execution of independent tasks. For example, you can simultaneously validate and transform multiple datasets in parallel, enhancing overall efficiency.&lt;/p&gt;

&lt;p&gt;5. Visualization and Monitoring:&lt;/p&gt;

&lt;p&gt;One of the key advantages of Step Functions is its visual representation of workflows. You can easily visualize the data ingestion workflow, understand its progress, and identify any bottlenecks or inefficiencies. Step Functions also integrates with AWS CloudWatch, allowing you to monitor and gain insights into the workflow's performance and resource utilization.&lt;/p&gt;

&lt;p&gt;Conclusion:&lt;/p&gt;

&lt;p&gt;AWS Step Functions simplify the orchestration of complex data ingestion workflows, providing a flexible and scalable solution. With Step Functions, you can easily define, manage, and visualize workflows, offering a clear understanding of data processing stages. Its built-in error handling, parallel execution, and visual monitoring capabilities allow for reliable and efficient data ingestion. By leveraging AWS Step Functions, businesses can streamline their data processing pipelines, leading to improved data quality, reduced manual efforts, and enhanced decision-making capabilities.&lt;/p&gt;

&lt;p&gt;References:&lt;/p&gt;

&lt;p&gt;- AWS Step Functions Documentation: &lt;a href="https://docs.aws.amazon.com/step-functions/"&gt;https://docs.aws.amazon.com/step-functions/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;- AWS Step Functions Developer Guide: &lt;a href="https://docs.aws.amazon.com/step-functions/latest/dg/welcome.html"&gt;https://docs.aws.amazon.com/step-functions/latest/dg/welcome.html&lt;/a&gt;&lt;/p&gt;

</description>
      <category>aws</category>
      <category>stepfunctions</category>
      <category>orchestration</category>
    </item>
    <item>
      <title>Demystifying AWS API Gateway Part01</title>
      <dc:creator>Sandeep Reddy Alalla</dc:creator>
      <pubDate>Sat, 29 Jul 2023 14:49:25 +0000</pubDate>
      <link>https://dev.to/aws-builders/demystifying-aws-api-gateway-part01-5ep5</link>
      <guid>https://dev.to/aws-builders/demystifying-aws-api-gateway-part01-5ep5</guid>
      <description>&lt;p&gt;In this series of blog posts, I will cover API gateway in general and particularly AWS API gateway, what it is, how we can use it to the full extent and what are some best practices we can follow while doing so. Before going into the details let's first discuss what is API Gateway.&lt;/p&gt;

&lt;h3&gt;
  
  
  What is API Gateway in general?
&lt;/h3&gt;

&lt;p&gt;In recent times, microservices have gained a lot of popularity with that the use of API gateway, what is it, why do we need it, and why can't we hit the microservices directly? I am assuming that you know the basics about microservices architecture and monolith architecture, if not &lt;a href="https://aws.amazon.com/compare/the-difference-between-monolithic-and-microservices-architecture/"&gt;here&lt;/a&gt; is a good place to know more about them.&lt;/p&gt;

&lt;p&gt;so what is an API gateway, this is nothing but a reverse proxy that sits between your microservices or your backend services, it acts like a single point of entry to your backend services, and it offers a lot of functionalities&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--s9q9trWq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/f6u1mpl3o38oqwigbppb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--s9q9trWq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/f6u1mpl3o38oqwigbppb.png" alt="API Gateway in action" width="637" height="395"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Single Entry Point:&lt;/strong&gt; It acts as a single point of entry to the client applications, rather than clients dealing with multiple backend or microservices they can just hit the API gateway which in turn will route the client request to the appropriate microservice.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Request Routing:&lt;/strong&gt; Based on the route URL, headers and other things API gateway will route the client requests to the correct microservice, it will also act as a load balancer.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Security and Authentication:&lt;/strong&gt; It can act as a security layer, it is capable to validate the access token by which it can handle authorization and authentication, by this it will handle invalid or unauthorized access to the backend services.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Rate Limiting and Throttling:&lt;/strong&gt; It can also help implement rate limiting on certain resources, which in turn avoids the** DDoS **attacks or it can avoid overloading of the system by which we can make sure that the system is more stable.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Caching:&lt;/strong&gt; It can also act as a cache, where it will cache the redundant calls to microservices and serves the response without actually making the call to the microservice, which will improve the latency and performance of the application.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Logging and Monitoring:&lt;/strong&gt; It can also log incoming requests and responses so that we will have a better understanding of the system behavior, this will help in troubleshooting or future enhancements&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Version Management:&lt;/strong&gt; When introducing changes to microservices, version management can be challenging. The API Gateway can handle versioning and ensure that clients interact with the correct version of the API.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I hope you got a good basic understanding of what API gateway is and how it can be useful, in upcoming posts in this series I will cover how we can achieve all these functionalities using the &lt;strong&gt;AWS API gateway&lt;/strong&gt;.&lt;/p&gt;

</description>
      <category>aws</category>
      <category>apigateway</category>
      <category>serverless</category>
    </item>
    <item>
      <title>I used chmod 777 -R / and why you should be careful or avoid doing it</title>
      <dc:creator>Sandeep Reddy Alalla</dc:creator>
      <pubDate>Fri, 17 Mar 2023 15:03:00 +0000</pubDate>
      <link>https://dev.to/aws-builders/i-used-chmod-777-r-and-why-you-should-be-careful-doing-this-5c40</link>
      <guid>https://dev.to/aws-builders/i-used-chmod-777-r-and-why-you-should-be-careful-doing-this-5c40</guid>
      <description>&lt;p&gt;As an application developer, I never cared much about Linux commands, but since I am working at a very small company now I get to do all sorts of things that I really enjoy, if you are like me then this article is for you.&lt;/p&gt;

&lt;p&gt;I recently ran &lt;strong&gt;chmod 777 -R /&lt;/strong&gt; command on one of our admin AWS EC2 instances, and this resulted in a lot of unwanted and some not-so-good things. I will detail the things that happened and some details about chmod and permissions in general in this article and by the end of this article, you will have a good understanding of these and will execute these commands with some confidence.&lt;/p&gt;

&lt;p&gt;As an application developer, I do not have 100% knowledge of Linux systems and how they work internally, but after I did this mistake I did some research and wrote this up so that I might not do the same in the future if you are reading this I might save you as well.&lt;/p&gt;

&lt;h3&gt;
  
  
  File System, user and user groups in Linux:
&lt;/h3&gt;

&lt;p&gt;Before going into the details let us, in short, discuss file systems, user and user groups in Linux, basically, on Unix based system there are permissions attached to each of the files created, you might have heard like read, write and execute. Based on these permissions a user will have access to these files and there is something called a super user who can grant or revoke access to any files on the file system. This superuser will be particularly useful when a user owns a very important directory and leaves the organization then in this case a superuser can come and change the owner of that directory(if a normal user is permitted to run some commands at the root level then this can be done using sudo.)&lt;/p&gt;

&lt;h3&gt;
  
  
  About Access Permissions on files
&lt;/h3&gt;

&lt;p&gt;Now let's discuss something related to access that can be set on files, these are either represented with alphabets or numbers&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;ls&lt;/span&gt; &lt;span class="nt"&gt;-l&lt;/span&gt; your_file_name &lt;span class="nt"&gt;--&lt;/span&gt; Command 
&lt;span class="nt"&gt;-rw-------&lt;/span&gt;@ 1 SRA 4238108 Apr 21  2022 IMG_0237.jpg &lt;span class="nt"&gt;---&lt;/span&gt; output
&lt;span class="c"&gt;# here my file name is IMG_0237.jpg&lt;/span&gt;
&lt;span class="nb"&gt;ls&lt;/span&gt; &lt;span class="nt"&gt;-ld&lt;/span&gt; your_folder_name &lt;span class="nt"&gt;--&lt;/span&gt; Command
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;So here, the line below &lt;strong&gt;ls - l&lt;/strong&gt; gave us the permissions that we have on the file, which are read and write(rw). if you want to know about a directory we can use &lt;strong&gt;ls -ld&lt;/strong&gt;. you can find more about what &lt;strong&gt;ls&lt;/strong&gt; command can do using &lt;strong&gt;man ls&lt;/strong&gt; command.&lt;/p&gt;

&lt;h3&gt;
  
  
  About how you can change Permissions, user or user group
&lt;/h3&gt;

&lt;p&gt;Now let's discuss how we can modify permissions are assign a new user or group to a certain folder or a file. This can be done using chown and chmod commands. Firstly, let's discuss chmod and the access codes that come with chmod&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;r: used to give read permission&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;w: used to give write permission&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;x: used to give execute permission&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;-r: used to remove read permission&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;-w: used to remove write permission&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;-x: and you guess it right to remove execute permission&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Alternate CodeAlternatively, we can also you numbers to represent these permission.&lt;/p&gt;

&lt;p&gt;let says you used ls -l on file and you were not satisfied with the permission on the file then you use chmod.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;chmod &lt;/span&gt;permission_you_want your_filename
&lt;span class="nb"&gt;chmod &lt;/span&gt;rwx your_filename
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now let's discuss &lt;strong&gt;chown,&lt;/strong&gt; this can be used to change user and or group on a file or directory. let's say as i said earlier a file or folder is owned by someuser that has left the company and we own want to change it to a different user and group.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;chown &lt;/span&gt;user_name:user_group_name file_or_folder_name
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Once you run this command and now want to check the user and group, you can just use ls -l or ls -ld.&lt;/p&gt;

&lt;h3&gt;
  
  
  Now what is the fuss about -R
&lt;/h3&gt;

&lt;p&gt;Up to this point, we are just either dealt with a folder or a single file, but what will you do if you want to change permission on every single file in a folder and any files in a subfolder in a folder, this is where -R(Recursive) option will come in hand.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;chmod&lt;/span&gt; &lt;span class="nt"&gt;-R&lt;/span&gt; your_access_modes folder_name
&lt;span class="nb"&gt;chmod&lt;/span&gt; &lt;span class="nt"&gt;-R&lt;/span&gt; 777 your_folder_name/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Why you should be careful
&lt;/h3&gt;

&lt;p&gt;Now let's go into the details of why we should be extra careful while running chmod 777 in general, 777 means you are giving read, write and execute permission to the user which might be ok to give to a single file, but giving to a complete folder is too risky but can be accepted to an extent but the command I ran&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;chmod&lt;/span&gt; &lt;span class="nt"&gt;-R&lt;/span&gt; 777 /
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is too risky and I think should be avoided and should be never run especially if you are an application developer, what this does is it changes permissions on every single file under root, which is every single file on your Linux machine, this gives read, write and execute permission to all the files to all the user who have access to that machine, this is a very serious security issue(these issues can be an article in itself so I am not discussing them here.). In my case how it effected us is, the machine I ran this command on, we use to run our jenkins and it impacted your CI/CD pipeline for almost two days, it messed up with the sudo permissions that other users have on this machine. In simple words it got the attention of multiple people and multiple people had to work on fixing it, so that was the impact of it in simple words.&lt;/p&gt;

&lt;h3&gt;
  
  
  In Conclusion
&lt;/h3&gt;

&lt;p&gt;But yeah you don't have to worry about it if you already ran it, there is nothing you can do about it other than fixing it. This is what my manager said to me when I confessed that I am the reason for the pipeline being done and I quote his exact words.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;I've done worse over my career -- if someone hasn't messed something up in Linux, they probably are not doing enough development.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I felt very good after reading these words but at the same time felt that I should be extra careful before doing something like this again. So, that is it for this article hope i help someone out there by writing this up, and if you want to know more about these commands I discussed above there are some great articles in fact, I read those before writing this article.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.baeldung.com/linux/why-is-chmod-r-777-destructive"&gt;why-is-chmod-r-777-destructive&lt;/a&gt;&lt;br&gt;&lt;br&gt;
&lt;a href="https://www.baeldung.com/linux/change-folder-and-content-permissions"&gt;change-folder-and-content-permissions&lt;/a&gt;&lt;br&gt;&lt;br&gt;
&lt;a href="https://www.baeldung.com/linux/advanced-file-permissions"&gt;advanced-file-permissions&lt;/a&gt;&lt;/p&gt;

</description>
      <category>aws</category>
      <category>ec2</category>
      <category>linux</category>
      <category>beginners</category>
    </item>
  </channel>
</rss>
