<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: sanghivivek</title>
    <description>The latest articles on DEV Community by sanghivivek (@sanghivivek).</description>
    <link>https://dev.to/sanghivivek</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F438782%2Ff263a31b-6d74-438f-8b29-28e28038dd9a.png</url>
      <title>DEV Community: sanghivivek</title>
      <link>https://dev.to/sanghivivek</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/sanghivivek"/>
    <language>en</language>
    <item>
      <title>
A complete Guide to Uipath ReFramework
</title>
      <dc:creator>sanghivivek</dc:creator>
      <pubDate>Thu, 23 Jul 2020 14:21:22 +0000</pubDate>
      <link>https://dev.to/sanghivivek/a-complete-guide-to-uipath-reframework-kfe</link>
      <guid>https://dev.to/sanghivivek/a-complete-guide-to-uipath-reframework-kfe</guid>
      <description>&lt;p&gt;An introduction to Uipath&lt;/p&gt;

&lt;p&gt;UiPath is a global Robotic Process Automation vendor that provides a complete software platform to help organizations efficiently automate business processes. And with the acquisition of both ProcessGold and Stepshot in 2019, it has become the first vendor to bring process mining &amp;amp; robotic process automation together.&lt;/p&gt;

&lt;p&gt;2,750+ enterprise customers and government agencies use UiPath’s Enterprise RPA platform to successfully deploy software robots that perfectly follow and execute repetitive processes. &lt;/p&gt;

&lt;p&gt;Businesses are accelerating their productivity and enhancing customer experience across  front-office and back-office operations through it’s complete software platform.&lt;br&gt;
UiPath Studio and Orchestrator  &lt;/p&gt;

&lt;p&gt;UiPath is a platform that comprises a Studio and an Orchestrator. A studio is a tool where developers can design and develop RPA processes to the Orchestrator or publish a reusable library. &lt;/p&gt;

&lt;p&gt;While an Orchestrator is a web application that enables developers to arrange UiPath Robots in executing repetitive business processes. You can understand it as a centralized robot management dashboard that helps in managing machines and robots along with a ton of additional features. Like Queues for enabling multiple robots to work on the same problem, scheduling jobs and assets to store config data and for securely storing credentials.&lt;br&gt;
What is Uipath ReFramework/Robotic Enterprise Framework?&lt;br&gt;
What is Uipath ReFramework.jpg&lt;/p&gt;

&lt;p&gt;Uipath reframework or also referred as robotic enterprise framework is a framework that is built to help developers in building quick and efficient RPA processes. &lt;/p&gt;

&lt;p&gt;It is the UiPath’s Template that has a well written structure that is used for building a robust large scale solution that works based on Queue Transactions.&lt;/p&gt;

&lt;p&gt;This Uipath framework is generally built on state machines. That you can use as a starting point for all of your UI projects.&lt;/p&gt;

&lt;p&gt;ReFramework makes a developer’s tasks much easier. It works as a template and provides all the basic details that you as a developer may need for any process automation.&lt;/p&gt;

&lt;p&gt;The template lets you read and store the config data, open the required application and close all the unnecessary applications, get the transaction and process it, and when required it allows to retry the transaction.&lt;/p&gt;

&lt;p&gt;Along with that it logs the status of all processed, failed &amp;amp; successful transactions. &lt;/p&gt;

&lt;p&gt;Hence to build a robust and fast process use ReFramework in Uipath. That also facilitates you these super cool features.&lt;/p&gt;

&lt;p&gt;Uipath ReFramework Features:&lt;/p&gt;

&lt;p&gt;Reusability&lt;br&gt;
It works for any type of processes and business. As the logic code is separated from other aspects of ReFramework it can be reused efficiently.     &lt;/p&gt;

&lt;p&gt;Scalability&lt;br&gt;
ReFramework has the ability to retry a failed transaction multiple times and send exception notifications.  Effective logging&lt;br&gt;
Effective logging&lt;br&gt;
It provides an effective logging mechanism to monitor the process and error handling.&lt;/p&gt;

