<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
    <channel>
        <title>نوشته های snehacynixit</title>
        <link>https://virgool.io/feed/@snehacynixit</link>
        <description></description>
        <language>fa</language>
        <pubDate>2026-06-28 08:46:31</pubDate>
        <image>
            <url>https://static.virgool.io/images/default-avatar.jpg</url>
            <title>snehacynixit</title>
            <link>https://virgool.io/@snehacynixit</link>
        </image>

                    <item>
                <title>Building and Deploying a MERN Application with MongoDB Atlas and Heroku</title>
                <link>https://virgool.io/@snehacynixit/building-and-deploying-a-mern-application-with-mongodb-atlas-and-heroku-vbgfmnkryufe</link>
                <description>Introduction to MERNIn this article, I’d be building and deploying an application built with the MERN stack to Heroku.MERN which stands for MongoDB, Express, React and NodeJS is a popular tech stack used in building web applications which involves frontend work (with React), backend work (with Express and NodeJS) and a database (with MongoDB).Heroku on the other hand is a platform as a service (PaaS) that enables developers to build, run, and operate applications entirely in the cloud MongoDB online course for more skills and techniquesFor this article, we’d be using MongoDB Atlas which is a global cloud database service for modern applications. This is more secure than the MongoDB installed locally on our server and it also gives room for more resources on our servers.We’d be building a simple react project, which makes post requests to an api to add a user and can also make get requests to get all users.Building ProcessYou may already have a MERN project which is to be deployed to Heroku, but I’d go over a little project just incase you don’tBuilding React AppNote: Before we begin with our project, node must be installed on your computer. node also provides us with npm which is used for installing packages.Install create-react-appcreate-react-app is used to create a starter react app.If you do not have create-react-app installed before, type the following in the command line.npm i create-react-app -g-g flag installs the package globally.Create project directorycreate-react-app my-projectcd my-projectThe above creates a directory ‘my-project’ and installs dependencies which would be used in the react starter. After which the directory is changed to the project directory.Start project and make necessary editsnpm startThe above starts the react project, which gives you a url which you preview the project. You make necessary edits on the project like changing images or texts.Install axiosnpm i axios --saveaxios is a javascript library used to make HTTP requests easily. It would be used to send requests from the frontend (React) to the apis provided by the backendCreating the backendThe backend manages the apis, handles requests and also connects to the database.Install backend packagesnpm i express cors mongoose body-parser --saveexpress: Express is a minimal and flexible Node.js web application framework that provides a robust set of features for web applications - Documentation.cors: CORS is a node.js package for providing a Connect/Express middleware that can be used to enable CORS with various options - Documentation.mongoose: Mongoose is a MongoDB object modeling tool designed to work in an asynchronous environment. Mongoose supports both promises and callbacks - Documentation.body-parser: Node.js body parsing middleware. - Documentation.Create backend foldermkdir backendcd backendConfigure backendCreate entry point server.jsFirst, create a server.js file, which would be the entry point to the backendtouch server.jsIn server.js, type the followingconst express = require(&#039;express&#039;);const bodyParser = require(&#039;body-parser&#039;);const cors = require(&#039;cors&#039;);const path = require(&#039;path&#039;)const app = express();require(&#039;./database&#039;);-----app.use(bodyParser.json());app.use(cors());-----// APIconst users = require(&#039;/api/users&#039;);app.use(&#039;/api/users&#039;, users);-----app.use(express.static(path.join(__dirname, &#039;../build&#039;)))app.get(&#039;*&#039;, (req, res) =&gt; {    res.sendFile&#40;path.join(__dirname, &#039;../build&#039;&#41;)})-----const port = process.env.PORT || 5000;app.listen(port, () =&gt; {    console.log(`Server started on port ${port}`);});express.static delivers static files which is the one built when npm run build is ran on a react project. Remember, the built file is in the build folder.From our configuration, any request sent to /api/users will be sent to users api which we about to configureConfigure users apimkdir apitouch api/users.jsIn touch.js, add the followingconst express = require(&#039;express&#039;);const router = express.Router()-----const User = require(&#039;../models/User&#039;);-----router.get(&#039;/&#039;, (req, res) =&gt; {    User.find()        .then(users =&gt; res.json(users))        .catch(err =&gt; console.log(err))})-----router.post(&#039;/&#039;, (req, res) =&gt; {    const { name, email } = req.body;    const newUser = new User({        name: name, email: email    })    newUser.save()        .then(() =&gt; res.json({            message: &amp;quotCreated account successfully&amp;quot        }))        .catch(err =&gt; res.status(400).json({            &amp;quoterror&amp;quot: err,            &amp;quotmessage&amp;quot: &amp;quotError creating account&amp;quot        }))})module.exports = routerIn the above, we create a get and post request handler which fetches all users and posts users. Fetching and adding user to the database is aided by the User model created. Let&#x27;s create the modelCreate User modelmkdir modelstouch models/user.jsIn user.js, add the followingconst mongoose = require(&#039;mongoose&#039;);const Schema = mongoose.Schema;-----const userSchema = new Schema({    name: {        type: String,        required: true    },    email: {        type: String,        required: true    }})module.exports = mongoose.model(&amp;quotUser&amp;quot, userSchema, &amp;quotusers&amp;quot)In the above, a schema is created for the user which contains the fields of the user. At the end of the file, the model (“User”) is exported with the schema and the collection (“users”)Connect MongoDB Atlas databaseAccording to docsMongoDB Atlas is the global cloud database service for modern applications.Firstly, we’d need to register on Mongo cloud. Best MongoDB course helps you to learn along with real time projects.One thing worth noting is whitelisting your connection IP address. If this step is ignored, you won’t have access to the cluster so pay attention to that step.The cluser is a small server which would manage our collections (similar to tables in SQL databases). To connect your backend to the cluster, create a file database.js which as we can see is required in server.js, then enter the following:const mongoose = require(&#039;mongoose&#039;);const connection = &amp;quotmongodb+srv://username:&lt;password&gt;@&lt;cluster&gt;/&lt;database&gt;?retryWrites=true&amp;w=majority&amp;quotmongoose.connect(connection,{ useNewUrlParser: true, useUnifiedTopology: true, useFindAndModify: false})    .then(() =&gt; console.log(&amp;quotDatabase Connected Successfully&amp;quot))    .catch(err =&gt; console.log(err));In the connection variable, enter your username (for MongoDB cloud), your password (cluster password), your cluster (address for your cluster) and the database (name of your database). All these can be easily discovered if you followed the documentationCalling APIs on the frontendAll APIs would be made to localhost:5000 locally just as we set up in server.js. When deployed to heroku, the server would use the port provided by the server (process.env.PORT).To make things easier, React allows us to specify a proxy which requests would be sent to.Open package.json and just before the last curly brace, and add the following:&amp;quotproxy&amp;quot: &amp;quothttp://localhost:5000&amp;quotThis way, we can directly send requests to api/users, and when our site is deployed and built, the default port of our application would be used with the same api.Open App.js for React and add the followingimport React, {useState, useEffect} from &#039;react&#039;import axios from &#039;axios&#039;;-----const App = function() {    const [users, setUsers] = useState(null);    const [username, setUsername] = useState(&#039;&#039;)    const [email, setEmail] = useState(&#039;&#039;)    useEffect(() =&gt; {        axios.get(&#039;/api/users&#039;)            .then(users =&gt; setUsers(users))            .catch(err =&gt; console.log(err))    }, [])    function submitForm() {        if(username === &#039;&#039;) {            alert&#40;&#039;Please fill the username field&#039;&#41;;            return;        }        if(email === &#039;&#039;) {            alert&#40;&#039;Please fill the email field&#039;&#41;;            return;        }        axios.post(&#039;/api/users&#039;, {            username: username,            email: email        })        .then(function() =&gt; {            alert&#40;&#039;Account created successfully&#039;&#41;}            .reload()        )        .catch(function() =&gt; alert&#40;&#039;Could not creat account. Please try again&#039;&#41;)    }    return (        &lt;&gt;            &lt;h1&gt;My Project&lt;/h1&gt;            {users === null ? (                &lt;p&gt;Loading...&lt;/p&gt;            ) : (                users.length === 0 ? (                    &lt;p&gt;No user available&lt;/p&gt;                ) : (                    &lt;h2&gt;Available Users&lt;/h2&gt;                    &lt;ol&gt;                        users.map((user, index) =&gt; (                            &lt;li key={index}&gt;                                Name: {user.name} - Email: {user.email}                            &lt;/li&gt;                        ))                    &lt;/ol&gt;                )            )}            &lt;form ={submitForm}&gt;                &lt;input type=&#039;text&#039; placeholder=&#039;Enter your username&#039;/&gt;                &lt;input type=&#039;text&#039; placeholder=&#039;Enter your email address&#039;/&gt;                &lt;input type=&#039;submit&#039;&gt;            &lt;/form&gt;        &lt;/&gt;    )}export default AppuseState and useEffect hooks are used to handle state and sideEffects. What is basically happening is that the first state of users is null, and at null, &#x27;Loading...&#x27; is showed on the browser. At useEffect, [] is used to specify that at componentDidMount (when the component is mounted), make a axios request to the api which is running on localhost:5000. If the result is gotten and there is no user, &#x27;No user available&#x27; is displayed to the user else a numbered list of the users is displayed.With the form available, a post request can be made to post a new user. The state of the inputs are controlled and sent to the api on localhost:5000 on submission. After wards, the page is refreshed and the new user is displayed.Deploying to HerokuTo deploy your application to heroku, you must have a heroku account. Then go through on how to create an heroku app.First, login to heroku:heroku loginThis will redirect you to a url on the browser of which you can log in, then you can continue in the terminal.In the same react project directory, run the following:heroku createTnis would create a heroku application and also give you the url to access the application.Configure package.jsonHeroku uses your package.json file to know which scripts to run and dependencies to install for your project to run successfully.In your package.json, add the following:{    ...    &amp;quotscripts&amp;quot: {        ...        &amp;quotstart&amp;quot: &amp;quotnode backend/server.js&amp;quot,        &amp;quotheroku-postbuild&amp;quot: &amp;quotNPM_CONFIG_PRODUCTION=false npm install npm &amp;&amp; run build&amp;quot    },    ...    &amp;quotengines&amp;quot: {        &amp;quotnode&amp;quot: &amp;quot10.16.0&amp;quot    }}From the above, heroku runs a post build which as you can see installs your dependencies and runs a build of your react project. Then it starts your project with the start script which basically starts your server. And your project works fine.engines specifies the versions of engines like node and npm to install.Push to Herokugit push heroku masterThis pushes your codes to heroku. Remember to include necessary files in .gitignore.After few seconds, you site is ready. If there are any errors, you can check your terminal for results after pushing or going to your dashboard on the browser to view build logs. MongoDB online training helps you to learn more effectively.Now you can preview your site on the url heroku sent when heroku create was ran.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Mon, 07 Sep 2020 18:09:18 +0430</pubDate>
            </item>
                    <item>
                <title>Rancher — A Way to Transform Kubernetes based Cloud-Native Stacks</title>
                <link>https://virgool.io/@snehacynixit/rancher-a-way-to-transform-kubernetes-based-cloud-native-stacks-tbmutkvcbz4v</link>
                <description>Rancher is one platform for everyone who uses Kubernetes and it is an open source software platform that enables organizations to run containers in production. Rancher supports flexible user authentication plugins and comes with prebuild user authentication integration with Active Directory, Lightweight Directory Access Protocol (LDAP) and GitHub. Rancher supplies the entire software stack needed to manage the containers in production.Here are a few key points which answer, why one to prefer rancher platform:1. Container Orchestration:Container orchestration is all about managing the life cycles of containers, especially in large, dynamic environments. The beauty of container orchestration tools is that you can use them in an environment in which containers are supported. Kubernetes online course for more skills and techniques.Rancher is a complete software package for teams who adopted the container platform. It addresses the operational and security challenges arises during the management of multiple Kubernetes clusters and while providing DevOps teams with integrated tools for running containerized workloads. The rancher API is very intuitive for building customized applications and the User Interface (UI) provides the complete infrastructure of a rancher from the container level.2. Multi-Cluster Management:The Rancher was build to manage Kubernetes everywhere it runs. It can easily deploy new clusters from scratch, Amazon EKS, Google Kubernetes Engine (GKE) and Azure Kubernetes Service (AKS) or even import existing Kubernetes clusters. Rancher deploys Kubernetes clusters anywhere and on any provides. It unites the clusters under centralized authentication and access control because it is agnostic about where the resources run and you can easily bring up clusters in a different provider and deploy applications to all of them. Instead of having several independent Kubernetes deployments, Rancher unifies them as a single, managed Kubernetes Cloud. One can set up a cluster with various cloud service providers like GCP, AWS, Bare Metal, Digital ocean, Custom, Azure. It’s very easy to set up a multi-cluster for different teams in a bigger organization and you will be able to control from a single place.3. Cluster Isolation:In rancher, a group of independent servers is interconnected through a dedicated network to work as one centralized data processing resource. Clusters are capable of performing multiple complex operations by distributing workload across all the connected servers. If a server fails, then it is automatically shut down and its users are switched instantly to the other servers. In Rancher, multiple clusters is placed together where each cluster are isolated without interfering each other.4. Building Continuous Integration Environment using Docker, Jenkins, and OpenVPN:Container networking overcomes the docker network limitations, using a software-defined network that connects all docker containers under the same network as if all of them were physically connected. This feature makes it much easier to interconnect your deployed services because you don’t have to configure anything. Advantage of Rancher network using OpenVPN is that they allow any device that may run on OpenVPN client including PCs, gateways, mobile devices or embedded systems to access Rancher network easily and securely.5. Deploy Containerized Applications:Rancher repository contains numerous applications, which are easy to set up, through Rancher’s UI. The applications in this repository are based on existing Helm charts. The applications are grouped into three different sections. Helm based applications are grouped into helm library and rancher based applications are included in the rancher library. This made the user distinguish applications easily and they can select what exactly they want. This made rancher UI as user- friendly.6. Microservices benefit Rancher as an Orchestration Platform:Container orchestration platform should be easily extendable, especially when it comes to implementing a specific service provider extension. Building and deploying this extension shouldn’t be tightly coupled to the core platform. Moving out of the code to its Microservice repository, dockerizing the service, and allowing it to deploy it using the catalog, makes everything easier to maintain and support1. Moving key Rancher features into separate Microservice projects.2. Dockerizing Microservice orchestration.3. Cataloging Dockerized application templates, and enabling them for deployment through the Rancher catalog.In the future, the rancher team has planned to move the rest of Rancher’s key services to their Microservices. This will allow users to integrate the system service plugins of their choice with just a couple of clicks. kubernetes certification training along with real time projects.7. Microservices with Istio:Recent days, Istio made people to attracted towards rancher labs easily. Istio is generally built by keeping Kubernetes in mind, and it can be deployed with helm easily. Istio is the micro-service development framework. It’s a great technology, combining some of the latest ideas in distributed services architecture in an easy-to-use abstraction. The main reason why people look into Istio is, sometimes it is referred to as a “service mesh”, it has facilities for API authentication/authorization, service routing, service discovery, request monitoring, request rate-limiting, and more. It’s made up of a few modular components that can be consumed separately or as a whole.8. Alerts and Notifications:Notifiers are services that inform on alert events. You can configure notifiers to send alert notifications to staff best suited to take corrective action. Alerts are either cluster level or workload level but rancher integrates alerts with a variety of popular IT services, including Slack, Email, Pagerduty, Webhook, Wechat.Conclusion:Rancher is a complete solution for deploying and managing Kubernetes. Better than an installer or a platform, it fits perfectly with every part of your container orchestration strategy. They are easy to set up with a simple command or API call. Managed Kubernetes Cluster can be created through any platform with the following scenarios,Managed Container Providers: Amazon EKS — Elastic Kubernetes Service, GKE — Google Kubernetes Engine, AKS — Azure Kubernetes Service, Amazon ECS — Elastic Container Service.Custom Prepared Containers with Amazon AWS, GCP, MS Azure, Digital Ocean, IBM Softlayer, etc.,Bare Metal Containers — Vmware Vsphere, Cisco ACI, etc.,Rancher Kubernetes Engine.Unlike solutions from Pivotal or RedHat, Rancher runs 100% upstream Kubernetes on any cloud provider or manages any hosted Kubernetes service. One Rancher cluster manages hundreds of Kubernetes clusters. From the moment you deploy it, Rancher makes your installation more powerful by including software from the CNCF and other recognized leaders in the open source community. Many other advantages are also tied up with rancher, like continuous monitoring and logging using Fluentd, Kibana, Elasticsearch, and Grafana. Learn Kubernetes online training from industrial experts.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Wed, 02 Sep 2020 13:46:01 +0430</pubDate>
            </item>
                    <item>
                <title>Deploying Applications Using (GKE) Google Kubernetes Engine</title>
                <link>https://virgool.io/@snehacynixit/deploying-applications-using-gke-google-kubernetes-engine-r7s5qu2pnndw</link>
                <description>Google Kubernetes Engine or GKE provides a managed ecosystem for implementing, managing, and enhance the container-based apps using Google infra. The GKE or Kubernetes Engine environment includes different machines (particularly Compute Engine instances) classified together to form a container cluster. It is useful to deploy even complex web apps.In this article, we will go through Google Kubernetes Engine or GKE and deploy a sample app on a GKE cluster. Kubernetes is the most preferred container orchestration tool in present era and is useful to deploy applications delivered under packages. Moreover, most cloud providers such as AWS, Google Cloud, and Azure, have their own managed Kubernetes service offerings. Kubernetes Online Course will helps you to learn more effectively.Kubernetes Engine is powered by Kubernetes open-source cluster management system.How to deploy application in KubernetesLet us discuss the procedure of deploying application in GKE.At first, you have to login into your account and then open the “Google Cloud Platform” console. On the left side, you will find an option named Kubernetes Engine under the category “compute”.Then Click on the Quick Start button.Give Name to the ClusterThis guide helps you to develop a Kubernetes cluster with the amount of nodes you require for the application. You can make configuration to everything within this cluster.To begin from the left side, we can see the first step. Then we have to provide a name to the cluster. The name can be anything as we like.Select a LocationIn the second step we have to pick up the location for the sake of simplicity. We can select any. But while using it in production, we have to see where we are getting the lower latency from, so that it can serve end-users much faster. Now we can deploy the cluster region-wise or zone wise. The cost adds up if we use it region-wise and not on a single-zone.Set Release ChannelNext, we have to set the Release channel for it. For this we can choose the version of the Kubernetes engine in this step. Further, the Cluster release channel can&#x27;t be modified, so we have to choose carefully. Hereunder, there are three different versions - Rapid, Regular, and Stable.Rapid:On this version, we will get the fastest upgrade and also will have the latest version of Kubernetes Engine all the time. But sometimes there might be some bugs or errors that have no limitation. Thus, we can recommend that this release is not for production-grade.Regular:The Regular version is useful for customers wants to test latest releases before they qualify for production. Some known issues/errors will occur, but there will be limitations for them. Kubernetes Certification Training will help you to learn more skills and techniques.Stable:This Stable version has been tested and passes all the tests to be stable for production-grade apps. Here, users have the option to select a static version of the Kubernetes engine (GKE) by selecting the static version.Choose the right ResourcesHere, a user can use and configure his node.· The system family includes three types, and user can select according to his requirements. The memory-optimized system is useful for intensive memory load, like real-time model learning. The compute optimized is a high-performance system that may be useful for scientific modeling. There is also a general-purpose system than can perform similarly well on all assignments.· There is a type of Machine from which user can select from the range of x CPUs and x Memory. Being under free credit status and trying it for learning purposes, user should always make choice of the lowest option. Because it saves him a credit, and he can do much more using that credit.· Allowing auto-scaling means user can enhance nodes up and down. Since, we are not enabling/allowing it here as our final aim is to learn, but on production side, user can set the size according to clients.· With Telemetry, users can enable logging of their system status like any crashes, incidents, and much more.Cluster ReviewingThe user will review the settings and then clicks make a change and then create so that Google Cloud Platform will start operating the cluster. And within a minute or so the cluster will be initialized or started.After this we will try to deploy the application in GKE in the following way.Deploy sample application in KubernetesHere we will design a Hello-app using the following code snippet.Now we will install Google Cloud tool using the Google server.gcloud components install kubectlAfter installing the Kubernetes client we have to set default zone &amp; project id.gcloud config set project i-return-273913gcloud config set compute/zone us-central1-cAs we have configured the default project and computing zone, now we need authentication details for the cluster.gcloud container clusters get-credentials my-first-cluster-1Our cluster is named as “my-first-cluster”, but users can change it to their own cluster name.kubectl create deployment hello-server --image=gcr.io/google-samples/hello-app:1.0Now, we will build a deployment using name “hello-server” with the sample image of hello-server written in GoLang script hello-app: 1.0 with version 1 tag. Moreover, users have option to increase replicas by providing --replicas=3 flag to enhance pod to 3.kubectl expose deployment hello-server --type LoadBalancer --port 80 --target-port 8080Later, we can expose our deployment using a load balancer service on port 80. Now the app will be accessible for the Internet as well.kubectl get podsNAME READY STATUS RESTARTS AGEhello-server-5bfd595c65-lm5rr 1/1 Running 0 2m26sHere, we can check for pods in case replicas not provided as a default will be single pod. Users pod will be in a running state and ready to serve.kubectl get service hello-serverNAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGEhello-server LoadBalancer 10.105.2.251 35.223.166.136 80:30098/TCP 71sFurthermore, we or user can now check the running status of the GKE service that we or user have created. The pods are exposed to the internet through a Kubernetes service.While, Pods include their independent IP address which can be reached through inside the cluster. Moreover, GKE Pods are designed to be momentary, spinning up or down based on scaling needs. And whenever a Pod crashes due to any error, GKE automatically redeploys that Pod, allotting a new Pod IP address each time.This means for any Deployment, the set of IP addresses respective to the active set of Pods is dynamic always.Summing UpThus, we have reached to conclude the topic on deployment of the applications using GKE. This makes the sense of using GKE to deploy apps with good knowledge. To get more updates on this, go through the Kubernetes Online Training.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Tue, 01 Sep 2020 17:59:08 +0430</pubDate>
            </item>
                    <item>
                <title>Explain Ruby on rails MVC</title>
                <link>https://virgool.io/@snehacynixit/explain-ruby-on-rails-mvc-tfjz5nemvfh8</link>
                <description>Lots of MVC discussions ignore the web server&#x27;s role. It is therefore important to note how the controller is generated and transferred user information magically. The Web server is the invisible gateway that shuts data back and forth: users never interact directly with the controller.Super Models in ruby on railsIn Rails, models are fat. They do the heavy lifting so that the controller stays lean, mean and unaware of the specifics. Here are a few tips on the model. Learn ruby on rails online course from industrial experts.Using ActiveRecord in ruby on railsExplain Ruby on rails MVCclass User &lt; ActiveRecord::BaseendThe code &lt; ActiveRecord::Base refers to the inheritance of the lowly User model from class ActiveRecord::Base, and gets Rails magic to be queried and saved to disk.Ruby can easily handle &quot;undetermined&quot; methods, too. ActiveRecord allows &quot;find by login&quot; methods, which do not actually exist. Assuming that the field is in your database, the model must conduct a query based on the field &quot;Login.&quot; No glue required for configuration.Defining methodologies of class and instance in ruby on railsYou can define methodology by following code.def self.foo&quot;Class method&quot; # User.fooenddef bar&quot;instance method&quot; # user.barendUser Attributes in ruby on railsDaily objects in Ruby can define such attributes as follows.attribute in regular Rubyattr_accessor :name # like @namedef name=(val) # custom setter method@name = val.capitalize # clean it up before savingenddef name # custom getter&quot;Dearest &quot; + @name # make it niceendHere you have to deal with the following.Attr_accessor: name generates the methods (name= and name) for get and set on your layout. It is like providing a @name variable for the public say.Defines method name=(val) for changing how to save @name (such as validating input).Defines the name of the process to monitor how the variable is generated (such as formatting changes).Attributes in Rails can be confusing because of the magic of the database. Here you have to deal with the following.ActiveRecord grabs the fields in the database and throws them into an array of attributes. It does getters and setters by default, but to save them, you need to call user.save.If the default getter and setter are overridden, use this as follows.def length=(minutes)self[:length] = minutes * 60enddef lengthself[:length] / 60endActiveRecord defines a method (wraps write attribute and read attribute) for accessing the raw attributes]). That&#x27;s how you shift the raw data. You can&#x27;t use length redefinitiondef length # this is badlength / 60endThen that&#x27;s an endless loop. So it is for oneself. This was a mine&#x27;s particularly frustrating Rails headache-use self[:field] when in doubt. ruby on rails certification helps you to learn along with real time projects.Rails are free. You forget that you are using a database, so clean it. Well, don&#x27;t.Save templates. When you&#x27;re making a move save it. The crucial move is really easy to overlook. Update attributes(params) can also be used and key hash-&gt; value pairs transferred.After the changes reload your versions. Suppose there are a number of videos for a person. You are making a new file, pointing it to the appropriate user and calling user.videos to get a list. Will it work?Probably not. User.videos can have stale data if you&#x27;ve already queried for videos. To get a fresh query you must call user.reload. Be careful — the memory model acts like a cache which can get stale.Make New Models in ruby on railsThere are two ways of creating new objects:Unsaved Joe = User.new(:name = &gt; &quot;Sad Joe&quot;) #Save bob = User.create: (name = &gt; &quot;Happy Bob&quot;) #User.new makes a new entity, setting hashed attributes. New does not save to a database: you must explicitly call user.save. Save method will fail unless the model is correct.User.create creates a new model and saves the model to the database. Validation can fail; user.errors is a hash of the error fields and the detailed message.Note how the hash is going in. With the brace magic of Ruby,} {is not specifically required asUser = User.new(:name =&gt; &quot;kalid,&quot;:site =&gt; &#x27;instacalc.com&#x27;)Takes onUser.new({:name = &gt; &quot;kalid,&quot; = &gt; &quot;instacalc.com&quot;))The arrow (= &gt;) means a hash is moved over.In reality, these associations define methods used to look up other class items. For example, for the proper status id, &quot;user belongs to status&quot; means user.status is querying the Status. &quot;Status has many: users&quot; also means status.users must check the user table with the same status id for all. Once we declare the relationship ActiveRecord manages the magic.Use of Customized Associations in ruby on railsSuppose you need two prime and secondary statuses, then use the following.Belongs to:primary status,:model =&gt; &#x27;Status,&#x27;:foreign key =&gt; &#x27;Status id primary&#x27;Belongs to:secondary status,:model =&gt; &#x27;Status,&#x27;:foreign key =&gt;&#x27;You define a new area and reference the model and foreign key to use for searches directly. For example, user.primary status returns an object Status with the &quot;primary status id&quot; I d. Really handsome.Rapid Controllers in ruby on railsThis section is short, as controllers shouldn&#x27;t do much in addition to bossing the model and viewing around. Usually they do:Manage sessions, logins / authorization, filters, redirects, and errors.Have default methods (aggregated with ActionController). Visiting http:/localhost:3000 / user / show may attempt to call the &quot;show&quot; action if one is present, or to make show.rhtml automatically if the action is not set.Pass instance variables such as @user are passed over to view. Local variables don&#x27;t get passed (those without @).Tough to debug in ruby on railsUsing render: text = &gt; &quot;Error found&quot; and return to debug your page in print-style format. It is another good reason to bring code into models easily debuggable from the console.To transfer data between requests, use sessions: session[:variable] = &quot;data.&quot;Using Opinions in ruby on railsViews are easy to see. The Foundations:Controller actions use views with the same name (default method will show.rhtml loads)Variables (@foo) for controller instances are available in all views and partials (wow!)Using ERB to run code in a view in ruby on rails&lt; Prozent ... Percent &gt;:Run the code, but don&#x27;t print. Used for if / then / else / end and loops with array.each. Use &lt; percent if false percent &gt; Hi there &lt; percent end percent &gt; to comment out sections of HTML. You get a free blank line, since after the closing percentage you actually have a newline &gt;.&lt; Prozent-... Percent &gt;:run the file, and don&#x27;t print the newline trailing. Use this when generating XML or JSON for readability when breaking up the.html code blocks, but don&#x27;t want newlines in the output.&lt; proportion = ... Percent &gt;:Execute the code and print the return value, e.g.: &lt;% = @foo percent &gt;. Remember the @ sign for controller variables transferred to the screen, right?). Don&#x27;t put an error if statements are inside the &lt; percent =.&lt; percentage = h ... Percent &gt;:Print the code, and exit the output by html: &gt; becomes &gt;. H) (is a Ruby function, but it&#x27;s called without a parent, as Rubyists are fit for it.When you start, it&#x27;s a little confusing-run some experiments on a dummy view page.ConclusionI hope you reach a conclusion about MVC in ruby on rails. You can learn more through Ruby on rails online training.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Tue, 25 Aug 2020 16:42:30 +0430</pubDate>
            </item>
                    <item>
                <title>Explain about DataStage Information server</title>
                <link>https://virgool.io/@snehacynixit/explain-about-datastage-information-server-uqjf2gkqrkrg</link>
                <description>IBM DataStage has provided users with the SPCR (Software Product Compatibility Reports) tool where you can place and view full lists of compatible OS, device components, pre-requirements and future applications supported for Information Server versions. In this article, let us have a look at the DataStage information server. Data stage online course help you to learn more effectively.IBM DataStage Information System ArchitectureIt is a client-server architecture designed with administration, operating tools and client-based design that links server A. Level ClientIBM DataStage Information Server provides enhanced application interfaces to different positions within an organization. The client tier includes clients such as the Planner, Administrator and Operator; IBM DataStage has a DataStage and Quality stage. Besides, it also has the IBM DataStage Information Server and Web Server console.There are two broad categories of customers: Administrative and consumer customers.1. Governing ClientsThis allows for the security, licensing, logging and scheduling areas for handling.Works of administration accomplishes within the respective Web Console Server. The IBM DataStage Information Server Web Console is a browser-based interaction for administrative tasks such as security management and planned work views generation.IBM DataStage uses Administrator Server for the IBM DataStage and IBM Quality Stage task management. It uses this to list defaults on general servers, to add and remove projects. Then it also helps to set properties for tasks.2. User ClientsFor example, these clients help to perform client activities, administer, build and design jobs and also verify, run, schedule and track jobs. The IBM DataStage Information Server console is a rich user-based interface for behavior as data profiling and service-oriented app development.The IBM DataStage and the Quality Stage designer help you manage build and develop work. You can also use the Designer app to set tables and access metadata resources.On the DataStage Server, the IBM DataStage and Qualitystage Director application validates schedules, operates, and tracks work.Note: Users of Microsoft Windows XP Pro, Server 2003 and Vista are braced on 32-bit.B. Thirds of serversThis Information Server System, which includes the Resource Providers Manager for Services, Working Areas, Repository, and Information Services as follows:Service tierIBM DataStage Information Server is entirely on the shared services package, centralizing core tasks across platforms. Shared services should allow managing and controlling these works in one location, regardless of which part is used.Company and product-specific features are included in server thirds.Popular servers are useful for surveillance, monitoring, management, metadata, and reporting tasks.Within the Information Server Series, software services give tasks for specific products.IBM DataStage Information Server products have three general categories allowed access to be as follows.ConceptionRunningMet AddressArchitectural notes Layer overviewClient review, user interfaces for administration and development, and optional Bridges and Met brokers. Multiple clients can access a single Information Server if the client and server versions match.You can install multiple clients using MultiClientManager on a single workstation.Windows XP, Vista or 2003 32bit versions are requiredMetadata Repository Database stores the configuration, configurations, architecture, and runtime metadata for the Information Server. Single metadata repository defines a database for each Information Server install. Datastage administrator training helps you to learn more skills and techniques.DB2 (including or supplied to the customer) v9.5 for 64 bit and v9.1 for 32-bit.2005, and SQL ServerOracle R2: 10 g(User delivered)Popular and product-specific servicesDomain Information Server Requires Web Sphere App Server (included or supplied by the customer) Release 6.0.2 Patch Pack 27 or later only fix packsEach Server installation defines a single domain.Profile &#40;non-network&#41; standalone onlyDevice Runtime engine that includes processor, Box, connector and agent service. In a single Information Server domain, register multiple engines, provided they are in different server environments.You can install only one v8 engine on a single server but can coexist with multiple v7 DataStage engines.2. Level serverYou can make a repository to store all objects of the IBM DataStage Information Server product module, and can be shared in the suite with other devices.Customers have the opportunity to view information from their service layers and the data analysis results.3. Motor TierThis parallel runtime system performs tasks on IBM DataStage Information Server.This includes Info Server Engine, Database Agents, and Connectors &amp; PACKS.IBM DataStage Information Server engine consists of items that you add, such as the DataStage Information Server and Quality Stage. It uses tools such as ETL and Standardize.Service agents are Java processes that run behind on every IBM DataStage hosting system. We offer communications between Services and Tiers Engine.Connectors and Packaged Server Connectivity KitsThe server connects to different outlets, irrespective of whether the mainframe or applications are configured or unstructured. The connectors provide data interaction in design-time, such as searching, access to runtime, managing errors and high performance.Topologies HelpedIBM DataStage Information Server is with a broad scalable parallel software architecture that provides performance and high-level outputs. Components of the IBM DataStage Information Server dig entirely on SMP, Grid, Clusters and MPP systems to allow use of all hardware tools for access.IBM DataStage Information Server supports multiple topologies to reduce the desire for your data supplement and hardware, as follows.Two tierThree tierGridNow let us see about installation of information serverDataStage information server installationRun the installation software on any device hosting Server third parties. If you are installing it on two or more computers, install third parties in the order below.Sign in to your Computersign in as Root User for Linux / UNIXLog in as a local administrator or as a domain or a local user who has direct contact with the central admin community for Windows.For Linux / UNIX, to set file formation mask to 022: umask 022For Linux / UNIX, make sure that you are allocating enough machine resources for installation. Set a file descriptor cap to be greater than or infinite by 102400. Check the recent NOFILES kernel parameter setting, too. This parameter should be set to a value at least equal to that defined for limit.Make sure that Lock Daemon is up and running, for Linux / UNIX. Look to your OS documentation for the best way to launch daemon services when not runningStart or run either a wizard or a console or a silent mode on the installation programmed.When the installation starts, select which third parties to install. Respond to topologies associated with the feature Architecture for selecting third parties.The items for installation must select as one or more installation levels during installation.Do not install a metadata repository tier if you are using a remote DB2 server installation or have Microsoft SQL or Oracle Service used for the metadata repository database. Enable it only when using a DB2 database that comes with an Information Server installer or a pre-existing local DB2 Server.For Linux / Windows, make sure that when the Information Server program prompts the installation location. Then install the Web Sphere App Server or DB2 server in a different directory that is writable and has sufficient spaceWhen prompted for user details, make sure you are adding IDs and passwords you created earlier during planning or during pre-requirements.If you ask to pick Project Data Stage, you will choose each.If you are using non-English language, the installation program will automatically allow National Language Support; but for protection, leave the selected Install NLS and IBM DataStage Web sphere DataStage server unless you are sure of support for non-ASCII characters on your server. As after installation, you cannot stop it.Click Install to start setup. After effective installation, the zip file that includes installation log files that save to the Information Server directory. File name is dump-operating system timestamp.zip.When you have built a client tier in Windows, make sure that the correct version is Microsoft. NET Framework you are using.During your installation cycle, repeat the steps for each device.Begin an Information Server Console once you are done with the installation and arrange it for the appropriate clients.If the installation is incomplete or ineffective, fix problems with the help of deployment logs. Delete the configuration of the installation directory, and the log file.Restart the computer for windows and then run the installer again.ConclusionI hope you reach a conclusion about the IBM information server. You can learn more from DataStage online training.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Thu, 20 Aug 2020 18:40:28 +0430</pubDate>
            </item>
                    <item>
                <title>Ruby on rails application on AWS Elastic Beanstalk</title>
                <link>https://virgool.io/@snehacynixit/ruby-on-rails-application-on-aws-elastic-beanstalk-du6tlpmoww0p</link>
                <description>In the past I&#x27;ve done posts involving AWS and how to use AWS and Jekyll to launch your website. Seeing that they just had their annual London Summit (which was great by the way), I thought I &#x27;d do a post on Elastic Beanstalk on how to deploy a simple Rails device, which uses postgres.What is The Elastic beanstalk?EB or Elastic Beanstalk allows users to deploy and manage their applications quickly without having to worry about setting up the infrastructure running those applications. It takes care of load balancing, health monitoring, capacity provision and scaling, allowing you to focus a little bit more on your actual application. Currently it supports Java, PHP,. NET, Python, Node.js, and Ruby applications built. Ruby on rails online course helps you to learn more skills and techniques.The best thing about EB is that it helps you to handle that environment under one program. For instance, you could test new apps or plug-ins, live, on staging, without making an effect on your production site, which is very useful. Elastic Beanstalk is kind of the same thing, if you&#x27;re used to deploying on Heroku. When you&#x27;re confused about future charges, refer to the AWS free tier guide.Get StartedIt probably goes without saying, but make sure that you have an account with AWS. First, after you&#x27;ve installed a brew, make sure it&#x27;s modified and then download the EB CLI.$Review Brief$Download brew awsebcli$eb —releaseThe CLI 3.2.2 EB (Python 3.4.3)Just run the version command to ensure it&#x27;s all correctly installed and you should get something similar to the above.I&#x27;ll assume you&#x27;ve got your rails app ready to go, in the sense it works locally and you&#x27;re just looking to deploy it. Having that in mind, you &#x27;re going to want to initialise EB in your app directory.$init ebUpon executing the above instruction, you will be given a series of questions about the device, the first of which is about the zone you would like to set up in.Select a Region by default1) Us-East-1: Eastern USA (N. Virginia)2) us-west-1: US West (NC)3) Us-west-2: Oregon (US West)4) WE-1: EU (Ireland)5) eu-central-1: European Union (Frankfurt)6) Ap-South-1: Mumbai (Asia Pacific)7) Ap-southeast-1: Singapore (Asia Pacific)8) Asia Pacific (Sydney) ap-southeast-29) Asia Pacific (Tokyo) ap-northeast-110) Asia Pacific (Seoul) ap-northeast-211) South America (Sao Paulo): Sa-East-112) China (Beijing) cn-north-1:13) Us-east-2: Eastern USA (Ohio)14) Ca-central-1: (central) Canada15) eu-west-2: European Union (London)(3 By default):I would obviously choose 6 because I&#x27;m in hyderabad, but choose which zone is nearest to where you are.Pick an application you want to use1) AnotherAppIPReployed previously2) [Create New Request](By default 2): 2Enter Name of Application(Originally &quot;myapp&quot;):Myapp Application was created.Looks like you&#x27;re using Ruby. Is this right?(Y / n) to: yChoose edition of the app.Rubies 2.3 (Puma)Rubies 2.2 (Puma)(Puma) 3) Ruby 2.1Ruby 2.0 (Puma) 4.5) Ruby 2.3 (The Standalone Passenger)6) Ruby 2.2 (The Standalone Passenger)7) Ruby 2.1 (The Standalone Passenger)8) Ruby 2.0 (The Standalone Passenger)9) 1.9.3 in Ruby(Originally 1): 1Would you like to set up SSH to your instances?You&#x27;ll then be asked which application to use, you &#x27;d choose a new application, I have two options as I&#x27;ve already implemented it. Next you can change your app&#x27;s name but by default it will choose the root of the app. The Beanstalk will even check what&#x27;s written in your app and make a presumption, but it will still first confirm it with you. Next you&#x27;ll want to pick a ruby framework that fits the ruby version you&#x27;ve used for your device.The last option allows you to set up SSH for your instances if you want to connect and configure things remotely, it doesn&#x27;t take long to setup and will only generate a keypair to use, which will then be automatically uploaded to your generated instance on the EB console. For now, if you want to keep things simple, simply hit no.If you want to Gain In-depth Knowledge on Ruby on Rails, please go through this link ruby on rails certification training Establishing an EnvironmentNow if you log into your AWS console and head over to Elastic Beanstalk, you&#x27;ll see just sitting there to see your generated device. It&#x27;s all ready to go, we just have to upload our code actually.First thing that you have to do is create an environment.$EB Make myapp-envNext EB will do some magic and create everything you need for your environment, including an S3 bucket to store data from the environment, a security group, a load balancer, an auto-scaling group, and notifications from CloudWatch.Creating &quot;app-170629 125010&quot; application version archiveTo upload S3 to myapp/app-170629 125010.zip. That can take some time.Download Complete.Details of environment of: myapp-envName of application: the myappArea: eu-west-2Version currently in use: app-170629 125010Eco ID: e-r4aeg3mdhpPlatform: arn: aws: elasticbeanstalk: eu-west-2::platform / Puma running 64bit Amazon Linux/2.4.1 with Ruby 2.3Tier: Simple Web-ServerCNAME: AWAREUpdated: 11:50:15.449000 + 00:00:2017-06-29Presentation Status:start creatingEnvironment.Use elasticbeanstalk-eu-west-2-677471806624 as an environment data storage bucket for the Amazon S3.Security group founded named: sg-6aa8d203Load balancer created, named: awseb-e-r-AWSEBLoa-1HFNDWZGG06GCSecurity group created, called: awseb-e-r4aeg3mdhp-stack-AWSEBSecurityGroup-4BVER9RZTAEAAuto Scaling setup named: awseb-e-r4aeg3mdhp-stack-AWSEBAutoScalingLaunchConfiguration-BGBXSRWXV2CSQuality of the community has moved to Pending. Launch in progress (running for 30 seconds). There aren&#x27;t examples.Auto Scaling Group created with the name: awseb-e-r4aeg3mdhp-stack-AWSEBAutoScalingGroup-16TMUTO9XH2LDAwaiting the launch of EC2 instances. That can take a couple of minutes.Auto Scaling community policy created: arn: aws: autoscaling: eu-west-2:677471806624: scalingPolicy:3554965a-0856-4f3c-90be-cb49bace9305: autoScalingGroupName / awseb-e-r4aeg3mdhp-stack-AWSEBAutoScalingGroup-16TMUTO9XH2LD: policyName / awseb-e-r4aeg3mdhp-stack-AWSEBAutoScalingScaleUpPolicy-1NDWK7HFTSWWTSWAuto Scaling community policy created named: arn: aws: autoscaling: eu-west-2:677471806624: scalingPolicy:2e1bac83-9f60-41ca-b60d-70e83fe14992: autoScalingGroupName / awseb-e-r4aeg3mdhp-stack-AWSEBAutoScalingGroup-16TMUTO9XH2LD: policyName / awseb-e-r4aeg3mdhp-stack-AWSEBAutoScalingScaleDownPolicy-56CUZI6KKCCloudWatch alarm created named awseb-e-r4aeg3mdhp-stack-AWSEBCloudwatchAlarmHigh-MXF54IOA2SZXCloudWatch alarm produced with the name: awseb-e-r4aeg3mdhp-stack-AWSEBCloudwatchAlarmLow-V88MV4MSDP3HInstance added to your environment [i-0086bb04a1a0d57b9]Health of the environment has shifted from Pending to Ok. It finished initialization 27 seconds ago and took 3 minutes.Started environment successfully: myapp-envIt doesn&#x27;t take too long but it&#x27;s getting everything set up nicely and ready to go. You can view the status to check that it&#x27;s all working, as below.$Condition ebDetails of environment of: myapp-envName of application: the myappArea: eu-west-2Version currently in use: app-170629 125010Eco ID: e-r4aeg3mdhpPlatform: arn: aws: elasticbeanstalk: eu-west-2::platform / Puma running 64bit Amazon Linux/2.4.1 with Ruby 2.3Tier: Simple Web-ServerCNAME: the myapp-env.itykuzig2.eu-west-2.elasticbeanstalk.comUpdated: 11:54:30.354000 + 00:00:2017-06-29Status: Made readyHealth: VerdantThe last thing to do for the Rails App is to build a new environment variable SECRET KEY BASE to use, which is very easy to do.$Top rakeGeneratesConnectFirst, you &#x27;re going to want to change EB&#x27;s environment variables, it&#x27;s essential to remember that you&#x27;re going to have to re-set all of your environment variables, similar to Heroku, because you&#x27;re now running on a completely different computer.SECRET KEY BASE = generatesalongkey $eb setenvFor the new environment variable this will change the climate. The same method applies to all other env vars you may have.Set up PostgreSQL on your Instance with RailsBut at this stage your app will probably still not run, because we haven&#x27;t set up a database for it. That&#x27;s good, now we are about to do it.On the Elastic Beanstalk screen, head over to your app&#x27;s dashboard and click the &quot;Configuration&quot; key.You&#x27;ll then see the following at the bottom of the page.Pick a protected username and password to request, then strike. That will create your database.We also need to tell our instance to use postgres, and we use a yum package named postgresql93-devel to do this.You can create custom configurations for EB environments, all you need to do is create a.ebextensions folder in the root, then use the.config suffix to name the file whatever you want. Also the file should be formatted like a file of.yml. So will your db.config file look like this in this situation.Packings:Yum:-Yum:Postgresql93:]Now commit and push this update to your repo, and re-deploy your app&#x27;s latest version.Add $git to.$git commit -m &#x27;postgres setup adding .config&#x27;$git origin master push$deploy ebOnce this is done, you can use the following command to open your Web app.$opens ebAll should be set up and working now!ConclusionI hope you reach to a conclusion about Ruby on rails on AWS elastic beanstalk. You can learn more through Ruby on rails online training.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Wed, 19 Aug 2020 17:38:07 +0430</pubDate>
            </item>
                    <item>
                <title>RUBY ON RAILS: WHAT IT IS AND WHY YOU SHOULD USE IT FOR YOUR WEB APPLICATION</title>
                <link>https://virgool.io/@snehacynixit/ruby-on-rails-what-it-is-and-why-you-should-use-it-for-your-web-application-mwqbdq4e4dul</link>
                <description>Some one ask us why we choose to use Ruby on Rails to develop web applications instead of all the other web frameworks and languages. There are many reasons for our decision, but before I embark on a discussion of the advantages (and disadvantages) of Ruby on Rails, I should first explain what Ruby on Rails actually is.If you want to Gain In-depth Knowledge on Ruby On Rails, please go through this link Ruby On Rails Online TrainingRUBY ON RAILSRails is a development tool which gives web developers a framework, providing structure for all the code they write. The Rails framework helps developers to build websites and applications, because it abstracts and simplifies common repetitive tasks.Rails is written in Ruby, the programming language which is also used alongside Rails. Ruby is to Rails as PHP is to Symfony and Zend, or as Python is to Django. The appeal of Ruby to developers lies in the elegance and terseness of the language.One of key principles of Ruby on Rails development (henceforth ‘Rails’) is convention over configuration. This means that the programmer does not have to spend a lot of time configuring files in order to get setup, Rails comes with a set of conventions which help speed up development.Another characteristic of Rails is the emphasis on RESTful application design. REST (Representational State Transfer) is a style of software architecture based around the client-server relationship. It encourages a logical structure within applications, which means they can easily be exposed as an API (Application Programming Interface).From project management point of view, the Ruby on Rails community advocate Agile web development — an iterative development method, that encourages collaborative and flexible approach, which is particularly well-suited for web application development with fast-changing requirements.Over the last few years Ruby on Rails has gained a large and enthusiastic following, but let’s consider the main arguments for and against Rails.PROS AND CONS OF RAILSWHY WE PREFER TO USE RUBY ON RAILS:The process of programming is much faster than with other frameworks and languages, partly because of the object-oriented nature of Ruby and the vast collection of open source code available within the Rails community.The Rails conventions also make it easy for developers to move between different Rails projects, as each project will tend to follow the same structure and coding practices.Rails is good for rapid application development (RAD), as the framework makes it easy to accommodate changes.Ruby code is very readable and mostly self-documenting. This increases productivity, as there is less need to write out separate documentation, making it easier for other developers to pick up existing projects.Rails has developed a strong focus on testing, and has good testing frameworks.Rails and most of its libraries are open source, so unlike other commercial development frameworks there are no licensing costs involved.POTENTIAL RAILS PROBLEMS AND LIMITATIONS AND HOW TO OVERCOME THEM:Not all website hosts can support RailsWhile it is true that not all web hosts support Rails, this is primarily because it can be more resource intensive than PHP, a fact which deters low-end shared-hosting providers. However, this is by no means a deal-breaker, and of course Rails-friendly hosts do exist, for example, Heroku and EngineYard.Alternatively, you can host your Rails application on a Virtual Private Server (VPS) with Amazon EC2, Rackspace, or Linode. You will then have full control over the server and can allocate sufficient resources for your application. More info at Ruby On Rails TrainingJava and PHP are more widely used, and there are more developers in these languagesThe number of Ruby developers is growing year on year as more people switch to it from other programming languages. One of the main differences between the Ruby and other communities is the amount of open source code (gems) which is publicly available, as of writing there are 63,711 gems which you can use to enhance your application.Performance and ScalabilityThere have been concerns that Rails applications are not as fast as Java or C, which is true, but for the majority of applications it is fast enough.There is also the option of running your application under JRuby, so you have the same performance characteristics as Java.CONCLUSIONOur decision to use Rails is above all one of personal preference — we find that it works well for us by enabling the rapid development of dynamic web applications. ruby on rails certification training along with realtime projects and effective learning.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Mon, 17 Aug 2020 11:44:57 +0430</pubDate>
            </item>
                    <item>
                <title>Topology Of DataStage With Kubernetes</title>
                <link>https://virgool.io/@snehacynixit/topology-of-datastage-with-kubernetes-shbaxjnhdgal</link>
                <description>IBM® InfoSphere® Information Server products that are installed in a containerized environment provide an experience that is simpler, has better performance and scalability, and is less prone to error for processes such as in-place upgrades.The deployment of InfoSphere DataStage® in a containerized environment makes use of two components: Docker and Kubernetes. The deployment of IBM BigIntegrate uses only Docker.Docker provides the platform for application deployment by using Docker images and containers, while Kubernetes automates deploying, scaling, and operating application containers. Engine/Services/Repository tiers are deployed as containers within their respective pods More Additional Information At DataStage Online TrainingBasic concepts: DockerDocker containers provide a light-weight virtual platform that comes with base operating systems such as CentOS. Compared to traditional application-on-host environments, containers are smaller and faster. Docker containers provide virtualization on the operating system level. In the Docker image, the artifacts for InfoSphere DataStage or IBM BigIntegrate, for example, the Kerberos ticket for the IBM BigIntegrate service on Hadoop, are already included and configured to work right away. By using standard Docker commands, the Docker container of InfoSphere DataStage or IBM BigIntegrate can be brought up or taken down.Basic concepts: KubernetesKubernetes is an open source platform for managing containerized services. Kubernetes can easily orchestrate and deploy containers. Support tools for the Kubernetes platform, including monitoring, are widely available.Topology for DataStage with KubernetesInfoSphere DataStage, which includes the Data Flow Designer UI (Client Tier), the APIs (Server Tier), and the execution engine (Engine Tier) that support it, is run in a Kubernetes-enabled Docker container environment. Kubernetes is a system that functions as a “container orchestrator” or “cluster manager” and provides mechanisms for deploying, maintaining, and scaling applications. Kubernetes places containers on nodes and enables pods to find each other. Kubernetes features basic monitoring, logging, health checking, and automatic recovery from failure.The following diagram illustrates the topology.Figure 1. InfoSphere DataStage containerized topologyInstallation artifacts for InfoSphere DataStageThe deployment of InfoSphere DataStage includes the following artifacts:NamespaceNamespace provides a scope for names to be unique within it. Multiple instances of IBM InfoSphere Information Server suites representative of several dedicated environments can run in their own namespace, for example, DEV / TEST / PROD.Persistent volumesPersistent volumes function as a slice of the storage that is provisioned for use by the containers. The file system type can be NFS, glusterfs, or others.Persistent volume claimA persistent volume claim is a request for storage from a persistent volume. You can have one or many claims for storage from a persistent volume until the persistent volume runs out of space. The following example shows the persistent volume claims for the namespace test-1:Take your career to new heights of success with a DataStage, enroll for live free demo on DataStage Training[root@propeller1 YAML_Scripts]# kubectl get pvc -n test-1xmeta-pv-volume-claim    Boundxmeta-pv-volume    10Gi       RWOTopology for IBM BigIntegrateThe following diagram illustrates the topology for IBM BigIntegrate.Figure 2. IBM BigIntegrate containerized topologyThe InfoSphere Information Server engine tier Docker (Conductor) is installed on the Hadoop Edge Node with YARN Client. All of the other InfoSphere Information Server Docker tiers can be on the Edge node or outside of the cluster. There is no Kubernetes cluster since a Hadoop cluster already exists. InfoSphere Information Server binaries are on all data nodes that will run InfoSphere DataStage jobs. InfoSphere Information Server binaries are copied to data nodes at job run time using HDFS if binaries do not already exist. Data stage online course helps you to learn more skills and techniques from industrial experts.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Fri, 14 Aug 2020 17:10:23 +0430</pubDate>
            </item>
                    <item>
                <title>Ruby vs Python [Infographic + Updated for 2020]</title>
                <link>https://virgool.io/@snehacynixit/ruby-vs-python-infographic-updated-for-2020-ippyoovvhovw</link>
                <description>Python and Ruby are two of the best examples of the new generation of high-level languages which focus on simplicity and giving the programmer the ability to get things done fast, rather than syntax correctness and strict hierarchy (insert cough that sounds like “Java!” here).First the similarities. Both are high-level, object-oriented languages. Both provide an interactive shell, standard libraries, multiplatform support across Linux, Unix, Windows and other operating systems, as well as persistence support. ruby on rails online training for more skills and techniques.They are also both excellent for web development, more so when you take advantage of each language’s purpose-built web frameworks – Django for Python and Rails for Ruby. That said, Ruby on Rails is somewhat more popular as a web development tool than Django-Python. Python is favored more in the academic and scientific arenas.But beyond that they also have some major differences. They also, surprisingly, have their passionate adherents and equally passionate detractors, which has resulted in more than one flame war that’s degenerated into insults and ad hominem attacks, and even into Godwin’s law. None of that here; we’ll delve into objective assessments and stick to what each language can or cannot do.1. RubyRuby was created in 1995 by the renowned Yukihiro “Matz” Matsumoto and was influenced by C, Perl, Java and C++. It is unabashedly object-oriented; in Ruby everything is an object. Some famous sites built using Ruby (on Rails) are Twitter, Hulu, Shopify, and Groupon.From the very beginning, Ruby’s ethos has always been expressiveness, power and elegance. Its dedicated followers love it for its ‘principle of least astonishment’ - the belief that a language’s code should always cause as little confusion as possible for the developer.This guiding principle naturally leads to Ruby’s inheritance of the Perl philosophy of having more than one way to do the same thing. This is the main difference between it and Python, as we’ll see later. This in turn means that a method can have multiple names, and this could lead to confusion for newbies.2. PythonPython was created in 1991 by Guido van Rossum, inspired by a multitude of languages – C/C++, java, Lisp, Perl and ICON. Some famous Python-built websites are Google, Dropbox, Reddit, and Youtube.Unlike Ruby with its daring, somewhat adventurous nature, Python is somewhat conservative. Python abhors Ruby’s ‘many ways of doing something’ school of thought, which Ruby has in common with languages like Perl and PHP; instead Python has always stressed that there is only one best way to do something, and the language should do it that way. This results in a language strict on layout and indentation and even the amount of whitespace to use (!), which of course feels stifling to Ruby proponents. However, this regimented philosophy results in Python being supremely readable and easy to learn – in fact a good number of schools and colleges use Python as a teaching aid. Its syntax is very simple, there is little to remember, and it is thus great for beginners.Python also boasts extensive libraries and an OO nature, though this is not as ‘pure’ as Ruby’s and is similar to object orientation in C++. Some more features in which Python is superior to Ruby are listed below.Better namespace handling and use of modulesCentral use of iteratorsInternal functionsA richer set of data structures3. Web Apps: Ruby Has The EdgeWeb development remains one of the chief arenas in which Ruby and Python compete. Sure, there is server scripting, enterprise apps, mobile apps, and now machine learning, but the traditional user of these languages was the web developer. In the web applications arena, for better or for worse, Ruby has been the much more dominant player, thanks to Ruby On Rails.Ruby’s flexibility, fully promoted by its philosophy that allows multiple ways of getting the same thing accomplished, is a boon to web developers. It’s tempting to think that one simple way of doing things will work for everyone, but when the use cases that web developers diverge as widely as they do, it’s only practical to let multiple approaches flourish. In this case, the success of Ruby is reminiscent of that of C++, a much-maligned language that has succeeded so widely because it lets any team pick whichever particular subset of the language they want to use.Ruby On Rails is like Ruby on steroids, complete with extensive behind the scenes code generation and server-side metaprogramming that would make coders in a more staid language community raise eyebrows. Indeed this was the case when Django, over in Python land, emulated the Rails MVC approach and immediately faced pushback from Pythonistas who thought the framework was doing too much and getting too complex, out of line with the Pythonic emphasis on readability. Where Python programmers, and Django, went with simplicity, Ruby On Rails went with power and flexibility. True, it can get complex, but the flexibility has proven valuable for web developers. This has led to Rails being almost a rite of passage for “cutting edge” startups especially those developing B2C platforms, with a plethora of big successes such as Airbnb, Twitter, Github, and others too many to count. Rails development is insanely fast, hyper productive, and allows an early stage startup to iterate flexibly with next to no technical staff beyond a couple of core ROR developers. Ruby has also done well in devops, with tools like Chef taking full advantage of the expressive power of the scripting language.4. Ruby Vs Python: Open Source CommunityIn numbers, Python has a stunning edge, but that’s to be expected given how versatile Python is as a general-purpose programming language. Its simplicity and beginner-friendly semantics has seen it make deep inroads into just about any area of computing imaginable. The numbers speak for themselves. Python has an estimated 8.2 million developers around the world, nearly four times the estimated 1.8 million developers that Ruby has. Python’s community dwarfs Ruby in this respect.However, it’s good to be aware of how passionate the Ruby community is. This counts for a lot more than it would seem on the surface. In technical circles, the mere size of a community can be dwarfed by the passion of the community. Languages with unique features that are valued by their niche communities can have very passionate devotees.The functional family of languages like Haskell, O’Caml, and Elixir are good examples. They have tiny communities, and have had for years, but these languages have not disappeared, or their communities grown disenchanted with them. Rather, whether at Wall Street banks doing esoteric derivatives computations or in academia, their adherents have dug in even deeper and there is a lot of dynamism in these much smaller communities. Ruby’s community looks a lot like them in this respect.5. Machine Learning: Python Has The EdgeData science and machine learning are just coming into their own, but, the world is now realizing the portent power of data science, spanning all the way from big data to artificial intelligence (AI), and deep learning. Data science, and machine learning in particular, allows machines to make human-like decisions and “learn” from data to get better over time at solving a dizzyingly wide assortment of problems. A lot of value has been unlocked and, naturally, businesses from tech giants like Google to small scrappy startups, are gearing up and making strides in this lucrative field. This has proven to be Python’s most portent area of accomplishment. ruby on rails online course from industrial experts.A machine learning comparison is a nightmare scenario for just about any language when matched up against Python. Indeed, in data science circles, especially those in academia, the comparison between Ruby and Python in this sphere would not warrant much beyond a cursory dismissal of Ruby.6. Ruby Vs Python: Frameworks And LibrariesAs open source programming languages with particularly vibrant communities, both Ruby and Python have stunningly complete ecosystems, with libraries that showcase the power of the open source ethos. Just about anything you can imagine can be accomplished with freely available open source packages in either programming language.Other software distribution systems to complement these exist, and there’s excellent tooling on both sides. This is a commonality between Ruby and Python that makes the communities, so different in many ways, much closer in their approach to open source.Here’s a look at some of the top libraries in the Ruby ecosystem:Web App Frameworks - rails, sinatra, rackWeb servers - puma, unicornDatabase adapters - pg, mysql2Ruby core extensions - activesupport, hashieConcurrent processing - eventmachine, concurrent-rubyTesting tools - rspec, capybara, minitestFor Python, a who’s who of top libraries showcases the broader areas of focus where the Python programming language has made serious inroads, with a pronounced focus on areas related to data science:Django (web framework)Numpy (data science)Pandas (data science)Matplotlib (data science)Scipy (data science)Flask (web framework)Keras (machine learning, deep learning)Theano (data science)TensorFlow  (machine learning, neural networks)Scikit-learn (machine learning)PyQT (graphical user interface, GUI development)wxPython (GUI development)Pygame (video game development)Tkinter (GUI package)Python’s vast data science footprint continues to grow, and its data science libraries, in many ways the leading libraries in that respect, are growing in user adoption among Python developers.7. Ruby Vs Python: Code Side By SideRuby code and Python code has a lot in common, but there are subtler differences, especially in coding idioms driven largely by philosophical differences. Both are dynamic, interpreted languages. Both use white space and don’t have the braces made popular by C, C++, and Java, among other languages. These languages are truly versatile, however, as revealed by the paradigms they support: procedural, imperative, functional, and object-oriented. Yes, certain super functional-style code is far easier to write in Ruby than in Python, but Python, despite its drive for simplicity, can be used in ways rather similar to Ruby. Ruby, however, tends to be more expressive, and strikes a bit closer to functional languages like Lisp or Scheme than Python. Syntactically, and in many other ways, Ruby code looks a lot more like Python.Here is a simple example that illustrates how close these two really are, while being far from the clones they might look like on the surface:Fibonacci function in Rubydef fib(n)n &lt; 2 ? n : fib(n-1) + fib(n-2)endalias :fibonacci :fibFibonacci function in Pythondef fib(n):if n &lt; 2:return nelse:return fib(n-1) + fib(n-2)The Python code is just a tad simpler, while the Ruby code prefers power over simplicity. Still, both of these are much closer than would be examples in Java, C++, and other languages. What this means is that if your team ever has to switch language, moving from Ruby to Python or vice versa, while often considered inconceivable by deep enthusiasts in either software development camp, the sky would not exactly fall down. The learning curve is much easier to scale for developers and teams moving from one to the other, than it would be to move to a language such as C, C#, or even Erlang.8. ConclusionDespite the noisy arguments from both languages’ camps, it is impossible to say whether one language is overall ‘better’ than the other. It’s clear that each has some areas it is better suited to, because of its features and support from other users in the same area. ruby on rails training for more effective learning.For Ruby this is web development via the Rails framework, and for Python it is scientific and academic programming. And each has some features or capabilities that the other does not have or does not do well.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Mon, 10 Aug 2020 17:25:58 +0430</pubDate>
            </item>
                    <item>
                <title>Explain DataStage employment properties and compilation</title>
                <link>https://virgool.io/@snehacynixit/explain-datastage-employment-properties-and-compilation-myuksmxuh81q</link>
                <description>DataStage comprises one or more stages for each of the four parallel DataStage jobs we have that link to the STAGE DB database. To add connection information and link to the dataset files that DataStage pops up, you need to change the levels.Stages have editable, predefined properties. Here we must adjust some of these properties for parallel job extracting STAGEDB ASN PRODUCT CCD.Step 1View the repository tree by Architect. Pick the parallel job under SQLREP folder STAGE DB ASN PRODUCT CCD extract. Only right-click the job to delete. The parallel work configuration window opens inside the Designer Palette. Data stage online course helps you to learn more skills and techniques.Step 2Find the icon in green. This icon represents the stage for the DB2 connector. It is used for CCD table data extraction. Double-click on the button. A window for the Stage Editor opens.Step 3Click Load to fill in the fields with information about the link in the Editor. Select OK to close the scene editor and save your changes.Step 4Return to the concept window for the parallel job remove STAGE DB ASN PRODUCT CCD . Locate the icon for the connector stage in getSynchPoints DB2. Double-click then on the button.Step 5Now press the Load button to fill in the fields with the details about the link.NOTE:When you are using a non-STAGE DB database as your Apply Control Server. Then select the option for the getSynchPoints stage to load the link information, which interacts with the control tables rather than the CCD table.Step 6In doing so, Render an empty text file with InfoSphere DataStage running on the machine.Title this file as product dataset.ds, and note where it was saved.After it gets changes from the CCD table, DataStage can write changes to that register.Data sets or files are known as persistent data sets and are used to transfer data between related jobs. It is expressed through a stage in DataSet.Step 7Now open the Layout window stage editor and double-click the Insert into a dataset button.Step 8This window includes, Under the tab Properties, make sure the Target folder is open and highlights the property File = DATASETNAME.Then you can find the range of files to the right.Access the product dataset.ds file in complete pathSelect the &#x27;OK&#x27; button.All required properties for the product CCD table have now been revised. Close the Development window and save all modifications.Step 9Now find and open the parallel job STAGE DB ASN INVENTORY CCD extract from the Designer repository pane and repeat Steps 3-8.PLEASE NOTE:For the get Synch Points stage you must load the link details for the control server database into the stage editor. If you don&#x27;t have a control server STAGE DB. Datastage administrator training helps you to learn more effectively.Open all DB2 connector stages for the parallel jobs STAGE DB ST00 AQ00 getExtractRange and STAGEDB ST00 AQ00 markRangeProcessed. Then use the load feature to add STAGE DB database link detailsThe DataStage jobs are compiled and runThe Architect validates the job specification by looking at inputs, transformations, expressions and other information when DataStage work is ready to compile.Once the job compilation is successfully finished, it is ready to run. We can compile all five jobs, but only run the &quot;job chain&quot; That is because all four parallel workers are regulated at this job.Step 1Under folder SQLREP. Select by (Ctrl+Shift any of the five jobs. Then click right and choose the option Multiple work compile.Step 2In the DataStage Compilation Wizard you will see 5 jobs picked. Tap Then.Step 3Compilation starts and a &quot;Compiled successfully&quot; message is shown until complete.Step 4Now launch DataStage and the Director of Quality Stage. Select Start &gt; All programs &gt; IBM Information Server &gt; IBM Web Sphere DataStage and the Director for Quality Stage.Step 5Navigation pane of the project to the left. Tap on tab for SQLREP. This puts all five positions into the status table for the manager.Step 6Choose the sequence job STAGE DB AQ00 S00 . Tap Job &gt; Run Now, from the menu bar.If the compilation is completed, the finished status will be revealed.Now test if modified rows stored in the tables PRODUCT CCD and INVENTORY CCD have been extracted by DataStage and inserted into the two files set for the data.Step 7Go back to the Designer and open the extract job for STAGE DB ASN PRODUCT CCD. To open the Stage Editor, double-click the insert in the Data Set icon.Then press the Data button.Step 8Acknowledge the defaults in the window to view rows. Then, just press OK. A browser window will open to view data set file contents.Checking the Database Replication and DataStage integrationWe compiled and executed the work in the preceding step. In this portion, we&#x27;ll test SQL Replication and DataStage integration. We must make changes to the source table for that, and see if the same change is applied to the DataStage.Step 1To navigate to your operating system&#x27;s sqlrepl-datastage-scripts tab.Step 2Continue SQL Replication with steps like:To start the Capture program at the SALES database run the startSQLCapture.bat (Windows file.In the STAGE DB database, run the startSQLApply.bat (Windows file to start the software program.Step 3Now open a file called updateSourceTables.sql. Replace &lt; sales-connect-ID &gt; and &lt; sales-password &gt; with User ID and password to link to the SALES database.Step 4Open a window with the command DB2. Change directory to sqlrepl-datastage-tutorial\scripts, and use the given command to run problem:In the Sales database, the SQL script can perform various operations such as reviewing, adding, and deleting on both tables (PRODUCT, INVENTORY.Step 5On the machine which runs DataStage. Open the DataStage Director and perform the sequence job STAGE DB AQ00 S00 . Tap Task &gt; Run Now.Following activities will be carried out when you are running the job.The Capture program reads and inserts the six-row changes in the SALES database log into the tables on the CD.The Apply program gets the shift rows from the SALES CD tables and incorporates them into the STAGEDB CCD tables.The two DataStage extract jobs pick up the changes from the CCD tables and copy them to the files of product dataset.ds and dataset.ds inventory.You can take a look at the data sets to verify that the above steps took place.Step 6Refer to the steps below,Start Designer. Open the job of extracting STAGE DB ASN PRODUCT CCD .Then double-click on the icon Insert into a dataset. In the Editor for the point. Click The Data View.Accept the defaults in the display window line, and click OK.The dataset has three new rows in it. The easiest way to check the changes is to scroll down the Data Explorer far to the right. Look now at the last 3 rows (see picture belowThe letter I, U and D specifies the operation INSERT, UPDATE , and DELETE which resulted in each new row. The same search can be done for Inventory tableConclusionI hope you reach to a conclusion about DataStage employment properties and compilation. You can learn more through DataStage online training.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Fri, 07 Aug 2020 11:33:48 +0430</pubDate>
            </item>
                    <item>
                <title>The Advantages of Using Kubernetes and Docker Together</title>
                <link>https://virgool.io/@snehacynixit/the-advantages-of-using-kubernetes-and-docker-together-vv7gqgkq3asp</link>
                <description>Docker is a company that provides a container platform. Containers are a way to pack and isolate a piece of software with everything that it needs to run.Docker is a company that provides a container platform. Containers are a way to pack and isolate a piece of software with everything that it needs to run. I mean “isolate” in the sense that containers can assign separate resources from the host where it’s running. You might be thinking this sounds pretty, but the difference is that containers are more lightweight: they don’t need another OS to make software run.Containers let you be more agile and build secure and portable apps, which lets you save some costs in infrastructure when done well.I know that sounds like a textbook definition, so let’s see how this is beneficial by following the day in the life of John. kubernetes online training learn more effectively.Let’s say John decides to start his containers journey. He learns that Docker containers work with base images as their foundation to run an app. A base image and all its dependencies are described in a file called “Dockerfile.”  A Dockerfile is where you define something like a recipe that you usually have in docs (or in your mind) for anyone who wants to run your app. He starts with the .NET Core app, and the Dockerfile looks like this. Take a look:As you can see, it’s as if you were programming. The only difference is that you’re just defining all dependencies and declaring how to build and run the app.John needs to put that file in the root of the source code and run the following command:docker build -t dotnetapp .This command will create an image with the compiled code and all of its dependencies to run. He’ll only do the “build’ once because the idea is to make the app portable to run anywhere. So when he wants to run the app, only Docker needs to be installed. He just needs to run the following command:docker run -d -p 80:80 dotnetappThis command will start running the app on port 80 of the host. It doesn’t matter where he runs this command. As long as port 80 isn’t in use, the app will work.John is now ready to ship the app anywhere because he’s packed it in a Docker container.So why is this better? Well, John doesn’t have to worry about forgetting what he installed on his local computer or on any other server. Kubernetes online course will make you to learn more skills and techniques from industrial experts.When the team grows, a new developer will rapidly start coding. When John’s company hires an operations guy, the new hire will know what exactly what’s included in the container. And if they want to do an upgrade of the framework or some dependency, they’ll do it without worrying about affecting what’s currently working.Use Docker to pack and ship your app without worrying too much about whether the app will work somewhere else after you’ve tested it locally. If it works on your machine, it will work on others’ machines.Use Kubernetes to deploy and scale your appSo, John now just needs to go to each of the servers where he wants to ship the app and start a container. Let’s say that, in production, he has ten servers to support the traffic load. He has to run the previous command on all the servers. And if for some reason the container dies, he has to go to that server and run the command to start it again.Wait. This doesn’t sound like an improvement, right? It’s not much different than spinning up VMs. When something goes down, he’ll still need to manually go and start containers again. He could automate that task too, but he’ll need to take into consideration things like health checks and available resources. So here’s where Kubernetes comes into play.Kubernetes, as their site says, “is an open-source system for automating deployment, scaling, and management of containerized applications.” but Kubernetes is the most popular one right now. Kubernetes does the container orchestration so you don’t have to script those tasks. It’s the next step after containerizing your application, and its how you’ll run your containers at scale in production.Kubernetes will help you to deploy the same way everywhere. Why? Because you just need to say, in a declarative language, how you’d like to run containers. You’ll have a load balancer, a minimum amount of containers running, and the ability to scale up or down only when it’s needed—things that you’d otherwise need to create and configure separately. You’ll have everything you need to run at scale, and you’ll have it all in the same place.This command will create everything that’s needed, or it will just apply an update, if there is one.He can run the exact same command on this computer or any other environment, including production, and it will work the same way everywhere. But it’s not just that. docker and kubernetes training learn more effectively.Kubernetes constantly checks the state of your deployment according to the yaml definition you use. So if a Docker container goes down, Kubernetes will spin up a new one automatically. John no longer has to go to each server where the container failed to start it up again; the orchestrator will take care of that for him. And there will be something monitoring the stake to make sure it’s compliant—meaning it’s running as expected—all the time.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Tue, 04 Aug 2020 15:51:20 +0430</pubDate>
            </item>
                    <item>
                <title>Ruby on Rails vs. Node.js: Which One Is the Best Solution?</title>
                <link>https://virgool.io/@snehacynixit/ruby-on-rails-vs-nodejs-which-one-is-the-best-solution-bheqswpj9ips</link>
                <description>Ruby is dead and that everyone should stick to Node.js. That is, quite frankly, not much younger than RoR.Also, it is not a framework. It is a web-server technology that is used with JavaScript frameworks, like Express, Meteor, Sails, and databases like MongoDB. However, such giants as LinkedIn, Hapi, and PayPal gradually decided to migrate from RoR to Node.js. If you’re interested in learning more about top Node.js frameworks, please check the best Node.js frameworks. ruby on rails training helps you to learn more skills and techniques.&amp;lt;br/&amp;gt;So why the Ruby on Rails vs. Node.js confrontation is one of the most popular topics in web development? Why, if at first sight, these technologies are so different? Why are they even compared? And which one is the best? Let’s try to figure this out.Which one is the right solution: Ruby on Rails or Node.js?First of all, let’s clarify that it’s not about which tool is better, and which one is worse. Both Ruby on Rails and Node.js are the most popular server-side technologies. And both of them have their pros and cons.The thing is that each technology is better for specific purposes. And that’s precisely the goal we’re pursuing – to compare Node.js vs. RoR and understand when to choose which tool.So, to figure out all the benefits and downsides, we’ve analyzed:the popularity of the technology over the past few years;scalability;what brands use the technology;how easy it is to adopt it;performance;Having these criteria in mind, let’s begin our Ruby on Rails vs. Node.js 2020 comparison.Ruby On Rails: an overviewLet’s begin with RoR because this technology came earlier. It’s a server-side framework written in Ruby, which is a multi-purpose and quite a dynamic language. When Ruby on Rails was released in 2005, it revolutionized the web development process offering a new approach.It introduced a new software design paradigm that placed convention over configuration. Also, that eased the work for developers in many ways. For instance, now they didn’t have to work on the boilerplate code. Thus, developers could finally focus on the features and the logic of the future app rather than cumbersome coding.Today Ruby on Rails is used by:GitHubDribbleHuluCouchsurfingBasecampAirbnbAnd by over a half of million other websites. So even though the interest in this technology, comparing Ruby vs. Node, decreases, it is still quite popular and useful. If you go through job ads on Linkedin or Indeed, it’s evident that RoR developers are in very high demand. ruby on rails certification along with real time projects.What are the pros?One of the most prominent advantages of Ruby on Rails is that it is straightforward to learn. It is a well-known “schoolkids’ framework.” If you go on the Internet, you can find many success stories. People say that they just “woke up in the morning, decided to make their website/web app, then tried to learn RoR, and they got it right.”That is why RoR is a frequent choice for freelancers. If you still don’t know what you need to do within this framework, you can be assisted by RoR developers community for sure. It is rather large and experienced because this technology has existed for so long.However, as practice shows, you can solve this problem on your own. There are many branches with both typical and quite specific questions, which can arise during the Ruby on Rails usage. Whichever project you are considering, if it is built on RoR, it always has a standard structure and syntax.Another reason to stick to Ruby on Rails is that it is an excellent choice for novice web developers. You can get a truly secure solution and not participate in the self-provision of its security mechanisms.What are the cons?Ruby on Rails won’t be an excellent fit for inexperienced specialists, especially if they want to build complex apps. Then this technology can bring many struggles in terms of maintenance, safety, and reliability of the application. RoR can be an excellent instrument for beginners if they are going to build blogs or simple APIs.The fact that RoR is not the right tool for new devs is not the only disadvantage of this framework. It is slow, much slower than Node.js. However, this issue becomes visible only if you work with enormous projects with massive traffic. But if we’re talking not about a giant app with an endless number of users and requests, then Ruby on Rails might be not the real villain here.The server architecture and databases also matter a lot. If the infrastructure is well-built, even large-scale products written on RoR can be rather swift. Take Airbnb of GitHub as an example – there are no issues with the performance.Node.js: overviewIs Node.js faster than Ruby on Rails?Node.js is based on one of the fastest engines. This and the ability to write high-speed asynchronous code are considered as truly killer-features. Matching Node.js vs. RoR, we can see that the first technology wins.Yes, RoR supports the dynamic AJAX interface and allows devs to implement something similar to the asynchronous code. But unfortunately, even these features are not able to ensure the Node.js speedSo what about adopting and learning Node.js? You should realize that it is not simple. So, when you decide to work with it and plan to learn only JavaScript, you can be disappointed. Moreover, a Node.js developer needs to master the work with JS frameworks and understand how to make queries in databases. On the other hand, this web technology is a great start to become a full-stack developer.However, if you already know JS, learning Node.js is a walk in a park. And if you have some experience with C++ or Java, it can be even more comfortable for you.What are the cons?Now let’s talk about all the disadvantages we at Jelvix noted working with Node.js. First of all, this tool is exceptionally inconsistent. As far as its API is concerned, it changes continually, making this technology not quite stable to work with. Of course, it can get improved in the future. For now, we have to work with this inconvenience.If you’re building a CPU intensive application, you should choose Ruby on Rails, because Node.js is not the solution here. It can result in significant performance issues if your application has to process images or render graphics. These processes need multiple CPUs. But because Node.js has a single-threaded processing mechanism, it can bring you to the enormous resource demand. ruby on rails online training will help you to learn more effectively.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Sat, 01 Aug 2020 17:20:47 +0430</pubDate>
            </item>
                    <item>
                <title>Ruby on Rails vs. Node.js: Which One Is the Best Solution?</title>
                <link>https://virgool.io/@snehacynixit/ruby-on-rails-vs-nodejs-which-one-is-the-best-solution-tg5nep3wtsig</link>
                <description>Ruby is dead and that everyone should stick to Node.js. That is, quite frankly, not much younger than RoR.Also, it is not a framework. It is a web-server technology that is used with JavaScript frameworks, like Express, Meteor, Sails, and databases like MongoDB. However, such giants as LinkedIn, Hapi, and PayPal gradually decided to migrate from RoR to Node.js. If you’re interested in learning more about top Node.js frameworks, please check the best Node.js frameworks. ruby on rails training helps you to learn more skills and techniques.&lt;br/&gt;So why the Ruby on Rails vs. Node.js confrontation is one of the most popular topics in web development? Why, if at first sight, these technologies are so different? Why are they even compared? And which one is the best? Let’s try to figure this out.Which one is the right solution: Ruby on Rails or Node.js?First of all, let’s clarify that it’s not about which tool is better, and which one is worse. Both Ruby on Rails and Node.js are the most popular server-side technologies. And both of them have their pros and cons.The thing is that each technology is better for specific purposes. And that’s precisely the goal we’re pursuing – to compare Node.js vs. RoR and understand when to choose which tool.So, to figure out all the benefits and downsides, we’ve analyzed:the popularity of the technology over the past few years;scalability;what brands use the technology;how easy it is to adopt it;performance;Having these criteria in mind, let’s begin our Ruby on Rails vs. Node.js 2020 comparison.Ruby On Rails: an overviewLet’s begin with RoR because this technology came earlier. It’s a server-side framework written in Ruby, which is a multi-purpose and quite a dynamic language. When Ruby on Rails was released in 2005, it revolutionized the web development process offering a new approach.It introduced a new software design paradigm that placed convention over configuration. Also, that eased the work for developers in many ways. For instance, now they didn’t have to work on the boilerplate code. Thus, developers could finally focus on the features and the logic of the future app rather than cumbersome coding.Today Ruby on Rails is used by:GitHubDribbleHuluCouchsurfingBasecampAirbnbAnd by over a half of million other websites. So even though the interest in this technology, comparing Ruby vs. Node, decreases, it is still quite popular and useful. If you go through job ads on Linkedin or Indeed, it’s evident that RoR developers are in very high demand. ruby on rails certification along with real time projects.What are the pros?One of the most prominent advantages of Ruby on Rails is that it is straightforward to learn. It is a well-known “schoolkids’ framework.” If you go on the Internet, you can find many success stories. People say that they just “woke up in the morning, decided to make their website/web app, then tried to learn RoR, and they got it right.”That is why RoR is a frequent choice for freelancers. If you still don’t know what you need to do within this framework, you can be assisted by RoR developers community for sure. It is rather large and experienced because this technology has existed for so long.However, as practice shows, you can solve this problem on your own. There are many branches with both typical and quite specific questions, which can arise during the Ruby on Rails usage. Whichever project you are considering, if it is built on RoR, it always has a standard structure and syntax.Another reason to stick to Ruby on Rails is that it is an excellent choice for novice web developers. You can get a truly secure solution and not participate in the self-provision of its security mechanisms.What are the cons?Ruby on Rails won’t be an excellent fit for inexperienced specialists, especially if they want to build complex apps. Then this technology can bring many struggles in terms of maintenance, safety, and reliability of the application. RoR can be an excellent instrument for beginners if they are going to build blogs or simple APIs.The fact that RoR is not the right tool for new devs is not the only disadvantage of this framework. It is slow, much slower than Node.js. However, this issue becomes visible only if you work with enormous projects with massive traffic. But if we’re talking not about a giant app with an endless number of users and requests, then Ruby on Rails might be not the real villain here.The server architecture and databases also matter a lot. If the infrastructure is well-built, even large-scale products written on RoR can be rather swift. Take Airbnb of GitHub as an example – there are no issues with the performance.Node.js: overviewIs Node.js faster than Ruby on Rails?Node.js is based on one of the fastest engines. This and the ability to write high-speed asynchronous code are considered as truly killer-features. Matching Node.js vs. RoR, we can see that the first technology wins.Yes, RoR supports the dynamic AJAX interface and allows devs to implement something similar to the asynchronous code. But unfortunately, even these features are not able to ensure the Node.js speedSo what about adopting and learning Node.js? You should realize that it is not simple. So, when you decide to work with it and plan to learn only JavaScript, you can be disappointed. Moreover, a Node.js developer needs to master the work with JS frameworks and understand how to make queries in databases. On the other hand, this web technology is a great start to become a full-stack developer.However, if you already know JS, learning Node.js is a walk in a park. And if you have some experience with C++ or Java, it can be even more comfortable for you.What are the cons?Now let’s talk about all the disadvantages we at Jelvix noted working with Node.js. First of all, this tool is exceptionally inconsistent. As far as its API is concerned, it changes continually, making this technology not quite stable to work with. Of course, it can get improved in the future. For now, we have to work with this inconvenience.If you’re building a CPU intensive application, you should choose Ruby on Rails, because Node.js is not the solution here. It can result in significant performance issues if your application has to process images or render graphics. These processes need multiple CPUs. But because Node.js has a single-threaded processing mechanism, it can bring you to the enormous resource demand. ruby on rails online training will help you to learn more effectively.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Sat, 01 Aug 2020 17:17:56 +0430</pubDate>
            </item>
                    <item>
                <title>How Kubernetes namespaces manage cluster resources?</title>
                <link>https://virgool.io/@snehacynixit/how-kubernetes-namespaces-manage-cluster-resources-s9htbakdwhjh</link>
                <description>Kubernetes clusters can manage a huge amount of independent workloads simultaneously and organizations usually choose to deploy projects built by isolated teams to distributed clusters. Even with relatively light usage, the number of deployed objects may become awkward very fast. Moreover, they may also slow down operational responsiveness and enhance the chance of high-risk mistakes.Kubernetes uses the namespaces concept to deal with the complex objects organizing within a cluster. Name spaces allow users to gather objects together to filter and control them as a unit. Learn Kubernetes online course more effectively.A Kubernetes cluster can be isolated into various name spaces. If a container is built in a namespace includes the default CPU limit, and the container doesn’t mention its own CPU limit, then the container is given the default CPU limit. They also assign a default CPU request under certain conditions.Moreover, the user needs a Kubernetes cluster, and the kubectl command-line tool must be arranged to contact the cluster.Functionality of NamespaceThe following are the few important functions of a Namespace within Kubernetes −Name spaces usually help in pod-to-pod contact using the same namespace.These are virtual clusters that fit on top of the same cluster physically.Besides, they also provide logical separation between different teams and their environmentsDefault NamespaceBy default, a cluster will represent a default namespace while setting up the cluster. This helps to hold the default pack of Pods, Services, and Deployments used by the cluster.For example, you have a fresh cluster; and you can inspect the available namespaces by performing the following:kubectl get namespacesNAME     STATUS    AGEDefault    Active     14mCreate a NamespaceLet us imagine a visual where an entity is using a shared Kubernetes cluster for building and producing use cases.The development team may like to manage space within the cluster. Here, they could get a visual of the list of Pods, Services, and implements they use to build and run applications. In this space, many resources come and go, and the restrictions on who may not modify resources are relaxed to enable faster development.The operations team would like to manage space within the cluster. Here they can implement strict protocols on who can or cannot alter the set of Pods, Services, and Deployments that run the production site.It requires the creation of a namespace so that the resources we create in this exercise are separate from the rest of the cluster. The following is;kubectl create namespace default-cpu-exampleCreate pods in each namespaceA Kubernetes namespace gives the opportunity for pods, services, and deployments within the cluster.However, users interacting with one name space cannot see other namespace content.kubectl config viewapiVersion: v1clusters:- cluster:certificate-authority-data: REDACTEDserver: https://130.211.122.180name: lithe-cocoa-92103_kubernetescontexts:- context:cluster: lithe-cocoa-92103_kubernetesuser: lithe-cocoa-92103_kubernetesname: lithe-cocoa-92103_kubernetescurrent-context: lithe-cocoa-92103_kuberneteskind: Configpreferences: {}users:- name: lithe-cocoa-92103_kubernetesuser:client-certificate-data: REDACTEDclient-key-data: REDACTEDtoken: 65rZW78y8HbwXXtSXuUw9DbP4FLjHi4b- name: lithe-cocoa-92103_kubernetes-basic-authuser:password: h5M0FtUUIflBSdI7username: adminkubectl config current-contextlithe-cocoa-92103_kubernetesIn this context, the next step defines a context for the kubectl client to work in each name space. Besides, the values of cluster and user fields are copied from the existing context.kubectl config set-context dev --namespace=development \--cluster=lithe-cocoa-92103_kubernetes \--user=lithe-cocoa-92103_kuberneteskubectl config set-context prod --namespace=production \--cluster=lithe-cocoa-92103_kubernetes \--user=lithe-cocoa-92103_kubernetesAs a default, the above commands/code adds two contexts that are saved into the file .kube/configCreate a LimitRange and a PodThe following is the configuration file for a LimitRange object. The configuration states a default CPU request and a CPU limit.apiVersion: v1kind: LimitRangemetadata:name: cpu-limit-rangespec:limits:- default:cpu: 1defaultRequest:cpu: 0.5type: ContainerKubernetes namespace best practicesNamespaces within Kubernetes serve various purposes -- from allowing teams to share a single cluster to applying resource allocations. Kubernetes certification training along with real time projects.For instance, with Kubernetes namespaces, many IT teams are able to logically separate build, test and production ecosystems. Moreover, name spaces also provide managerial control over resources, via resource allocations and limits.When an IT admin sets up a cluster, four different name spaces are automatically created:a) Default- All the resource implements without a namespace are deployed under this name.b) kube-system-This name space holds Kubernetes system setups and deployments crucial to its cluster.c) kube-public- This is open to all users with read-only access but hired for system usage.d) kube-node-lease- Here, all nodes include a related Lease object in this namespace.A Lease improves the rendition of the node heartbeats, messages that nodes pass to the node controller to show availability - as the cluster extends.Let&#x27;s dive in-depth and understand how to work with name spaces. As a pre-requirement, we should have a Kubernetes cluster up and running before trying the commands/code.Run the below commands to get the list of all namespaces, or a relevant Kubernetes namespace:kubectl get namespaces kubectl get namespaces &lt;name of namespace&gt;Moreover, to get detail information about a name space, the describe command is useful:kubectl describe namespaces &lt;name of namespace&gt;Create resources in namespacesTo create a resource within a certain namespace that already exists, send the name of the name space as logic to the -n or -- namespace parameter in the command:kubectl create deployment my-nginx --image nginx --namespace webserverThe --all-namespaces switch framework will register any resources within all the name spaces, like the below command:kubectl get pods --all-namespacesNonetheless, this method doesn&#x27;t provide the precise list of all the resources within-cluster, as all resources are not arranged within a namespace. For example, resources like nodes, cluster roles and persistent volumes, a low-level one, are not present in any namespace. To register all those resources without having a namespace, the following command is issued:kubectl api-resources --namespaced=falseSet namespace preferenceIT admins can set up a namespace preference to recall all the commands executed afterward. This removes the need to clearly define name space names with all kubectl commands.Create a new namespaceThe namespace creation is very simple: Run the following command –kubectl create namespace &lt;name of namespace&gt;,And place the name of the namespace you need to create.Note: Namespaces are not hierarchical; so we cannot build a namespace within other namespaces.Praveen KumarPraveen KumarSet namespace preferencePraveen KumarDelete a namespaceTo delete a namespace we use the below command;kubectl delete namespaces &lt;name of namespace&gt;This will also erase any Kubernetes resources under the namespace held or exist.Namespace granularityThere, a common question I got is how many Namespaces need to create and for what purpose? Create many Namespaces and they get in the way, but making too few and we miss out on the benefits.Moreover, the creation of Namespace depends upon organization structure—from small teams to mature enterprise, each has its own structure. Depending on the situation, the business can adopt the relevant Namespace action plan.Cross Namespace communicationMostly namespaces are “hidden” from one another, but they are not completely separated as a default. Service within one Name-space can speak to another Name-space service well. Suppose, to get team service within our Namespace, we should contact another team’s service within another Name-space.Moreover, The Kubernetes namespace is useful for a small team, rapidly growing teams, large companies, and big enterprises.ConclusionNamespaces can help notably with arranging the Kubernetes resources and can enhance the velocity of the teams working. That’s in this article for now. I hope you got a fundamental idea of namespace through this article. To get more updates and skills in this regard, one can opt for Kubernetes Online Training.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Fri, 31 Jul 2020 13:59:45 +0430</pubDate>
            </item>
                    <item>
                <title>Cypress for Ruby on Rails developers</title>
                <link>https://virgool.io/@snehacynixit/cypress-for-ruby-on-rails-developers-eg6ul0tncygg</link>
                <description>The web has evolved and so did Ruby on Rails. The framework now provides improved JavaScript tooling, including integrations for both yarn package manager and webpack module bundler - de facto choice in the JavaScript community. Out of the box support for these tools facilitates creation of rich client applications. We can now easier than ever build Rails-backed applications with modern tools like Vue, React and Angular.However, as we develop our applications with modern JavaScript libraries, a new concern emerges. Feature specs that once brought confidence are now becoming increasingly brittle. Specs that once steadily navigated through almost static web pages now stumble and fall in an asynchronous world of JavaScript. ruby on rails training helps you to learn more skills and techniques from industrial experts.Hence, similarly to how webpack and yarn were previously introduced to build modern applications, we further introduce Cypress to test them. Particularly, in this post, we look at Cypress as an alternative tool for writing and executing feature specs. We explore the key points that make it stand out among other web automation tools. Finally, we demonstrate how to integrate Cypress into a Ruby on Rails development cycle by setting up tests in both local and CI environments.CypressCypress is a JavaScript end-to-end testing framework. It is an all-in-one solution that enables one to both write and execute tests that run in the browser. In a Rails project, Cypress takes place of both Capybara and the underlying web driver.cypressCypress vs SeleniumWithout doubt, Capybara is the most popular and widely adopted solution for integration testing in Rails. It provides a robust interface to communicate with the browser through a web driver. Although Capybara is agnostic of the installed driver, Selenium WebDriver is the prevailing choice among Rails developers. As Selenium is the most widespread solution also beyond Rails, it is therefore important to understand the difference between Cypress and the combination of Capybara/Selenium.The key difference between Cypress and Selenium lies in their ways of communication with the browser, i.e. browser automation. With Selenium, all communications are done through an external to the browser driver (the WebDriver). To simulate user actions, Selenium queries the browser by sending remote calls through the network and then extracting the desired information from the responses. Cypress, on the other hand, doesn’t involve any network communication. It lives directly in the browser and runs the tests in the same run-loop as the client application. That is, Cypress tests are right there - in the browser, sharing the same context with your application.As an outside process, Selenium is not able to react to events in the same run-loop. Events are thus processed asynchronously, can be overlooked and network delays may be introduced. This may lead to test flakiness and longer execution times.In contrast, by sharing the same JavaScript event-loop with your application, Cypress is synchronously notified of all events as they occur leading to more reliable test execution. Removing the network layer allows Cypress to execute tests as fast as the browser is capable of rendering.The browser-integrated architecture of Cypress accounts for it’s quick and reliable test execution. Sounds promising. But let’s see it for ourselves. Next move: install Cypress in a Rails project. ruby on rails online course from industrial experts.Cypress on Rails: hands-on experienceApplication setupWe want to quickly bootstrap a Rails application with some logic, data, and views already in place so that we can focus on the testing part. A fresh installation of Solidus will do the job. Solidus is a highly customizable ecommerce platform. By adding Solidus gem to our project we get a default store implementation right out of the box. Bellow is an outline of all required application setup steps:Create a new Rails project, use Postgresql for the database and skip the test files:$ rails new cypress-store -d postgresql -TAdd Solidus to the project by installing two new gems and running their included generators:# Gemfilegem &#039;solidus&#039;gem &#039;solidus_auth_devise&#039;bundle exec rails g spree:installbundle exec rails g solidus:auth:installbundle exec rake railties:install:migrationsRun the rails server and navigate to the index page, you should be greeted with the default store landing page:bundle exec rails sAt this step, we have a full-fledged online store. One might want to tweak some styles before sending it to production, but for our testing purposes, it’s just what we need. We are now ready to setup Cypress.Cypress setupSimilarly to how react-rails gem is used to integrate React components with Rails views, we will use cypress-on-rails gem to integrate Cypress with Rails tests. The new gem is a light wrapper around Cypress that augments its functionality allowing us to prepare application state using factories or custom Ruby code. Add the cypress-on-rails gem to the Gemfile and run the generator:# Gemfilegroup :test, :development do  gem &#039;cypress-on-rails&#039;, &#039;~&gt; 1.0&#039;endbin/rails g cypress_on_rails:installThis will both add the cypress npm package and setup the Ruby integration. To ensure that Cypress is ready to run tests against our application, run the application server in a test environment on port 5002 and in a separate window run Cypress:# start railsbundle exec rails server -e test -p 5002# in separate window start cypressyarn cypress open --project ./specYou might also need to precompile assets before running Cypress. The command cypress open will launch a test runner window with some sample tests scaffolded for us by Cypress. We will move on to substitute the sample tests with our own. Now, notice how simple it is to add Cypress to a Rails project, a single gem and no external dependencies like servers or drivers required.However, let’s throw in a few more gems to help us with arranging the application state. We want to empty the database before each spec and then create the data required by each test scenario.As usually, we delegate the database cleaning job to the database cleaner gem. Add the gem to the project and then key in the bellow scripts:# spec/cypress/cypress_helper.rbrequire &#039;database_cleaner&#039;# spec/cypress/app_commands/clean.rbDatabaseCleaner.strategy = :truncationDatabaseCleaner.clean# spec/cypress/support/index.jsimport &#039;./commands&#039;import &#039;./on-rails&#039;beforeEach(() =&gt; {  cy.app(&#039;clean&#039;);});The above scripts configure the gem and then run it (cy.app(&#x27;clean&#x27;)) before each integration test. Now lets prepare the test data with FactoryBot. Add the factory_bot_rails gem to the project together with the following code:# spec/cypress/cypress_helper.rbrequire &#039;database_cleaner&#039;require &amp;quotfactory_bot&amp;quotrequire &amp;quotspree/testing_support/factories&amp;quotrequire &amp;quotcarmen&amp;quotDir[Rails.root.join(&amp;quotspec&amp;quot, &amp;quotsupport&amp;quot, &amp;quotfactories&amp;quot, &amp;quot**&amp;quot, &amp;quot*.rb&amp;quot)].each { |f| require f }FactoryBot.find_definitionsWe now have access to both the FactoryBot library and all the factories provided by Solidus (e.g. users, orders and products).Add Cypress testsSome online stores require their customers to sign in prior to the checkout. Solidus comes with user session management functionality built-in and for us it’s a great test subject to begin with.Our first test will verify that only registered (persisted) users can sign in. Users that cannot be found in our database will be presented with the corresponding sign in failure message.Following the Arrange-Act-Assert (AAA) testing pattern, we first arrange the application state for our planned scenario. We will execute our tests against an application with one existing user. We will use a user factory imported from Solidus. Key in the following:# spec/cypress/app_commands/scenarios/sign_in.rbFactoryBot.create(:user, email: &#039;user@example.com&#039;, password: &#039;test123&#039;)With the state arranged, we move on to describe user actions and assert the desired outcome. Note that Cypress leverages other well-known libraries to write and organize tests. Specifically, Mocha provides TDD-like syntax to structure the tests (think decribe() - beforeEach() - it()). Likewise, Cypress wraps and extends Chai for writing assertions (think should). Moreover, with cypress-on-rails gem we are able to run our factory defined above by calling cy.scenario(‘sign_in’). Type in the following:// spec/cypress/integration/user/sign_in.spec.jsdescribe(&#039;Sign in&#039;, () =&gt; {  beforeEach(() =&gt; {      cy.scenario(&#039;sign_in&#039;);  });});Great, with above we declared that we want our sign_in state preparation script to run before any of the following tests. Now, let’s describe a scenario in which an existing user attempts to login:// spec/cypress/integration/user/sign_in.spec.jsdescribe(&#039;Sign in&#039;, () =&gt; {  beforeEach(() =&gt; {    cy.scenario(&#039;sign_in&#039;);    cy.visit(&#039;/&#039;);  });  it(&#039;signs in user with valid credentials&#039;, () =&gt; {    cy.get(&#039;#link-to-login&#039;).click();    cy.url().should(&#039;include&#039;, &#039;/login&#039;);    cy.get(&#039;[name=&amp;quotspree_user[email]&amp;quot]&#039;).type(&#039;user@example.com&#039;);    cy.get(&#039;[name=&amp;quotspree_user[password]&amp;quot]&#039;).type(&#039;test123&#039;);    cy.get(&#039;input.button&#039;)      .contains(&#039;Login&#039;)      .click();    cy.get(&#039;.flash.success&#039;)      .contains(&#039;Logged in&#039;)      .should(&#039;be.visible&#039;);  });});The test code is self-explanatory. The user visits the index page and clicks on the login button, which redirects him to the login page. On the login page, the user enters his valid credentials and clicks “Login” button. As the credentials are valid, we expect a login success message to be displayed. Now let’s verify that a user with invalid credentials cannot sign in:// spec/cypress/integration/user/sign_in.spec.jsdescribe(&#039;Sign in&#039;, () =&gt; {  beforeEach(() =&gt; {    cy.scenario(&#039;sign_in&#039;);    cy.visit(&#039;/&#039;);  });  it(&#039;signs in user with valid credentials&#039;, () =&gt; {    ...  });  it(&#039;does not sign in user with invalid credentials&#039;, () =&gt; {    cy.get(&#039;#link-to-login&#039;).click();    cy.url().should(&#039;include&#039;, &#039;/login&#039;);    cy.get(&#039;[name=&amp;quotspree_user[email]&amp;quot]&#039;).type(&#039;wrong_email@example.com&#039;);    cy.get(&#039;[name=&amp;quotspree_user[password]&amp;quot]&#039;).type(&#039;test123&#039;);    cy.get(&#039;input.button&#039;)      .contains(&#039;Login&#039;)      .click();    cy.get(&#039;.flash.error&#039;)      .contains(&#039;Invalid email or password.&#039;)      .should(&#039;be.visible&#039;);  });});It’s not ideal, the duplicate code is screaming at us. We will return to it, but for now, we focus on executing the tests. ruby on rails online training along with real time projects.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Wed, 29 Jul 2020 17:05:52 +0430</pubDate>
            </item>
                    <item>
                <title>Explain briefly DataStage containers</title>
                <link>https://virgool.io/@snehacynixit/explain-briefly-datastage-containers-td97fbnjrfyk</link>
                <description>A container is used to group stages and connections, as its name suggests. Containers help simplify and modularize job designs for servers and allow you to replace complex diagram areas with a single container level. For example, if you have a lookup that is used by multiple jobs, you can place in a sharing container the jobs and links that create the lookup, and use it for different jobs. In the programming language, you can look at it in a way like a process or method.Containers are linked by input and output stages to other stages or containers within the job. datastage online course for more techniques and skills from industrial experts.Types of DataStage containersThere are two types of Containers.Local containersThese are created in a local job in dataStage, and can only be accessed through that job. A local container is edited in the Diagram window of a task tabbed page. You can use the local containers in Server jobs, or work in parallel.Shared containersThese are created separately and stored in the Repository just like jobs in DataStage. There are two shared container types.Shared container serviceYou may find this in application jobs and also in parallel activities as well.Shared parallel container employed in parallel occupations.In parallel jobs, you can also use shared application containers as a way of integrating cloud job features into a parallel stage.Let us see about the features of local and shared containers.Features of Local and shared containersLocal containersUsed primarily to ease the creation of the work.You can combine pieces of logic and use them within a work.Can only be used in a job once it has been developed.Number of Local Containers assisted input and output connections.On-the-job availability.Shared containersUsed for ease of job design as well as for sharing among workers.Flexibility over the entire project.The mapping of shared containers includes metadata.Shared containers can be saved as standalone.Job need to be repackaged once the shared container definition has changed.Shared containers cannot be self-compiled.If the code for shared containers is used within the job, it will be included in the code for the task.Setting up local and shared containers in DataStageThe setup of local and shared containers are as follows.Local containerThe main purpose of using a local DataStage container is to visually simplify a complex design and make it easier to comprehend in the Diagram window. If there are lots of stages and connections in the DataStage job, it may be easier to create additional containers to represent a similar sequence of steps.Do the following to construct a local container, from an established work design:Press the Shift key and click on the steps you want to insert in the local container using the mouse.Select Edit [Construct Container] Local from the menu bar. A new tab appears in the Diagram window which contains the contents of the new stage of the Local Container. You are warned if any disputes over the naming of ties arise when the container is installed. The new container is opened and shifts focus to its tab.As with any other stage in your job design, you can rename, move, and delete a container stage.To display or change a local container in the Diagram window, simply double-click on the container stage. In a folder, you can edit the stages and links just the way you do for a work.Drag and drop the Container icon in the General group on the tool palette to the Diagram window to build an empty container into which you can add stages and ties.In the Diagram window, a container stage is added, double-click on the stage to open it, and add stages and links to the container the same way you do for a job.Use of Local container Input and Output StagesPhases of input and output are used to describe the stages of the main job the container is connected to. datastage administrator training helps you to learn more effectively.If you are building a local container from an existing group of stages and links, the input and output stages will be added automatically. The connection between the input or output stage and the container stage has the same name as the link in the Diagram window for the main job.In the example above the input link is the link from the Oracle OCI stage (oracle oci 0) of the main job connecting to the container. The output link is the connection that connects from the first container to the second.If you create a new container, the input and output stages will be placed in a container with no link. You need to add stages between the input and output stages to the container Diagram window. Link the stages together, and edit the names of the links to match those in the main window.You can have any number of links in and out of a local container, in the job all the link names inside the container must match the link names within and outside it. Editing metadata on either side of the container edits the meta data on the connected stage in the job once a connection is established.Shared ContainerShared containers also help you simplify the design but are reusable by other jobs unlike local containers. Shared containers can be used to make work components accessible in the project.Shared containers comprise groups of stages and connections, and are stored like DataStage jobs in the Repository. DataStage positions an instance of that container in the design when you insert a shared container into a job. When compiling the job which contains an instance of a shared container, the container code is included in the compiled job. The DataStage debugger can be used on instances of shared containers that are used within jobs.You can create a shared container from scratch, or bring into a shared container a set of existing stages and links.Create a shared container out of the current job design.Press Shift and then press on the other stages and links to connect to the jar.Select Edit [Construct Container] Shared from the menu bar. You will be asked via the Build New dialog box for a name for the container. The community is replaced with a Shared Container stage of the same sort in the Diagram window with the specified name.Any parameters which occur in the components are copied as container parameters into the shared container. The generated instance has assigned all of its parameters to corresponding job parameters.Modify or display a Shared ContainerSelect File -&gt;Open from the menu bar, then select Shared Folder to open. You can also highlight the Shared Container, right-click on the mouse and pick the address.Using a shared containerDrag a Shared Container icon in the Repository window from the Shared Container branch to the Diagram window of the job.Update Tabs for Input and Output.Container Map ConnectionChoose the connection within the shared container to which you will map the incoming job link. You need to change the  link to cause a validation process. Then you will be alerted if the metadata does not match and the meta data reconciliation option is provided as mentioned below.The Container ColumnsColumns page displays the metadata identified in a standard grid for the connection to the job point. In the Load Shared Containers button, you can use the Reconcile option to overwrite metadata on the job stage link with the container link meta data in the same way as defined for the Validate option.Conclusion:I hope you reach a conclusion about containers in DataStage. You can learn more about DataStage containers from DataStage online training.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Tue, 28 Jul 2020 15:31:42 +0430</pubDate>
            </item>
                    <item>
                <title>Visualize IoT Data With Kaa and MongoDB Compass</title>
                <link>https://virgool.io/@snehacynixit/visualize-iot-data-with-kaa-and-mongodb-compass-keb7ahbm6txx</link>
                <description>Kaa is a highly flexible, open source middleware platform for Internet of Things product development. It provides a scalable, end-to-end IoT framework for large, cloud-connected IoT networks. Kaa enables data management and real-time bidirectional data exchange between the connected objects and backend infrastructure by providing server and endpoint SDK components. Learn MongoDB online training from industrial experts.The SDK components support multi-programming development, client server communication handling authentications, and so on. The SDK components can be virtually integrated with unlimited and any type of connected devices or microchips.In this blog, let us discuss the quick installation of Kaa Sandbox using a VirtualBox environment and connecting a sample application with MongoDB log appenders.Installing Kaa SandboxTo install Kaa Sandbox, perform the following:Download Sandbox image v0.10.0 from the download link.Download the .ova file and provide a proper location in the local system.Download the VirtualBox platform packages. In our use case, Windows hosts are used.Locate the two downloaded files in the proper location for a better understanding.Open VirtualBox and go to File --&gt; Import Virtual Appliance.Import the downloaded kaa-sandbox-0.10.0.1.ova file.Click the Next button, then select the proper configuration details such as Name, OS Type, CPU, RAM, and so on. Note: A minimum of 4096 MB should be available to run in the environment.Upon verifying the configuration details, click Import to start the process.Demonstrating a Sample ApplicationIn this section, let&#x27;s discuss a sample Kaa application in Kaa Sandbox.This application sends temperature data at preset time periods from the endpoint to the server. A log appender is set up to collect data from the endpoint. In our use case, a MongoDB log appender is used.The sample application is executed by:Generating a Java SDKCreating the log appendersLaunching the applicationFetching MongoDB logs from the appendersChoosing the ApplicationThe sample application here is named Data Collection Java DemoGenerating the SDKTo generate the SDK, perform the following:The corresponding SDK component will be built or generated. You can also download Objective C, C++, and Android files for the Java SDK.If you want to Gain In-depth Knowledge on MongoDB, please go through this link MongoDB online course</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Mon, 27 Jul 2020 18:13:45 +0430</pubDate>
            </item>
                    <item>
                <title>Running Kubernetes Cluster using Kind and Docker</title>
                <link>https://virgool.io/@snehacynixit/running-kubernetes-cluster-using-kind-and-docker-pceqygu8pizm</link>
                <description>Before we start running the process using different tools and components, we must know about the Kubernetes and other tools that help in this process. Kubernetes is an open-source container-based system that automates the process of deploying, scaling and managing applications.  Being open-source, Kubernetes is compatible with any of the platforms like on-premise, cloud, hybrid infrastructure. It moves the workloads according to the requirement. Kubernetes cluster refers to the systems that are connected to each other to work in a single frame.Docker is a platform that makes it easy to create, run and deploy applications using small containers. Containers are small packages of software that can be moved easily to any place. Each container is different from one another. for more techniques kubernetes cetification training A Kind is a tool that helps in running local Kubernetes clusters using Docker containers as nodes.Kubernetes in Docker kindKubernetes is developed as a highly available cluster of systems that connects to work as a single infrastructure. The main role of Kubernetes is to automate the scheduling of containers among the clusters in an efficient manner.Here we will understand how to run the cluster in different steps with a single Docker container in Kind.In this process, we will start by installing Kind.The Kind installation is done through the following commands. :-go get -u sigs.k8s.io/kindkind create clusterNext, we will confirm the cluster.kind get clustersSetting KubectlHere first, we need to install the Kubernetes. Then we will create Kubectl. The following command will check the version of kubectl.kubectl versionOnce kubectl and kind are ready, we will run the following command.export KUBECONFIG=”$(kind get kubeconfig-path)”kubectl cluster-infoDeploying applicationIn this part, we will see the deploying process of application. Here first, we download the mysql-deployment.yaml &amp; wordpress-deployment.yaml Now, we will create kustomization.yaml. for more kubernetes courseThen we will check it through the following command.k8s-wp/kustomization.yamlmysql-deployment.yamlwordpress-deployment.yamlThen we will apply to the cluster.cd k8s-wpkubectl apply -k ./Here we can see the output like this;secret/mysql-pass-7tt4f27774 createdservice/wordpress-mysql createdservice/wordpress createddeployment.apps/wordpress-mysql createddeployment.apps/wordpress createdpersistentvolumeclaim/mysql-pv-claim createdpersistentvolumeclaim/wp-pv-claim createdTo check the cluster status, we can use the following commands.kubectl get secretskubectl get pvckubectl get podskubectl get services wordpressWe should wait until the pods show running status.Later we have to run the following command to access the service.kubectl port-forward svc/wordpress 8080:80Now we can open http://localhost:8080/Thus, kind is the best alternative to minikube as it uses only a single Docker container.Kind Kubernetes versionWe can see that the version string may look like v2 or v2 beta 1. The versions are sorted out by the following algorithmFirst we sort out the Entries those following the Kubernetes version pattern.For the entries that are following the Kubernetes version pattern, the numeric portion in that version string is sorted out.In case strings like alpha or beta follow the numeric portion, then they are sorted in the way that the equivalent string should come without beta or alpha suffix.If other numbers also follow beta or alpha then they can be sorted differently.Strings that do not fit in the above format, they are sorted alphabetically and not numerically.Kubernetes Kind typeKind represents the K8s type of objects that are created. These can be a Pod, Service, DaemonSet, etc. K8s API version helps to create the resources. These resources can be v1, v1beta, etc.Thus, we have seen how to run the Kubernetes cluster using Kind and Docker in the above article. We can see the steps and commands that follow the process of installing and running the cluster. It shows how the cluster will run smoothly by using different steps.  Kubernetes is useful to run different kinds of applications. As it is an open-source system that is based on containers. As we know that the containers are small software packages.It gives an overview of the Kubernetes, Docker, and kind in a simple way to understand the way they work together. The Kubernetes cluster gives the platform to automate the scaling, operating and deploying of application containers across the clusters. One can start their career by gaining knowledge of Kubernetes and different components through Kubernetes Online Training.This knowledge will help to grow the career as the application implementations are increasing day by day. Having knowledge of the above tools and technology, one can prosper in this way.</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Mon, 13 Apr 2020 12:22:49 +0430</pubDate>
            </item>
                    <item>
                <title>Can Artificial  Intelligence fight loneliness during lock down</title>
                <link>https://virgool.io/@snehacynixit/can-artificial-intelligence-fight-loneliness-during-lock-down-z2ecufctx6tv</link>
                <description>Artificial intelligence has several applications and Health care is one of them. Artificial intelligence can be helpful for  people to fight loneliness. In the current scenario everyone needs this as the world is in lockdown. This has its own repercussions and in this article I would like to brief you about the use of artificial intelligence to fight loneliness.Loneliness is a global issue that scientists agree can be bad for your health.  It is as bad as smoking 15 cigarettes a day or being extremely overweight. Young people are at risk as are elderly people. The epidemic corona virus resulted in lockdowns across cities around the world. I recommend isolation and social distancing. Artificial intelligence helps in fighting loneliness by providing Ai companionship. for more info go through ai certification course There lived a man who was introduced to artificial intelligence. I want to write this paragraph in his perspective so that you would come to an idea about Artificial intelligence. He was so astounded, it was just so fun,he says. He remains an active user of his Google Home app many months later. He asks the google for news and weather forecasts, music and audio book recommendations, and hints on crossword puzzles. Sometimes he asks google to tell a joke to him. This keeps him safe, actually, because when you lose your wife after 64 years it is a lonely life. You spend a lot of time alone in it.Since human beings are social beings, most people have a traumatic feeling not being able to participate in social experiences. He has consulted on the Bournemouth smart speaker project and states all the participants at the care home have always done it well. She says that voice-activated apps also help to provide a &quot;sense of control&quot; that &quot;in this time of confusion, too, could help&quot;. artificial intelligence online training india provides you more techniques Replacement of human touch:We know feeling lonely can lead to poor mental health. If this is caused by a lack of social contact with others, an AI service could be beneficial. Particularly for those of us who can not establish new social connections or who need to remain in social isolation. It is crucial that it does not become a long-term substitute for human contact.This is the advice for those who frequently feel depressed including finding help from friendly services provided by charities, and opening up their feelings to current friends or relatives.Corona virus-related lockdowns in cities across the world and self-isolation measures for those over 70 may worsen the issue of loneliness .The charity also advises that those affected by loneliness should also seek talking therapy to help them understand how their emotions and values impact their feelings and behaviors and learn to cope with their situation. Several clinicians, politicians and doctors may be able to offer these services remotely during the corona crisis.Technical problems:Artificial Intelligence technologies champions like smart speakers understand that while some elderly people are early adopters. It increases their use more broadly as a challenge. Some men don&#x27;t like modern technology.People who are less frequent users of current technology may need some extra encouragement to take the first step to try the voice-activated technology. However, work into artificial intelligence and other technology has shown that lack of consciousness is the main barrier.Customers just don&#x27;t even know that there are those things, they don&#x27;t know where to get them. They don&#x27;t know how to get them. That is not just about age to be alone. It is a lack of commitment to make it accessible to them.Artificial Intelligence in use:Several other high-tech projects are also testing Artificial intelligence limits as a potential tool to foster a sense of companionship for older residents on the planet. There are several elderly robot companions which help elders fight loneliness.Mabu, a doll-sized robot, hasl built personalized conversations according to the unique circumstances of the patients. In the US, Mabu is a doll-sized robot used as a virtual care assistant. It can check in on the well-being of the pensioners. It checks whether they have taken their medicine. It even suggests whether the weather is good enough for them to take a walk outside. A robot named Dinsow plays a similar role in Japan, and other parts of Asia. It has a screen for a face that allows users to watch videos and read directions while family members can also dial in for video calls automatically.Participants are encouraged to discuss topics like their greatest loves and travel experiences, with specific follow-up questions answered by the speakers.It was amazing to see that they were happy to share their stories whether it was a voice assistant, a recorder or anything. Artificial intelligence technology has reached new heights.Data privacyThe stories that old people are telling are their life stories, intensely personal. There has to be clarification on responsibility of data, as for any personal data. The protection of privacy is most important in Artificial Intelligence.Many who work on the Artificial Intelligence project claim that using local service and secure servers, they emphasize user health. Data is not stored in the cloud. There is no sharing of third-party data from their side.The Google Home smart speakers used in both Memory Lane and the project have hit the headlines. Recently there is a debate about how the tech giant uses the data collected. Yet the company has maintained that it is not selling details to third parties.However, when this question was asked, people replied, “As long as they don&#x27;t interfere with my bank balance and things like that, I&#x27;m happy!”Social reconnectionsAs research into the benefits of using voice assistants and Artificial intelligence technologies  help lonely pensioners continues, there are hopes that the corona virus crisis itself. This has highlighted the vulnerability of many elderly people. This may bring something of  silver lining when it comes to future societal efforts to tackle social isolation.Meanwhile, the coronavirus pandemic has also stressed the need to inform older people to make the most of interactive networking devices such as voice-activated assistants and video calls.It would be very beneficial to some of these online ventures if older people could still access them, so they could ask what they want it to be.Social support:Interventions in social care are not always feasible or desirable. Artificial agents in some circumstances provide support similar to human social support for health benefit. Health care artificial agents may serve as transitional objects to help patients cope with feelings of depression and suicidal distress that often accompany serious illness and end-of-life experiences. Artificial Intelligence reduces feelings of loneliness, as well as  increases inter-relationship. This is either by direct experiences with the agent or through human conversations that would not have occurred otherwise.Challenges:The robots and Artificial intelligence will help overcome loneliness. It raises multiple ethical and social problems to tackle. We must consider the expense. The robots are costly. This makes funding difficult to get through. There are also certain challenges in trust and ethical grounds.Trust:I think that is a solvable problem, but that is not a simple one. It is difficult even for a human to know the right way to deal with a depressed person. The teaching, or programming, of Artificial intelligence is important.Ethics:We should make it clear to people that accompanying robots are pre-programmed and do not really have emotions. The researchers state that the boundaries between man and robot will begin to blur with time.Conclusion:By reading this article you reach a conclusion about need and the application of artificial intelligence. You can learn more about Artificial intelligence through Artificial Intelligence online training.&#x60;</description>
                <category>snehacynixit</category>
                <author>snehacynixit</author>
                <pubDate>Tue, 31 Mar 2020 14:20:18 +0430</pubDate>
            </item>
            </channel>
</rss>