Abstract
Existing blockchain smart contract platforms are designed as monolithic architectures. Even though there are multiple smart contracts with fully independent business logic, they run on a single monolithic container. This dependence on a monolithic container can be a performance bottleneck during the processing of a large number of transactions. To address this challenge, microservice-based architecture is adopted in the blockchain smart contracts by introducing a novel architecture to run independently on separate microservices. The new smart contract architecture is built on top of Mystiko blockchain, a functional programming and actor-based “Aplos” concurrent smart contract platform. Aplos is identified as a “Smart Actor” platform since it is built using Actor-based concurrency handling. Based on the philosophy of microservices, the Aplos Smart Actor platform on Mystiko blockchain is redesigned. This architecture is introduced as “SaaS - Smart actors as a service”. With SaaS, different Aplos smart actors in the blockchain are deployed as separate independent services (e.g. docker containers) instead of a single monolith service. This ensures different smart actors can execute transactions independently. An additional benefits to SaaS is that the architecture increases the scalability by guaranteeing concurrent execution of transactions, producing high transaction throughput on the blockchain.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
References
Akka documentation. https://doc.akka.io/docs/akka/2.5/actors.html
Akka streams documentation. https://doc.akka.io/docs/akka/2.5/stream/
How do i accomplish lightweight transactions with linearizable consistency? https://docs.datastax.com/en/cassandra/3.0/cassandra/dml/dmlLtwtTransactions.html
The scala programming language. https://www.scala-lang.org/
Aderaldo, C.M., Mendonça, N.C., Pahl, C., Jamshidi, P.: Benchmark requirements for microservices architecture research. In: 2017 IEEE/ACM 1st International Workshop on Establishing the Community-Wide Infrastructure for Architecture-Based Software Engineering (ECASE), pp. 8–13. IEEE (2017)
Adrian, O.R.: The blockchain, today and tomorrow. In: 2018 20th International Symposium on Symbolic and Numeric Algorithms for Scientific Computing (SYNASC), pp. 458–462. IEEE (2018)
Androulaki, E., et al.: Hyperledger fabric: a distributed operating system for permissioned blockchains. In: Proceedings of the Thirteenth EuroSys Conference, p. 30. ACM (2018)
Bandara, E., Ng, W.K., Ranasinghe, N., De Zoysa, K.: Aplos: smart contracts made smart. In: Zheng, Z., Dai, H.-N., Tang, M., Chen, X. (eds.) BlockSys 2019. CCIS, vol. 1156, pp. 431–445. Springer, Singapore (2020). https://doi.org/10.1007/978-981-15-2777-7_35
Białecki, A., Muir, R., Ingersoll, G., Imagination, L.: Apache lucene 4. In: SIGIR 2012 Workshop on Open Source Information Retrieval, p. 17 (2012)
Burns, B., Grant, B., Oppenheimer, D., Brewer, E., Wilkes, J.: Borg, omega, and kubernetes. Queue 14(1), 70–93 (2016)
Cristescu, I.D., Krivine, J., Varacca, D.: Rigid families for CCS and the \(\pi \)-calculus. In: Leucker, M., Rueda, C., Valencia, F.D. (eds.) ICTAC 2015. LNCS, vol. 9399, pp. 223–240. Springer, Cham (2015). https://doi.org/10.1007/978-3-319-25150-9_14
Dannen, C.: Introducing Ethereum and Solidity. Apress, Berkeley, CA (2017). https://doi.org/10.1007/978-1-4842-2535-6
Davis, A.L.: Akka streams. In: Reactive Streams in Java, pp. 57–70. Springer, Berlin (2019)
Destounis, A., Paschos, G.S., Koutsopoulos, I.: Streaming big data meets backpressure in distributed network computation. In: IEEE INFOCOM 2016-The 35th Annual IEEE International Conference on Computer Communications, pp. 1–9. IEEE (2016)
Eykholt, E., Meredith, L.G., Denman, J.: Rchain architecture documentation. Retrieve. Jan. 19, 2019 (2017)
Fernandes, J.L., Lopes, I.C., Rodrigues, J.J., Ullah, S.: Performance evaluation of restful web services and amqp protocol. In: 2013 Fifth International Conference on Ubiquitous and Future Networks (ICUFN), pp. 810–815. IEEE (2013)
Gormley, C., Tong, Z.: Elasticsearch: the definitive guide: a distributed real-time search and analytics engine. O’Reilly Media, Inc. (2015)
Gupta, M.: Akka essentials. Packt Publishing Ltd, Birmingham (2012)
Harz, D., Knottenbelt, W.: Towards safer smart contracts: A survey of languages and verification methods (2018)
Hewitt, C.: Actor model of computation: scalable robust information systems. arXiv preprint arXiv:1008.1459 (2010)
Hoare, C.A.R.: Communicating sequential processes. Commun. ACM 21(8), 666–677 (1978)
Hughes, J.: Why functional programming matters. Comput. J. 32(2), 98–107 (1989)
Kreps, J., Narkhede, N., Rao, J., et al.: Kafka: a distributed messaging system for log processing. In: Proceedings of the NetDB. pp. 1–7 (2011)
Kurath, A.: Analyzing Serializability of Cassandra Applications. Ph.D. thesis, Master’s thesis. ETH Zürich (2017)
Kwon, J.: Tendermint: Consensus without mining. Draft v. 0.6, fall 1, 11 (2014)
Lakshman, A., Malik, P.: Cassandra: a decentralized structured storage system. ACM SIGOPS Oper. Syst. Revi. 44(2), 35–40 (2010)
Marescotti, M., Blicha, M., Hyvärinen, A.E.J., Asadi, S., Sharygina, N.: Computing exact worst-case gas consumption for smart contracts. In: Margaria, T., Steffen, B. (eds.) ISoLA 2018. LNCS, vol. 11247, pp. 450–465. Springer, Cham (2018). https://doi.org/10.1007/978-3-030-03427-6_33
Merkel, D.: Docker: lightweight linux containers for consistent development and deployment. Linux J. 2014(239), 2 (2014)
Nakamoto, S.: Bitcoin: A peer-to-peer electronic cash system (2008)
O’Connor, R.: Simplicity: A new language for blockchains. In: Proceedings of the 2017 Workshop on Programming Languages and Analysis for Security. pp. 107–120. ACM (2017)
Odersky, M., et al.: An overview of the scala programming language. Technical Report (2004)
Popejoy, S.: The pact smart contract language 2017 (2016)
Sergey, I., Kumar, A., Hobor, A.: Scilla: a smart contract intermediate-level language (2018)
Thönes, J.: Microservices. IEEE Softw. 32(1), 116–116 (2015)
Traiger, I.L., Gray, J., Galtieri, C.A., Lindsay, B.G.: Transactions and consistency in distributed database systems. ACM Trans. Database Syst. (TODS) 7(3), 323–342 (1982)
Zamani, M., Movahedi, M., Raykova, M.: Rapidchain: a fast blockchain protocol via full sharding. IACR Cryptol. ePrint Arch. 2018, 460 (2018)
Zyskind, G., Nathan, O., Pentland, A.: Enigma: decentralized computation platform with guaranteed privacy. arXiv preprint arXiv:1506.03471 (2015)
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2021 Springer Nature Singapore Pte Ltd.
About this paper
Cite this paper
Bandara, E. et al. (2021). SaaS - Microservices-Based Scalable Smart Contract Architecture. In: Thampi, S.M., Wang, G., Rawat, D.B., Ko, R., Fan, CI. (eds) Security in Computing and Communications. SSCC 2020. Communications in Computer and Information Science, vol 1364. Springer, Singapore. https://doi.org/10.1007/978-981-16-0422-5_16
Download citation
DOI: https://doi.org/10.1007/978-981-16-0422-5_16
Published:
Publisher Name: Springer, Singapore
Print ISBN: 978-981-16-0421-8
Online ISBN: 978-981-16-0422-5
eBook Packages: Computer ScienceComputer Science (R0)