&lt;p&gt;Error Screenshot&lt;br&gt;
ReFramework has the functionality to take a screenshot of the screen at the point where it gets failed, that let you know the unattended automations and overall troubleshooting.   &lt;/p&gt;

&lt;p&gt;Exception Handling&lt;br&gt;
ReFramework makes exception handling a piece of cake. It has functionality to take actions when an exception comes. That let you not worry about process halt or anything else.     &lt;/p&gt;

&lt;p&gt;Consistency&lt;br&gt;
The variables, assets and settings are consistent across ReFramework that makes it easy to understand. Also the code standards allow an easy handover to a different developer.&lt;br&gt;
How ReFramework works in Uipath&lt;/p&gt;

&lt;p&gt;If you have ever worked at Uipath studio then you might know it has 3 types of data flow representations: sequence, flowchart and state machine.&lt;/p&gt;

&lt;p&gt;Though ReFramework contains all the 3 data flows, the main structure of the program is built using a state machine as it provides a more clean and functional data flow representation.&lt;/p&gt;

&lt;p&gt;So, before knowing how the Reframework works in the Uipath, let’s have a look on it’s architecture.&lt;/p&gt;

&lt;p&gt;We have four stages in the ReFramework architecture&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Init
Get Transaction
Process Transaction 
End Transaction
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;As you can see, It has a main.xml file which uses the state machine workflow and each stage is connected with each other for the work processes. &lt;/p&gt;

&lt;p&gt;Since the system can only be in one state at a time, at least one transition condition from a given state must be true for it to move to another state. If it gets failed in any of these states, ReFramework is built in a way to either retry it or end the process and send an exception log with the respective reason.&lt;/p&gt;

&lt;p&gt;Overall, ReFramework architecture comprises 3 state activities, 1 final state activities and 7 transitions where each state is connected with each other with transitions.&lt;/p&gt;

&lt;p&gt;Now, let’s understand each stages of the framework in a better way:&lt;/p&gt;

&lt;p&gt;Init – This is the initial state which is used to read and store the config data in the dictionary, close all the unnecessary applications and open the required one. For example, if in the Process we need to upload an attachment in SAP, we first require the Bot to fetch the credentials from Orchestrator, open the SAP application and then login to SAP using the credentials. &lt;/p&gt;

&lt;p&gt;The best part of UiPath ReFramework is that it is built in such a way that you can initialize all the applications necessary here in the Init state and if the conditions you have built are met, the Bot will then move forward with processing the transaction.&lt;/p&gt;

&lt;p&gt;If there is an error while initializing the applications or the credentials provided are invalid, an exception notification will be sent from within Init State and end the process.&lt;/p&gt;

&lt;p&gt;Get Transaction- It is the data retrieval state, which is used to get the transaction from queue, data table, folder, database and other sources. Yes, once the Bot successfully initialized all the applications it requires for a process. Hence, it looks for any transaction items in the Orchestrator Queue to process. &lt;/p&gt;

&lt;p&gt;ReFramework prebuilt functionality looks for a Stop Request and will stop the process even though there are items still in the Queue to process. This becomes helpful in situations where you notice the Bot is not doing what it is expected to do and want to stop the process before it works on any other transaction items.&lt;/p&gt;

&lt;p&gt;Process Transaction- In this state, the transactions are processed that are fetched from the previous state. And if there is no record to process, the robot automatically moves to the end process state. If we look again at our attaching a document in SAP example, The Bot, which has now got the Transaction Data from the Queue should now upload the attachment to SAP. &lt;/p&gt;

&lt;p&gt;And in Process State, all the activities required to attach the document will be  invoked. For example, a workflow to check if the document exists or not on the Shared Path, a workflow with activities like clicking on appropriate GUI Elements for the Bot to navigate through SAP, type in the file path and look for the confirmation that the document was successfully attached.&lt;/p&gt;

&lt;p&gt;ReFramework has prebuilt SetTransactionStatus workflow that can be used to set the Transaction Status of an item to either Success, Business Exception or Application Exception. And among them, Business Exceptions are prebuilt exceptions that are built into the script and looked by a Bot. &lt;/p&gt;

&lt;p&gt;After the successful transaction, bot will now move forward with the next item in the Queue.&lt;/p&gt;

&lt;p&gt;End Transaction- This is the final state of ReFramework that ends the robot successfully and closes all the applications. After the Bot has finished processing all the transaction items from the Queue, it will log out of applications,  irrespective of if it is a failed or successful transaction.&lt;/p&gt;

&lt;p&gt;Once you open the Uipath studio you see the screen like this:&lt;br&gt;
ReFramework start screen&lt;/p&gt;

&lt;p&gt;On the first left column, you need to click the start option, below the open and close menu. And there you need to select the ‘Robotic Enterprise Framework’ from the ‘New From Template’ options for the base practice on a large scale deployment.&lt;/p&gt;

&lt;p&gt;Once you click on it, the ‘New robotic Enterprise framework’ wizard will open up. Fill up the name, location, and description as per the project and click on the create button. Now you will encounter this screen:&lt;br&gt;
The home screen of ReFramework&lt;/p&gt;

&lt;p&gt;Here comes the actual role of the uipath reFramework. Because once you create the new framework, It stores all the dependencies and work flows in the one folder, you can go and check one by one.&lt;/p&gt;

&lt;p&gt;To initialize the process you will see a screen similar to this:&lt;/p&gt;

&lt;p&gt;Initialize the process&lt;/p&gt;

&lt;p&gt;Uipath ReFramework Examples&lt;/p&gt;

&lt;p&gt;Uipath ReFramework becomes the best choice for several cases. For example:&lt;/p&gt;

&lt;p&gt;You want to scrap 100 pages on a site that requires a login, then reframework will ease the process in unmatchable speed. All you need to do is&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Include the credentials required for the site in your Config file
Store the url of your site in the config file (as it is easier to change once in Excel than a lot of times in the workflows)
Now you can control the number of pages that need to be scraped
Also can retry the scraping on pages that failed.
That’s it!!
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Let’s see some of the most commonly use cases where Uipath Reframework is making things easier for the enterprises&lt;/p&gt;

&lt;p&gt;Web Scrapping – Whenever you need to scrap data from various locations and want to feed them in a particular excel sheet. Like in the case of comparison sites, stock markets, e-commerce and other for a specific purpose in a large scale, then the framework can become very useful in making the process fast and errorless.&lt;/p&gt;

&lt;p&gt;Inventory/supply chain management– As retailers rely on legacy systems for stock keeping. The Framework bots can perform constant checks on the systems providing data on key metrics like items with low stock levels or the one changing rapidly.&lt;/p&gt;

&lt;p&gt;Customer/User onboarding– In many B2C businesses customer onboarding is critical. And using this automation framework, customer onboarding actions can be completed instantaneously even in companies that rely on legacy systems, that hugely improve the customer experience.&lt;/p&gt;

&lt;p&gt;Generating mass emails– Mass emails relying on data from multiple systems are laborious to produce manually. Hence for enterprises who need to send them frequently, this automation framework is easing the process.&lt;/p&gt;

&lt;p&gt;Validating and processing online loan applications – You can use this framework to built intermediary bots between the online system and the main frame that used business logic to ask the user to fix incorrect entries as well as make the loan decisions and generate confirmation letters.&lt;/p&gt;

&lt;p&gt;These are just to name a few, their implementations can be seen on large scale at manufacturing, healthcare industries, banking, E-commerce and many other industries.&lt;/p&gt;

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

&lt;p&gt;You can use REFramework with very ease, if you have a good understanding of the “Invoke Workflow Activity” and some grip on managing data between the State Machine. Must say, REFramework is so user friendly that it has everything in-built and it provides robust Robots.&lt;/p&gt;

&lt;p&gt;As UiPath is continually adding new features and updates to UiPath Studio and ReFramework, keep an eye out on the latest updates to excel!&lt;br&gt;
Frequently Asked Questions&lt;/p&gt;

&lt;p&gt;Q.How can I learn UiPath ReFramework?&lt;/p&gt;

&lt;p&gt;A. Learning UiPath ReFramework is easy. All you need to do is just start with the basics.&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Learn about ReFramework workflow activity, template and go through all the parts.
You may also opt for the Uipath Advanced certification course, that will make most of your confusion clear and gives you some confidence by doing some dummy projects.
Have some concepts of orchestrator 
Note your doubts and clear them one by one.
Keep patience and practice, you will soon find yourself doing live projects
All the best!!
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Q. What is the role of an Orchestrator in Uipath?&lt;/p&gt;

&lt;p&gt;A. UiPath Orchestrator is a centralized robot management dashboard where you can easily deploy, secure, and manage your UiPath Robots at scale. It runs on a server and connects to all the Robots within the network, whether Attended, Unattended, or Free. It ensures the correct delivery of the packages to Robots.  &lt;/p&gt;

&lt;p&gt;Q. What is ReFramework in Uipath?&lt;/p&gt;

&lt;p&gt;A. ReFamework or Robotic Enterprise Framework is a template within UiPath Studio built using State Machine layout.&lt;/p&gt;

&lt;p&gt;Q. What are the types of projects in UiPath?&lt;/p&gt;

&lt;p&gt;A. There are two types of standalone automation projects in Uipath Studio: process or library. Processes can incorporate all types of workflows, flowchart, sequence, state machine and global exception handler.&lt;/p&gt;

&lt;p&gt;Q.Can UiPath be used for testing?&lt;/p&gt;

&lt;p&gt;A. Yes, Uipath can be used for running unit tests and will help ease the development and save time.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://hashstudioz.com/blog/a-complete-guide-to-uipath-reframework/"&gt;https://hashstudioz.com/blog/a-complete-guide-to-uipath-reframework/&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Is OPC UA the future of IIOT?</title>
      <dc:creator>sanghivivek</dc:creator>
      <pubDate>Thu, 23 Jul 2020 13:15:51 +0000</pubDate>
      <link>https://dev.to/sanghivivek/is-opc-ua-the-future-of-iiot-36k4</link>
      <guid>https://dev.to/sanghivivek/is-opc-ua-the-future-of-iiot-36k4</guid>
      <description>&lt;p&gt;Since we are discussing OPC-UA as the future of IIOT, We need to first understand the definition of IIOT.  As per Wikipedia, IIOT is The interconnected sensors, instruments, and other devices networked together with computers’ industrial applications, including manufacturing and energy management.&lt;/p&gt;

&lt;p&gt;In a nutshell, the Industrial Internet of Things is getting all the data in digital format within the manufacturing facility /unit/ Enterprise. Any consumer of data can get access to the data when they need it. &lt;br&gt;
The IIoT is enabled by technologies like cloud computing, cybersecurity, edge computing, mobile technologies, machine-to-machine, 3D printing, advanced robotics, internet of things, RFID technology, and cognitive computing.&lt;br&gt;
What is OPC UA?&lt;/p&gt;

&lt;p&gt;Now we need to understand what OPC-UA is so that we can better understand how it is related to IIOT. Let’s see the definition of OPC-UA by Wikipedia, &lt;/p&gt;

&lt;p&gt;OPC Unified Architecture (OPC UA) is a machine to machine communication protocol for industrial automation developed by the OPC(Open platform communications) Foundation.&lt;/p&gt;

&lt;p&gt;It is an industrial standard for packaging the data from the edge, Edge is machined in industrial units, PLCs, Pneumatic controls. OPC-UA is standard for how you communicate between servers and the devices placed in industrial units, how data should be packaged in its payload. &lt;/p&gt;

&lt;p&gt;OPC-UA is the grandchild of OPC-DA( Data Acquisition). OPC is all about data exchange. While OPC-DA is based on D-COM and can work only with Windows products. It is not compatible with Linux or MAC. OPC-UA is the advancement of OPC -DA, OPC-UA is technology agnostic. One can run on Linux, Windows or MAC. &lt;/p&gt;

&lt;p&gt;Both standards are written by the OPC Foundation. The OPC Foundation is an industry association that creates and maintains standards for the open connectivity of industrial automation devices and systems.&lt;/p&gt;

&lt;p&gt;Let’s focus on the question under discussion “is the OPC-UA Future of IIOT”? , In my opinion, any IIOT protocol should have the following three qualities:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;OPEN – It should be open protocol, should be open to communication with other products. There are multiple open source for connectivity available, it should have the option to integrate.

Reports by Exception – It should be edge-driven and should send updates to the server which is saving the data that clients will consume. There is no point to publish the data that has not been changed. 

Lightweight and stable – It should be lightweight and stable, It can not consume tons of bandwidth on the network.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;OPC-UA satisfies all the features which IIOT protocols should have. OPC UA could deliver an architecture appropriate for the Internet age, delivering modern transports, security technologies, data, and transaction specifications. The last two items are the key to a complete solution and were the defining criteria for its selection as an IIoT (Industrial Internet of Things) ready Dream Report interface.&lt;/p&gt;

&lt;p&gt;There are multiple alternate IoT Protocols such as MQTT, AMQP, CoAP among others, but many only define transports and not data structures. As a communication protocol for industrial automation, the OPC Unified Architecture (OPC-UA) has quickly become the protocol of choice as the number of Industrial Internet of Things (IIoT) deployments continue to grow.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Production Dashboard : Hashstudioz Technologies delivered this project for Canadian customers. The customer is using WinCC -RT which is a Siemens automation/monitoring platform. WinCC-Rt is used to manage communications with PLC. It has a built-in OPC-UA server. Customers will enable OPC-UA on WinCC-RT and share the connection endpoint. The Hashstudioz team developed and deployed an OPC-UA client which connects to the PC-UA server and fetches the required tags. Customers are now able to supply the list of tags that need to be read from WinCC-RT. The component which will be developed and design by Hashstudioz development team is following:
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;OPC UA Role with Win CC-RT&lt;/p&gt;

&lt;p&gt;We used an open-source OPC-UA python client and saved the data in the database. We used the Django framework to create the JSON API which is consumed by the frontend to create a dashboard. &lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;Kepware OPC-UA  integration :  This project was similar to the previous project wherein the WinCC customer was using kepware. We created an OPC-UA client in node.js In contrast to permanently reading information (polling), OPC UA provides a more elegant functionality, a so-called Subscription. A UA client can subscribe to a selection of Nodes of interest and let the server monitor these items. Only in case of changes, e.g. to their values, the server alerts the client about such changes. This mechanism reduces the amount of transferred data immensely. In addition to the reduction of bandwidth, this mechanism introduces further advantages and is the recommended mechanism to “read” information from a UA Server. This feature is mentioned in the basic requirement for IIOT protocols. The client and server should work on a change of data and should not send all the data. &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Adapter between API and OPC-UA :&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;This is an interesting project HashStudioz developed for a German customer. The customer has an indoor asset tracking platform that can receive the data through API. The Client ‘s end client was not technical enough to consume API and send the data but was good in publishing the data as OPC-UA Client.  We achieved this by setting up an open-source node.js based OPC-UA server.&lt;/p&gt;

&lt;p&gt;OPC-UA server creates a function named APICALL, this function will have two parameters 1) API name  2) Argument list, OPC-UA client can call this function, and pass the API and parameters, System will call the API and will return the response to Client.&lt;/p&gt;

&lt;p&gt;Source : &lt;a href="https://hashstudioz.com/blog/is-opc-ua-the-future-of-iiot/"&gt;https://hashstudioz.com/blog/is-opc-ua-the-future-of-iiot/&lt;/a&gt;&lt;/p&gt;

</description>
      <category>iot</category>
    </item>
  </channel>
</rss>
