Skip to main content

RAML-Based Mock Service Generator for Microservice Applications Testing

  • Conference paper
  • First Online:

Part of the book series: Communications in Computer and Information Science ((CCIS,volume 793))

Abstract

The automation capabilities and flexibility of computing resource scaling in cloud environments require novel approaches to application design. The microservice architectural style, which has been actively developing in recent years, is an approach to design a single application as a suite of small services. Continuous integration approach demands transition from manual testing methods to fully automated methods. The mocking is one of the methods to simplify development and testing of microservice applications. The mock service can be considered as an extension of mock object concept. It simulates the behavior of a web service based on a description of its interface. However, developers need to spend additional efforts on development and support of these mock services. We propose a method that would make it easier to generate mocks for REST services by using RAML specifications of services. Using this approach, we propose an implementation, which provides mock services generation and deployment as Docker containers.

This is a preview of subscription content, log in via an institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   39.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

References

  1. Savchenko, D., Radchenko, G.: Microservices validation: methodology and implementation. In: 1st Ural Workshop on Parallel, Distributed, and Cloud Computing for Young Scientists (Ural-PDC 2015). CEUR Workshop Proceedings, vol. 1531, Yekaterinburg, Russia, pp. 21–28 (2015)

    Google Scholar 

  2. Pahl, C.: Containerization and the PaaS cloud. IEEE Cloud Comput. 2, 24–31 (2015)

    Article  Google Scholar 

  3. Newman, S.: Learning Building Microservices. O’Reilly Media, Inc., Sebastopol (2015)

    Google Scholar 

  4. Kim, T., Park, C., Wu, C.: Mock object models for test driven development. In: Fourth International Conference on Software Engineering Research, Management and Applications, pp. 221–228. IEEE (2006)

    Google Scholar 

  5. Soltesz, S., Potzl, H., Fiuczynski, M., Bavier, A., Peterson, L.: Container-based operating system virtualization: a scalable, high-performance alternative to hypervisors. ACM SIGOPS Oper. Syst. Rev. 41(3), 275–287 (2007)

    Article  Google Scholar 

  6. Fielding, R.: Representational state transfer. In: Architectural Styles and the Design of Network-based Software Architecture, pp. 76–85 (2000)

    Google Scholar 

  7. Haupt, F.: A framework for the structural analysis of REST APIs. In: IEEE International Conference on Software Architecture (ICSA), pp. 55–58 (2017)

    Google Scholar 

  8. Cloves, C., Schmelmer, T.: Defining APIs. In: Microservices from Day One, pp. 59–74. Apress, New York (2016)

    Google Scholar 

  9. Surwase, V.: REST API modeling languages-a developer’s perspective. IJSTE Int. J. Sci. Technol. Eng. 2(10), 634–637 (2016)

    Google Scholar 

  10. API Blueprint. http://apiblueprint.com. Last accessed 15 Apr 2017

  11. Voegler, J., Bornschein, J., Weber, G.: Markdown – a simple syntax for transcription of accessible study materials. In: Miesenberger, K., Fels, D., Archambault, D., Peňáz, P., Zagler, W. (eds.) ICCHP 2014, Part I. LNCS, vol. 8547, pp. 545–548. Springer, Cham (2014). https://doi.org/10.1007/978-3-319-08596-8_85

    Chapter  Google Scholar 

  12. Mountebank - over the wire test doubles. http://www.mbtest.org. Last accessed 15 Apr 2017

  13. Azzam, S., Al-Kabi, M.N., Alsmadi, I.: Web services testing challenges and approaches. In: Proceedings of the 1st Taibah University International Conference on Computing and Information Technology, pp. 291–296 (2012)

    Google Scholar 

  14. Tsouroplis, R., Petychakis, M., Alvertis, I., Biliri, E., Askounis, D.: Community-based API builder to manage APIs and their connections with cloud-based services. In: CAiSE Forum, pp. 17–23 (2015)

    Google Scholar 

  15. Merkel, D.: Docker: lightweight Linux containers for consistent development and deployment. Linux J. 2014(239), 2 (2014)

    Google Scholar 

  16. JSON Schema: syntax and semantics. http://cswr.github.io/JsonSchema/. Last accessed 15 Apr 2017

  17. Grinberg, M.: Flask Web Development: Developing Web Applications with Python. O’Reilly Media, Inc., Sebastopol (2014)

    Google Scholar 

  18. Elizabeth. http://elizabeth.readthedocs.io/en/latest/. Last accessed 15 Apr 2017

  19. Ramlification, Python parser for RAML. https://github.com/spotify/ramlfications. Last accessed 15 Apr 2017

  20. Naumen Service Desk. http://www.naumen.ru/products/service_desk/. Last accessed 15 Apr 2017

  21. Raml-mock-service. https://github.com/veor12/raml-mock-service. Last accessed 15 Apr 2017

Download references

Acknowledgment

The work was supported by the RFBR research project No. 15-29-07959 and by Act 211 Government of the Russian Federation, contract No. 02.A03.21.0011.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Gleb Radchenko .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2017 Springer International Publishing AG

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Ashikhmin, N., Radchenko, G., Tchernykh, A. (2017). RAML-Based Mock Service Generator for Microservice Applications Testing. In: Voevodin, V., Sobolev, S. (eds) Supercomputing. RuSCDays 2017. Communications in Computer and Information Science, vol 793. Springer, Cham. https://doi.org/10.1007/978-3-319-71255-0_37

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-71255-0_37

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-71254-3

  • Online ISBN: 978-3-319-71255-0

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics