Skip to main content

Step 0: An Idea for Automatic OCL Benchmark Generation

  • Conference paper
  • First Online:
Software Technologies: Applications and Foundations (STAF 2017)

Part of the book series: Lecture Notes in Computer Science ((LNPSE,volume 10748))

Abstract

Model Driven Engineering (MDE) is an important software development paradigm. Within this paradigm, models and constraints are essential components for expressing specifications of a software artefact. Object Constraint Language (OCL), a specification language that allows users to freely express constraints over different model features. However, one major issue is that the lack of OCL benchmarks makes difficult to evaluate existing and newly created OCL tools. In this paper, we present our initial idea about automatic OCL benchmark generation. The purpose of this paper is to show a developing idea rather than presenting a more formal and complete approach. Our idea is to use an OCL metamodel to sketch abstract syntax trees for OCL expressions, and solve generated typing constraints to produce the concrete OCL expressions. We illustrate this idea by using an example, discuss our work-in-progress and outline challenges to be tackled in the future.

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

Access this chapter

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

Institutional subscriptions

Notes

  1. 1.

    In a more complex scenario, either n3 or n4 could also be an integer or an attribute.

  2. 2.

    In a multiple attributes scenario, the node could be either an integer literal or another integer type attribute.

  3. 3.

    The fully generated benchmark is available at https://github.com/classicwuhao/maxuse/tree/master/maxuse_examples/benchmark.

