<?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: Fernando</title>
    <description>The latest articles on DEV Community by Fernando (@flachica).</description>
    <link>https://dev.to/flachica</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%2F80393%2Fc4413be8-e78e-4b00-864c-08ab4b03a39f.jpeg</url>
      <title>DEV Community: Fernando</title>
      <link>https://dev.to/flachica</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/flachica"/>
    <language>en</language>
    <item>
      <title>Clean Architecture: A Toy Node Prototype</title>
      <dc:creator>Fernando</dc:creator>
      <pubDate>Thu, 28 Jul 2022 12:02:21 +0000</pubDate>
      <link>https://dev.to/flachica/clean-architecture-a-toy-node-prototype-2kp3</link>
      <guid>https://dev.to/flachica/clean-architecture-a-toy-node-prototype-2kp3</guid>
      <description>&lt;p&gt;I have published &lt;a href="https://github.com/flachica/clean-arch-node"&gt;an approach&lt;/a&gt; to the "Clean Architecture" proposed by Robert C. Martin&lt;/p&gt;

&lt;p&gt;Note that there are issues to be improved. Any contribution will be welcome.&lt;/p&gt;

&lt;p&gt;This server publishes two endpoints:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;/animals&lt;/code&gt; on port &lt;code&gt;3000&lt;/code&gt; --&amp;gt; With three animal examples loaded from memory&lt;br&gt;
&lt;code&gt;/fruits&lt;/code&gt; on port &lt;code&gt;3001&lt;/code&gt; --&amp;gt; With three fruit examples loaded from memory&lt;/p&gt;

&lt;h2&gt;
  
  
  Main features
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Endpoints can be served with Express or Fastify depending on running &lt;code&gt;node details/indexExpress.js&lt;/code&gt; or &lt;code&gt;node details/indexFastify.js&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Each endpoint can be served by a different port. With this we simulate the concept of microservice. Each one of them runs in a different thread and therefore could be executed independently with different server configurations.&lt;/li&gt;
&lt;li&gt;I have only implemented one type of repository. Data is always served from memory&lt;/li&gt;
&lt;li&gt;I don't strictly follow the layers or folders suggested by "Clean Architecture". I have preferred to group by Entity (animals and fruits) as it is the most important part of the system. In each folder we would always find "Adapters" that act as a bridge with the route published on the server and the "Repository" or data source. By adding more entities we would not have to jump from folder to folder if we had to extend any of the previous classes&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Structure
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;abstract&lt;/code&gt;: As a microframework. Contains classes that will be extended in details or in domain

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;details&lt;/code&gt;: Abstractions of the details. According to "Uncle Bob" the details relate to the technology and not the core of the system. Namely: Database, http server, frameworks, etc.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;domain&lt;/code&gt;: Domain abstractions. "Parent" classes that will be extended with the kernel concretes of the system.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;details&lt;/code&gt;: Classes that implement the technical details of the system&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;domain&lt;/code&gt;: System core classes. The domain is related to the entities and use cases that model our system.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>node</category>
      <category>api</category>
      <category>cleancode</category>
      <category>javascript</category>
    </item>
    <item>
      <title>Odoo and Blockchain, a proposal to innovate</title>
      <dc:creator>Fernando</dc:creator>
      <pubDate>Wed, 14 Apr 2021 16:47:56 +0000</pubDate>
      <link>https://dev.to/flachica/odoo-and-blockchain-a-proposal-to-innovate-2lkl</link>
      <guid>https://dev.to/flachica/odoo-and-blockchain-a-proposal-to-innovate-2lkl</guid>
      <description>&lt;p&gt;What follows is an article of a technical nature. An explanation of how my new module that serves to innovate with #Odoo in the #Ethereum #Blockchain ecosystem is made. It is very simple, but first, a brief introduction:&lt;/p&gt;

&lt;p&gt;I usually discuss it with the people around me. I believe that the solution posed by Blockchain for the challenges that lie ahead is very successful. But there is a problem, it is a combination of technologies that should help us to pivot business models, but there are no products or services on the market that have been decentralized to reach new heights of success. Or at least I haven't heard it. What does resonate a lot is the use of crypto money, speculation with these new types of assets and from time to time a historical maximum like that of recently. But this, attentive readers, in my view is not a disruptive change in the nature of money. It is not taking advantage of Blockchain 100%.&lt;/p&gt;

&lt;p&gt;Well, to what I was going, since I read the last &lt;a href="https://libroblockchain.com/revolucion/"&gt;blockchain book&lt;/a&gt; that fell into my hands, my head did not stop spinning about the matter. We must facilitate innovation in this technology. And what better than joining the world's most used ERP with Blockchain?&lt;/p&gt;

&lt;p&gt;The module I link below is supported by #MetaMask, a well-known crypto wallet. All you have to do is configure this extension with one of your Ethereum public addresses and you will be able to interact with the SmartContract that I have prepared.&lt;/p&gt;

&lt;p&gt;But you will ask me, what does this module do? It's simple, it implements a &lt;a href="https://en.wikipedia.org/wiki/Finite-state_machine"&gt;state machine&lt;/a&gt; within Odoo and makes it public through a Smart Contract. It also provides a universal API, well known and documented. Regarding the specific functionality, if you review the module, you will see that it creates a Contract against the Initiatives / Opportunities model, and that within them 4 states are defined: Draft, Approved, Confirmed and Canceled. Well, what the module does is add these four states to the Initiatives. Once the Odoo user visits an opportunity, the system publishes a Contract in Draft state. Being a public and accessible contract, as well as open, interoperability is total. That is, if you have software that can make JSON API calls yourself, you could change to one of these states and it would be reflected in my system. The potential is quite interesting. It is a twist to the interconnection through APIs. Perhaps to connect two systems does not add much value, but it is greatly facilitated when we talk about more types of software, both proprietary and custom. I'm talking about how we could be sending Contracts from Odoo, signing from WhatsApp or from the management software that "our computer friend" made us and each and every one of them would only have to use a single API. Also, if we used Ether as a currency, we could be charging/paying with this currency saving us a lot of paperwork.&lt;/p&gt;

&lt;p&gt;The module is very simple but the potential is demonstrated. I insist as I have done on other occasions: It is no longer so much about sending us information but rather about reaching an agreement. To make the information we exchange real, traceable and auditable by anyone. And, of course, that the modification history is not changeable. I encourage you to innovate in your business, to do it with Odoo, the best ERP in the world and to put the chain of the header in motion. If you have any questions, you can contact me by this same means.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;INFO: &lt;a href="https://github.com/flachica/ethereum-odoo-addons/tree/main/ethereum_state_machine"&gt;https://github.com/flachica/ethereum-odoo-addons/tree/main/ethereum_state_machine&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>blockchain</category>
      <category>odoo</category>
      <category>erp</category>
      <category>ethereum</category>
    </item>
    <item>
      <title>Blockchain: A matter of trust</title>
      <dc:creator>Fernando</dc:creator>
      <pubDate>Sun, 02 Feb 2020 11:49:10 +0000</pubDate>
      <link>https://dev.to/flachica/blockchain-a-matter-of-trust-57f6</link>
      <guid>https://dev.to/flachica/blockchain-a-matter-of-trust-57f6</guid>
      <description>&lt;p&gt;After the publication of my &lt;a href="https://dev.to/flachica/blockchain-for-the-enterprise-an-opportunity-or-just-smoke-25n1"&gt;first article&lt;/a&gt; related to Blockchain I had the opportunity to discuss with some colleagues and some friends. I have not managed to convince any of them but the discussion was interesting and I leave you in these brief lines.&lt;/p&gt;

&lt;p&gt;The first major confusion that muddles the debate is to understand that Blockchain is the same as crypto currencies.&lt;/p&gt;

&lt;p&gt;Let's do an abstraction exercise: Blockchain is a tool on which to implement processes of exchange of value between peers. These pairs form a network and each element of it can be related to the rest, through safe, clear and auditable processes.&lt;/p&gt;

&lt;p&gt;And now let's do a concrete exercise: I commented above that Blockchain is a technology that operates in peer networks. How are these networks formed in the real world? Well, sometimes peers relate collaboratively with some confidence, such as when there is a customer/supplier relationship. In others, this relationship does not occur. The elements could even become competition. If we look for a case in the real world, this relationship occurs for example in business associations. All of them understand that individually they should earn the maximum benefit, but that if they associate they can establish relationships that defend the sector on which they operate.&lt;/p&gt;

&lt;p&gt;And how does Blockchain apply to all this?&lt;/p&gt;

&lt;p&gt;There are still very few case studies where you can empirically verify the improvement or advantages that Blockchain offers to form stronger human networks. But, I commented in my previous article, that modern society has a crisis of confidence. This deteriorates the quality of the relationships that occur in the groups, leaving the members in an individualistic and annihilating solitude. And this justifies that, at least, there are initiatives that analyze possible solutions from different perspectives.&lt;/p&gt;

&lt;p&gt;Blockchain in my opinion is not, by far, the philosopher's stone on which to solve the challenges of the future. Human issues are not solved by applying technology, it is just the opposite, when humans realize that we have a problem, we create technology to try to solve them.&lt;/p&gt;

&lt;p&gt;But what case studies do we have about Blockchain?&lt;/p&gt;

&lt;p&gt;I also analyzed it in my previous article (for more detail in this answer go to the &lt;a href="https://courses.edx.org/courses/course-v1:LinuxFoundationX+LFS171x+2T2019/course/"&gt;Introduction to Hyperledger course&lt;/a&gt;).&lt;/p&gt;

&lt;p&gt;Few people imagined in the 60s, that we were going to have devices that fit in a pocket with which to contact by using color video with people on the other side of the globe in a matter of seconds and live. Or that we were going to be able to count on this huge amount of data to form and inform ourselves about everything that happens in the world. Or about the harmful phenomena that this causes such as "infoxication", "fake news" or the crisis of attention and dependence on the immediate.&lt;/p&gt;

&lt;p&gt;Well, this technology is still "in diapers". It has not exploited its full potential. Some people imagine that when the Internet emerged everything was smooth but it was not. Today there are already companies that are applying on the supply chain, to guarantee the origin of the raw material of their products, or applying it to the educational processes to offer traceability and transparency on the acquired skills. Also for aid to third parties, so that donations, both material and monetary, reach the destination and are applied on the intended objectives.&lt;/p&gt;

&lt;p&gt;And when the processes fail, who is responsible?&lt;/p&gt;

&lt;p&gt;This doubt is one of the most interesting. It implies a paradigm shift in people's consciousness. Of course, the organization of social issues, supported by the great individual leaderships, have their advantages. That it is easy to assign all the responsibility to a single person, physical or legal, and that it is this who assumes the consequences of a bad practice and if it is not solved we go to higher order institutions such as states or judicial powers.&lt;/p&gt;

&lt;p&gt;But here we have to ask ourselves if this way of relating is the most appropriate for all cases. Where should we put the focus? On the trust generated by the great leaders or the big brands? Or do we put the focus on the processes that must be followed to consolidate that trust? If I had to answer, I would choose the second option because we have to improve the processes that are carried out in the different human relationships. And it is not about eliminating intermediaries, states or breaking with central authorities such as banks. What is involved is to provide mechanisms so that these institutions can better perform their work based on safe, auditable and traceable technologies. It is not about replacing humans with technology in resolving their conflicts, it is about addressing problems with new tools, but first we must recognize that we have those problems. . . . cast . . . That is not so clear.&lt;/p&gt;

&lt;p&gt;Yes all very well, but Blockchain is expensive and there are already technologies that could have solved this much sooner.&lt;/p&gt;

&lt;p&gt;Bruce Schneier (a security expert) comments in &lt;a href="https://www.wired.com/story/theres-no-good-reason-to-trust-blockchain-technology/"&gt;this article&lt;/a&gt;, that this technology does not bring anything new and that what it brings makes it much worse. For from these modest lines I would like to repeat that this technology is in the embryonic phase, that there is a very important effort in the standardization of technological mechanisms for the construction of “distributed trust” in value exchanges between humans and that, in reality , this is a matter of the priorities that as a globalized society we manage to give ourselves.&lt;/p&gt;

&lt;p&gt;Scheneir's approaches are very interesting but his discussion may be made later.&lt;/p&gt;

&lt;p&gt;In the meantime I will continue to turn the question around: Will it be possible for societies to develop methods of building trust in a distributed way or is it more comfortable and useful to rest that weight on the individualist leaderships we know today?&lt;/p&gt;

