Ethereum obtains external data
DTV share, Ethereum is an open source public blockchain platform with intelligent contract function. It provides decentralized virtual machines to handle point-to-point contracts through its private cryptocurrency, Ethernet. Key points: open source, smart contract function, public chain platform, Ethernet
Ethereum is an open source public blockchain platform with smart contract function. It provides decentralized virtual machine (Ethereum virtual machine) to process point-to-point contract through its special cryptocurrency ether (also known as "Ethereum")
The token on theblockchain is called ether, and the code is eth. It can be traded in many foreign exchange markets of cryptocurrency, and it is also the medium used to pay transaction fees and computing services on Ethereum
the concept of Ethereum was first proposed by vitalik buterin, a programmer, from 2013 to 2014, inspired by bitcoin, with the general meaning of "next generation cryptocurrency and decentralized application platform", and began to develop through ICO crowdfunding in 2014. As of February 2018, Ethernet is the second highest cryptocurrency in market value, second only to bitcoin
extended data:
Ethereum platform has no characteristics and value. Like programming languages, it's up to entrepreneurs and developers to decide what to use. However, it is clear that some application types benefit more from the functions of Ethereum than others. Ethereum is especially suitable for those applications that automatically interact directly between points or promote group coordination activities across networks
for example, coordinate the application of point-to-point market, or the automation of complex financial contracts. Bitcoin enables indivials to exchange money without the help of financial institutions, banks or governments. The impact of Ethereum may be more profound
in theory, any complex financial activities or transactions can be automatically and reliably carried out on Ethereum with coding. In addition to financial applications, any application scenario with high requirements for trust, security and persistence, such as asset registration, voting, management and Internet of things, will be affected by Ethereum platform on a large scale
If you want to query the transaction records on the main network, you can use Etherscan. However, if you build your own private chain, how should you query the transaction records
the answer is that you need to listen to the logs on the chain, save them in the database, and then query them in the database. For example:
< pre t = "code" L = "Java" > varaddr = & quot& quot;< br />varfilter=web3.eth.filter({fromB lock:0 ,toBlock:' latest', address:addr });< br />filter.get(function(err,transactions){transactions.forEach(function(tx){
vartxInfo=web3.eth.getTransaction(tx.transactionHash);
/ / at this time, the transaction information txinfo can be stored in the database
})< br />}); Pre >
Web3. Eth. Filter() is used to monitor the log on the chain, and Web3. Eth. Gettransaction() is used to extract the information of the specified transaction. Once the transaction information is obtained, it can be stored in the database for query
recommend a practical introction, you can see: Ethereum tutorial
choose your own direction
the cost of developing an interface is not so high. Except for EOS, there is not much data to be chained, which is basically completed locally. As a top blockchain technology developer in China, weisanyun is still a good technology developer.
eth. M is characterized by providing a complete intelligent business blockchain architecture for enterprise users and government partners on the Bi platform, providing users with a perfect data import scheme and a variety of classic distributed computing models, which can more quickly solve users' massive data computing problems and effectively rece enterprise costs, And create a new business model on the basis of data security. Blockchain is a new field that needs to be combined with market demand. We can solve some pain points in the instry in data storage security, data retrieval and data filtering. For blockchain framework, business model and technology, we focus on building mature blockchain procts with the most appropriate and proven technology
blockchain, originally just a settlement system of bitcoin, is essentially a decentralized accounting scheme based on cryptography. The technology used by blockchain itself is not a new concept, but a collection of cryptography technologies. Through ingenious design, it realizes the demand of decentralized settlement. However, it is accompanied by some derivative problems. Users are used to transferring and sharing information in the distributed storage space, namely Internet. However, if we want to complete the transfer of money value, we are used to using centralized and trusted third-party transaction intermediaries, such as banks. Although online payment is becoming more and more popular, bank card and password are still needed to register online payment account. The use of blockchain transactions is decentralized and does not require a third-party intermediary. Blockchain realizes the following three important functions: recording transaction information, verifying identity and establishing contract. It's going to be a big change. Because around the world, financial services are the largest sector in terms of market value. Even if it replaces a small part of business, blockchain can have a huge impact on the traditional financial field. At the same time, eth. M blockchain will also improve the efficiency of data management in the whole field. The function of establishing contracts will make the value of blockchain not limited to the financial field. This is the core of eth. M. blockchain can be used to store any information, even software code. That is to say, it can be realized by programming. When the relevant parties provide the relevant key, the transaction can be executed. The same program can also be used to obtain external data: stock index data, weather, news headlines or other data that can be analyzed by computer. In this way, the pre verified contract can be executed automatically when the specified conditions are met. Contracts executed on the blockchain are called "smart contracts"
in the future, eth. M's smart contract application scenarios are very wide, for example:
1. In the field of electric power, if the smart temperature regulator is used to collect the power utilization status of the smart grid in real time, when the wattage consumed by a certain company is monitored to reach a certain amount, the company account and the electric power company's transfer will be completed, and the automatic payment will be realized
2. In the medical field, if a doctor / patient stores the data of blood glucose meter in the form of blockchain, then the patient's physical sign data can be completely and accurately recorded. Blood glucose data can trigger insulin controller to help patients control blood glucose in a safe range
3. In the field of intellectual property supervision, blockchain can be used to monitor the number of times users use, share and a protected proct.
