Hedera Native Smart Contracts #693
Replies: 10 comments 20 replies
-
Just nothing the need for supported tooling, custody solutions, oracles etc who would need to comply with the new approach or be provided with a service like Hashio to make the compatibility possible. Can we call out the problems this approach will solve? Eg lower cost, high throughput operators etc. |
Beta Was this translation helpful? Give feedback.
-
Would I be correct in saying the idea is pretty much identical to how smart contracts work on Near network? If so would forking Near's runtime layer not be the simplest way to get this implemented? Additionally, programmatic interaction with the HFS, HCS and HTS can be enabled via a precompile contract similar to how this was achieved on the HSCS. Could you clarify gas limits, gas costs and gas prices relative to the HSCS? In addition, how would resources(memory, compute) be distributed between both smart contract services and if throttling is required how would that would work? |
Beta Was this translation helpful? Give feedback.
-
all the points you've mentioned in here have been done and accomplished by our technology, the Smart Nodes. Creating a new virtual machine implies a lot of steps, development power, and costs, this is why i would definetely vote against it. EVM exist since decades now, and even if I don't like the approach of smart contract myself, I must admit EVM is very solid and it's been secured during those decades. If an attack like the one we've seen in those days can still happen on smart contract, do you imagine what could happen if you develop a brand new HVM? there could be any kind of Operating System attack there, from chroot to heap overflow, or whatever else. IMHO the best solution would be to converge our strenght and power by teaching our community one simple thing: all you need is HCS, HFS, HTS. If you want to add a layer on top of them to oversimplify their usage and speed up the development, we've done this already. let's join our strenght and development power, we're open to any collaboration, but please let's avoid keep wasting time, energy and money into bulding something which would just add a layer of risk without any real advantage at all. |
Beta Was this translation helpful? Give feedback.
-
I do think that having a trustless layer that is native to Hedera is necessary since Hedera is not a blockchain and in whatever way it is when transforming a code from a blockchain to hashgraph will always have its own vulnerabilities. If we can achieve this without the need of creating a virtual machine would be amazing. Creating a Hedera Virtual Machine for this sounds costly in both energy consumption and fee and may affect the speed of the network reaching consensus. |
Beta Was this translation helpful? Give feedback.
-
The idea of having another trustless layer of execution which is native to Hedera, could enable engineers from many walks of life to participate in creating decentralized applications without needing to learn Solidity, and perhaps at a higher TPS than the EVM layer currently can handle. I am all for something like this, however, it would be great to see an architecture diagram (through UML) that clearly denotes each service and how they interface with one another. @HGraphPunks would you be able to include that in your proposal? |
Beta Was this translation helpful? Give feedback.
-
Cross-posting from slack Interesting idea, in the same vain I’ve postulated/experimented that storing composable units of code in HCS message in a terse language such as clojure combined with a defined schema for composition could be useful in helping build out a Lego of reusable code blocks where the author could be paid per “HVM” execution cycle. For this additional outcome like this to occur HVM or similar would need to happen. However, due to the large scope and risk of securitization/compliance implications it’s going to be curious to see the reaction. Ultimately, if this did fail to pass would the idea be to create an L2 (similar to HSUITE - I believe the ideas are similar) that could drive to same outcome? |
Beta Was this translation helpful? Give feedback.
-
Personally based on spirit/philosophy, I think this is the wrong direction... I'd want more industry compatibility, not less. Additionally, Hedera has plenty to worry about in their roadmap (when can I run a node? when is sharding implemented? when will we get better dev tools? there's no clarity on these things after 4-5 years...) & this seems to be a total distraction from genuine decentralization, especially when you already have the tools available to write logic on-chain. Plus, if you truly wish to build your own execution env, use HCS & push Hedera to get a bridge/interface from HCS to other services - that is what it was built for. |
Beta Was this translation helpful? Give feedback.
-
For any DLT, it is important to consider short and long term adoption. Programming LanguagePopularity
Let's take a look at the Stack Overflow Developer Survey for 2022.
You see similar figures for developers who are learning to code as well. Talent PoolThe talent pool for any language: JS, Python, Java, and C# is much larger than the talent pool for Solidity. SecurityIt is important to consider why Solidity was created in the first place:
Solidity had all the above in mind for its creation. And these are still common, but solved problems for the most popular languages. Talent QualityWe should also consider experience levels of Solidity developers. Because Solidity was designed with DLT-specific security features in mind does not mean there are no security risks. Experienced software engineers can navigate and introduce proven patterns and security practices into the DLT ecosystem, but have a hard time entering the DLT ecosystem due to the friction of developing on the EVM, learning Solidity, Oracles, json-rpc, etc. Use casesMost popular applications are built on JS, Java, C#, Python, Ruby, etc. While there are some popular applications build on the EVM, they are not at the scale of Facebook Marketplace, Youtube, VISA/MasterCard, Stripe, Discord, etc. Building an HVM to support the languages that massive use cases have been built on does not mean Hedera would gain massive adoption, but it does mean that the barrier for entry for developers of massive use cases will be able to on-board and experience the benefits of DLTs more easily. Consider the HVM as a way to bring high quality talent into the DLT space and accelerate it's growth. Only 1.52% of experience devs know Solidity. They are not likely to experiment with a new language, APIs, and concepts to prove a novel idea. But they are much more likely to explore a new API, library, or runtime using their language of choice. For many developers, the concept of building trustless, serverless, scalable code with a built-in audit-able database is very appealing, but the barrier to entry is very high. Please consider what a low barrier to entry trustless code execution platform could do for Hedera's adoption rate. |
Beta Was this translation helpful? Give feedback.
-
@HGraphPunks I'm re-reading this (several months later), and have more thoughts:
One of the things that I think would make it worth the effort of building and maintaining One specific limitation of the EVM that severely limits what kinds of applications are able to be built on it If say, we were not limited to using HFS to store key-value pairs, Within the Hedera-native version of HSCS that you are proposing, |
Beta Was this translation helpful? Give feedback.
-
@HGraphPunks apart from language popularity, another rather important factor to consider is addressing one of the fundamental problems with EVM/ Solidity, which is that is is quite hard to audit. Picking a target language (or multiple target languages) that lend themselves to formal verification techniques would be ideal. That being said I'm not sure if there are any languages that lie in the intersection between these 2 requirements.
|
Beta Was this translation helpful? Give feedback.
-
Overview:
This is the initial discussion starter to conceptualize the future of native hashgraph smart contracts. I believe the future of smart contract execution on Hedera is the combination of the 3 native Hedera services being used in conjunction together to do trustless execution of complex logic.
Objective:
Create methods of trustless execution of logic on Hedera that is native and does not require developers to learn solidity or use EVM smart contracts.
Initial Idea:
Here's the initial thoughts on how the three services could be used together to achieve this outcome.
Hedera File Service
Hedera Consensus Service
Hedera Token service
Ramifications:
I imagine there are many ramifications with this idea and I’m looking forward to discussing the benefits and costs of how Hedera Native Smart Contracts could be achieved. Here are the two major updates I think this functionality would require.
HVM (Hedera Virtual Machine):
This HIP introduces Hedera Virtual Machines to process Hedera Native Smart Contracts. Just like EVM processes logic and executes transactions onto a blockchain, HVM would be needed to process the logic of the contracts and post native Hedera transactions to the mainnet through the other Hedera services.
HVM would allow the nodes that currently exist to not have to support the memory execution of the logic as well as the network. Fees for execution would go to operators of the HVM.
Initial thoughts and discussions with developers, HVMs could use WASM to execute the contracts for mass compatibility.
File Service Extension
The current length of files in the file service are restricted to a certain length and size. This will need to be updated to allow bigger files to be stored. The rent and cost of execution should be defined by the length of the file like how SC currently work through EVM.
Last Thoughts:
I believe the future of hashgraph technology can be obtained by focusing on the extension and development of Hedera native services to best execute application logic needed for block chain parity today, and innovation in Web3 tomorrow.
The ability for Hedera only devs to create native trustless execution logic will bring a new frontier to the Web3 space and be a path to innovation that building on Hedera provides.
Beta Was this translation helpful? Give feedback.
All reactions