</description>
      <category>blockchain</category>
      <category>trust</category>
      <category>society</category>
      <category>internet</category>
    </item>
    <item>
      <title>Blockchain for the enterprise: An opportunity or just smoke?</title>
      <dc:creator>Fernando</dc:creator>
      <pubDate>Sun, 19 Jan 2020 11:48:42 +0000</pubDate>
      <link>https://dev.to/flachica/blockchain-for-the-enterprise-an-opportunity-or-just-smoke-25n1</link>
      <guid>https://dev.to/flachica/blockchain-for-the-enterprise-an-opportunity-or-just-smoke-25n1</guid>
      <description>&lt;p&gt;Before entering this analysis I must say that I am a newcomer to this technology. Surely I can make some precision error. Take this article as the opinion of a layman in the matter who intends to cease to be.&lt;/p&gt;

&lt;p&gt;With the emergence of the Internet, society interconnected, communications revolutionized the social landscape, instant messaging, social networks or smartphones are results of an evolution of this tool. Its main objective: to communicate computers over long distances. Those are some of the results, but the philosophical debate that has to guide the evolution of the tool is still there, and some of the questions that are most related to the blockchain are the following: Why should we trust a company that operate on the Internet? Why, if I put my bank account, they will not charge me improperly? Why should I trust that news that someone posted on your blog?&lt;/p&gt;

&lt;p&gt;As you can see, the Internet has brought many advances but there is still a way to go. Blockchain is called to be one more method that changes the way we interact. If the Internet changed the way we communicate, blockchain promises to change the way trust is generated.&lt;/p&gt;

&lt;p&gt;The volatility of financial markets, the distrust generated by some multinationals, pharmaceuticals, food or even the textile sector with their well-known brands, can be questioned. Why do we trust that if we buy a garment of a certain brand, we trust that it is original, it is made of high quality raw material and they have employed workers with adequate social rights? These are not minor issues. In fact, our society suffers a crisis of confidence. If you are interested in this philosophical debate and you want a deeper and specialized analysis, David Pastor Vico in &lt;a href="http://pabiloeditorial.com/web/la-soledad-de-los-pajaros-de-david-pastor-vico"&gt;"La soledad de los pájaros"&lt;/a&gt; dissects the subject very well.&lt;/p&gt;

&lt;p&gt;I don't know if blockchain will eventually improve the methods that human societies need to build and gain trust. If it will serve to create those clans that protect the individual from that annihilating loneliness. Hopefully we can write that &lt;a href="https://es.wikipedia.org/wiki/Aplicaci%C3%B3n_asesina"&gt;Killer App&lt;/a&gt; that, like email, replaced postal mail, revolutionizing our society. What I am convinced of is her need. But I have my doubts. I have seen one and a thousand times how humans choose inappropriate alternatives while having the truly necessary ones at hand.&lt;/p&gt;

&lt;p&gt;With the arrival of this century we have become very impatient. We intend to conquer great challenges in a very short space of time. But this is not so. Lately there have been a lot of great changes, but each of them continue to simmer. Are we so unaccustomed to seeing a good &lt;a href="https://es.wikipedia.org/wiki/Puchero"&gt;"puchero"&lt;/a&gt; that we do not distinguish steam from smoke cooking from the special effects of the marketing industry?&lt;/p&gt;

&lt;p&gt;I suppose that I also have that crisis of confidence, although I must admit that I have some illusion. There are quite a few brands working on this story. From banking multinationals to small Startup specialized in the subject. A very large diversity of companies and sectors working on this blockchain. That hope is what pushes me to be thinking about this matter all the time and with which I have already been able to involve some people.&lt;/p&gt;

&lt;p&gt;If you want to know a little more about the technical details, the possibilities it offers for your company or how society can benefit from this technology, be sure to visit the &lt;a href="https://courses.edx.org/courses/coursehttps://courses.edx.org/courses/course-v1:LinuxFoundationX+LFS171x+2T2019/course/-v1:LinuxFoundationX+LFS171x+2T2019/course/"&gt;Introduction to Hyperledger&lt;/a&gt; course. Especially chapter 5 in which he speaks precisely of all this.&lt;/p&gt;

&lt;p&gt;And if you feel like continuing this story, let's keep in touch. I would be delighted to be able to continue this debate.&lt;/p&gt;

&lt;p&gt;Health, strength and joy!&lt;/p&gt;

</description>
      <category>blockchain</category>
      <category>hyperledger</category>
      <category>trust</category>
      <category>society</category>
    </item>
  </channel>
</rss>