References

  1. Object Management Group: Object Constraint Language Version 2.4 (2014)

    Google Scholar 

  2. Beckert, B., Keller, U., Schmitt, P.H.: Translating the Object Constraint Language into first-order predicate logic. In: Verify Workshop at FLoC, Copenhagen, Denmark (2002)

    Google Scholar 

  3. Maraee, A., Balaban, M.: Efficient reasoning about finite satisfiability of UML class diagrams with constrained generalization sets. In: Akehurst, D.H., Vogel, R., Paige, R.F. (eds.) ECMDA-FA 2007. LNCS, vol. 4530, pp. 17–31. Springer, Heidelberg (2007). https://doi.org/10.1007/978-3-540-72901-3_2

    Chapter  Google Scholar 

  4. Brucker, A.D., Wolff, B.: HOL-OCL: a formal proof environment for uml/ocl. In: Fiadeiro, J.L., Inverardi, P. (eds.) FASE 2008. LNCS, vol. 4961, pp. 97–100. Springer, Heidelberg (2008). https://doi.org/10.1007/978-3-540-78743-3_8

    Chapter  Google Scholar 

  5. Kyas, M., Fecher, H., de Boer, F.S., Jacob, J., Hooman, J., van der Zwaag, M., Arons, T., Kugler, H.: Formalizing UML models and OCL constraints in PVS. ENTCS 115, 39–47 (2005)

    Google Scholar 

  6. Clavel, M., Egea, M., de Dios, M.A.G.: Checking unsatisfiability for OCL constraints. ECEASST 24 (2009)

    Google Scholar 

  7. Büttner, F., Egea, M., Cabot, J.: On verifying ATL transformations using ‘off-the-shelf’ SMT solvers. In: France, R.B., Kazmeier, J., Breu, R., Atkinson, C. (eds.) MODELS 2012. LNCS, vol. 7590, pp. 432–448. Springer, Heidelberg (2012). https://doi.org/10.1007/978-3-642-33666-9_28

    Chapter  Google Scholar 

  8. Soeken, M., Wille, R., Kuhlmann, M., Gogolla, M., Drechsler, R.: Verifying UML/OCL models using Boolean satisfiability. In: DATE, Dresden, Germany, pp. 1341–1344 (2010)

    Google Scholar 

  9. Queralt, A., Artale, A., Calvanese, D., Teniente, E.: OCL-Lite: finite reasoning on UML/OCL conceptual schemas. Data Knowl. Eng. 73, 1–22 (2012)

    Article  Google Scholar 

  10. Dania, C., Clavel, M.: Ocl2fol+: coping with undefinedness. In: OCL@MoDELS (2013)

    Google Scholar 

  11. Semeráth, O., Vörös, A., Varró, D.: Iterative and incremental model generation by logic solvers. In: Stevens, P., Wąsowski, A. (eds.) FASE 2016. LNCS, vol. 9633, pp. 87–103. Springer, Heidelberg (2016). https://doi.org/10.1007/978-3-662-49665-7_6

    Chapter  Google Scholar 

  12. Przigoda, N., Wille, R., Drechsler, R.: Ground setting properties for an efficient translation of OCL in SMT-based model finding. In: 19th MoDELS, pp. 261–271. ACM (2016)

    Google Scholar 

  13. Dania, C., Clavel, M.: OCL2MSFOL: a mapping to many-sorted first-order logic for efficiently checking the satisfiability of OCL constraints. In: 19th MoDELS, pp. 65–75. ACM (2016)

    Google Scholar 

  14. Soeken, M., Wille, R., Drechsler, R.: Encoding OCL data types for SAT-based verification of UML/OCL models. In: Gogolla, M., Wolff, B. (eds.) TAP 2011. LNCS, vol. 6706, pp. 152–170. Springer, Heidelberg (2011). https://doi.org/10.1007/978-3-642-21768-5_12

    Chapter  Google Scholar 

  15. Wu, H., Monahan, R., Power, J.F.: Exploiting attributed type graphs to generate metamodel instances using an SMT solver. In: 7th TASE, Birmingham, UK (2013)

    Google Scholar 

  16. Cabot, J., Clarisó, R., Riera, D.: On the verification of UML/OCL class diagrams using constraint programming. J. Syst. Softw. 93, 1–23 (2014)

    Article  Google Scholar 

  17. Gogolla, M., Büttner, F., Cabot, J.: Initiating a benchmark for UML and OCL analysis tools. In: Veanes, M., Viganò, L. (eds.) TAP 2013. LNCS, vol. 7942, pp. 115–132. Springer, Heidelberg (2013). https://doi.org/10.1007/978-3-642-38916-0_7

    Chapter  Google Scholar 

  18. Gogolla, M., Cabot, J.: Continuing a benchmark for UML and OCL design and analysis tools. In: Milazzo, P., Varró, D., Wimmer, M. (eds.) STAF 2016. LNCS, vol. 9946, pp. 289–302. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-50230-4_22

    Chapter  Google Scholar 

  19. Wu, H.: Finding achievable features and constraint conflicts for inconsistent metamodels. In: Anjorin, A., Espinoza, H. (eds.) ECMFA 2017. LNCS, vol. 10376, pp. 179–196. Springer, Cham (2017). https://doi.org/10.1007/978-3-319-61482-3_11

    Chapter  Google Scholar 

  20. de Moura, L., Bjørner, N.: Z3: an efficient SMT solver. In: Ramakrishnan, C.R., Rehof, J. (eds.) TACAS 2008. LNCS, vol. 4963, pp. 337–340. Springer, Heidelberg (2008). https://doi.org/10.1007/978-3-540-78800-3_24

    Chapter  Google Scholar 

  21. Wille, R., Soeken, M., Drechsler, R.: Debugging of inconsistent UML/OCL models. In: 2012 DATE, pp. 1078–1083 (2012)

    Google Scholar 

  22. Balaban, M., Maraee, A.: Finite satisfiability of UML class diagrams with constrained class hierarchy. ACM Trans. SEM 22(3), 24:1–24:42 (2013)

    Google Scholar 

  23. Cabot, J., Teniente, E.: A metric for measuring the complexity of OCL expressions. In: Model Size Metrics Workshop@MODELS 2006 (2006)

    Google Scholar 

  24. Cadar, C., Dunbar, D., Engler, D.: KLEE: unassisted and automatic generation of high-coverage tests for complex systems programs. In: 8th USENIX Conference on Operating Systems Design and Implementation, pp. 209–224 (2008)

    Google Scholar 

  25. Peleska, J., Vorobev, E., Lapschies, F.: Automated test case generation with SMT-solving and abstract interpretation. In: Bobaru, M., Havelund, K., Holzmann, G.J., Joshi, R. (eds.) NFM 2011. LNCS, vol. 6617, pp. 298–312. Springer, Heidelberg (2011). https://doi.org/10.1007/978-3-642-20398-5_22

    Chapter  Google Scholar 

  26. Gulwani, S., Jha, S., Tiwari, A., Venkatesan, R.: Synthesis of loop-free programs. In: The 32nd PLDI, pp. 62–73. ACM (2011)

    Google Scholar 

  27. Phothilimthana, P.M., Thakur, A., Bodik, R., Dhurjati, D.: Greenthumb: superoptimizer construction framework. In: 25th CC, pp. 261–262. ACM (2016)

    Google Scholar 

  28. Healy, A., Monahan, R., Power, J.F.: Predicting SMT solver performance for software verification. In: 3rd Workshop on FIDE, pp. 20–37 (2016)

    Google Scholar 

  29. Wu, H.: Generating metamodel instances satisfying coverage criteria via SMT solving. In: The 4th MODELSWARD, pp. 40–51 (2016)

    Google Scholar 

  30. Wu, H.: An SMT-based approach for generating coverage oriented metamodel instances. IJISMD 7, 23–50 (2016)

    Google Scholar 

  31. Wu, H.: MaxUSE: a tool for finding achievable constraints and conflicts for inconsistent UML class diagrams. In: Polikarpova, N., Schneider, S. (eds.) IFM 2017. LNCS, vol. 10510, pp. 348–356. Springer, Cham (2017). https://doi.org/10.1007/978-3-319-66845-1_23

    Chapter  Google Scholar 

  32. Noten, J., Mengerink, J.G.M., Serebrenik, A.: A data set of OCL expressions on GitHub. In: 14th International Conference on Mining Software Repositories

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Hao Wu .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2018 Springer International Publishing AG

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Wu, H. (2018). Step 0: An Idea for Automatic OCL Benchmark Generation. In: Seidl, M., Zschaler, S. (eds) Software Technologies: Applications and Foundations. STAF 2017. Lecture Notes in Computer Science(), vol 10748. Springer, Cham. https://doi.org/10.1007/978-3-319-74730-9_31

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-74730-9_31

  • Published:

  • Publisher Name: Springer, Cham

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

  • Online ISBN: 978-3-319-74730-9

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics