• Ei tuloksia

What actions can be proposed to reduce the complexity of the CMDB and improve its maintainability?

It should be noted that this is the partial answer, as the sub-questions on maintainability in Chapter 5 do not exhaustively cover all possible aspects of the ontology maintainability. The ontology maintainability was achieved primarily by designing the simple, small, and reusable ontology utilizing the best practices. Starting with the small ontology and gradually expanding it reduces the risk of accumulating unnecessary information in the ontology. In addition, the number of the CIs was reduced by utilizing the collective CI pattern for elements that pose little risk to the primary operation of the

SOI and therefore do not require to be distinguished as individuals based on the serial number.

During the project definition phase, it was noted that the domain experts cannot always provide useful requirements alone, so the input of ontology-building developer, in this case the author, was required to incorporate constraints. The involvement of developer in the design of the requirements was critical in concretizing the competency questions applicable to the ontology, and also in prioritizing which requirements can be implemented within the schedule. Ontology development differs from object-oriented programming in that the structure of the class and the relationships between the ontology classes differ from the structure of the corresponding domain of the object-oriented program. Therefore, the developers and the domain experts may require training before they can work with the challenges of real-world ontology modelling, even if they have previous experience in conceptual modelling.

In conclusion, the CMDB architecture could consist of small and independent graph databases stored on RDF4J servers and maintained locally near the SOI, as shown in Figure 34. Federated SPARQL queries consolidate data so that only the relevant information is downloaded and data at rest remains in the local CMDB graph databases.

RDF4J Desktop and FedX provide transparent federation for the multiple SPARQL endpoints by automatically selecting relevant sources, submitting expression templates to these sources for evaluation, and merging individual results.

Figure 34. The proposed CMDB architecture.

Federation With FedX

In summary from the above discussion, it can be concluded that the future development of the ontology and the database application can be divided into two tasks. Firstly, the quality of the ontology can be improved by testing and utilizing it with real-world data.

For this purpose, the actual graph database server providing the SPARQL endpoint services and the web-based client interface for the database management and query execution should be installed and deployed in the data centre. Secondly, the next stage of development could include the development of quality metrics such as Ontology Quality Evaluation Framework (OQuaRE) [20] to support the development of the next generation ontology. This thesis examined the ontology mainly from the perspective of maintainability, but subsequent iterations could utilize the metrics that capture issues related to structural, functional adequacy, reliability, performance efficiency, compatibility, portability, and quality of use.

References

1 Millog Oy. [Internet]. 2018 [cited 2020 Jul 10]. Available from: https://millog.fi/

2 NATO Standardization Office. ACMP-2009 Guidance on configuration management edition A version 2. Brussels: NSO; 2017.

3 Finnish Standards Association. ISO/IEC 20000-1 Information technology - Service management - Part 1: Service management system requirements.

Helsinki: SFS; 2018.

4 Finnish Standards Association. ISO/IEC 20000-2 Information technology - Service management - Part 2: Guidance on the application of service management systems. Helsinki: SFS; 2019.

5 NATO Standardization Agency. ACMP-7 NATO Configuration management guidance on the application of ACMP 1 – 6 edition 2. Brussels: NSA; 2007.

6 Lichter H, Schneider-Hufschmidt M, Zullighoven H. Prototyping in industrial software projects-bridging the gap between theory and practice. IEEE Transactions on Software Engineering. 1994; 20(11): 825 – 832.

7 Peffers K, Tuunanen T, Gengler C E, Rossi M, Hui W, Virtanen V, Bragge J.

The Design Science Research Process: A Model for Producing and Presenting Information Systems Research. In: 1st International Conference Proceedings;

2006; Claremont Graduate University, California: DESRIST; 2006:83 – 106.

8 Brenner M, Gillmeister M. Designing CMDB data models with good utility and limited complexity. In: 2014 IEEE/IFIP Network Operations and Management Symposium (NOMS); 2014; Krakow, Poland: IEEE; 2014:1 – 15. Available from:

https://doi.org/10.1109/NOMS.2014.6838375

9 Fowler M. Analysis Patterns: Reusable Object Models. Addison-Wesley Professional; 2015.

10 Obrst L. Ontologies for semantically interoperable systems. In: CIKM03 12th International Conference on Information and Knowledge Management; 2003;

New Orleans, Louisiana, USA: Association for Computing Machinery; 2003:

366– 369. Available from: https://doi.org/10.1145/956863.956932

11 Uschold M, Gruninger M. Ontologies: principles, methods and applications. The Knowledge Engineering Review. Cambridge University Press; 1996; 11(2): 93–

136. Available from: https://doi.org/10.1017/S0269888900007797

12 Musen M A. The Protégé project: A look back and a look forward. AI Matters.

SIGAI; 2015; 1(4): Available from:

https://dl.acm.org/doi/10.1145/2757001.2757003

13 Wong K Y, Ray P, Parameswaran N, Strassner J. Ontology mapping for the interoperability problem in network management. IEEE Journal on Selected Areas in Communications. 2005; 23(10): 2058-2068.

14 Shahri H H, Hendler J A, Porter A A. Software configuration management using ontologies. In: 3rd International Workshop on Semantic Web Enabled Software Engineering (SWESE); 2007; Innsubruk, Austria: ESWC; 2007.

15 Na-Lampang N, Vatanawood W. Development of an ontology-based configuration management system. In: 8th International Conference on Electronics, Computers and Artificial Intelligence (ECAI); 2016; Ploiesti, Romania: IEEE; 2016: 1–6. Available from:

https://doi.org/10.1109/ECAI.2016.7861164

16 Apache Jena. [Internet]. 2020 [cited 2020 Oct 18]. Available from:

https://jena.apache.org/

17 Noy N F, McGuinness D L. Ontology Development 101: A Guide to Creating Your First Ontology. [Internet]. Stanford, CA: Stanford University. 2014 Feb 13 [cited 2020 Jul 12]. Available from:

https://protegewiki.stanford.edu/wiki/Ontology101

18 DMTF. CIM Schema [Internet]. 2020 [2.53.0 4 Mar 2020; cited 2020 Jul 12].

Available from: https://www.dmtf.org/standards/cim

19 CIMTool. [Internet]. 2013 [cited 2020 Jul 12]. Available from:

https://wiki.cimtool.org/

20 Duque-Ramos A, Fernández-Breis J T, Iniesta M, Dumontier M, Aranguren M E, Schulz S, Aussenac-Gilles N, Stevens R. Evaluation of the OQuaRE

framework for ontology quality. Expert Systems with Applications. 2013; 40(7):

2696-2703.

21 W3C Working Group Note. RDF 1.1 Primer [Internet]. 2014 [cited 2020 Jul 12].

Available from: https://www.w3.org/TR/rdf11-primer/

22 W3C Recommendation SPARQL Query Language for RDF. [Internet]. 2008 [cited 2020 Jul 12]. Available from: https://www.w3.org/TR/rdf-sparql-query/

23 W3C Recommendation. OWL 2 Web Ontology Language Primer (Second Edition) [Internet]. 2012 [cited 2020 Jul 12]. Available from:

https://www.w3.org/TR/owl-primer/

24 W3C Semantic web. [Internet]. 2015 [cited 2020 Jul 12]. Available from:

https://www.w3.org/standards/semanticweb/

25 Prot U, Horridge M, Knublauch H, Rector A, Stevens R, Wroe C, Brandt S. A Practical Guide to Building OWL Ontologies Using Protégé 4 and CO-ODE Tools. Matrix. 2011; 0-107.

26 IETF. RFC 3986 - URI Generic Syntax [Internet]. 2005 [cited 2020 Jul 12].

Available from: https://tools.ietf.org/html/rfc3986

27 IETF. RFC 2141 - URN Syntax [Internet]. 2005 [cited 2020 Jul 12]. Available from: https://tools.ietf.org/html/rfc3986

28 IETF. RFC 1738 - Uniform Resource Locators (URL) [Internet]. 1994 [cited 2020 Jul 12]. Available from: https://tools.ietf.org/html/rfc1738

29 W3C Recommendation. RDF 1.1 XML Syntax [Internet]. 2014 [cited 2020 Jul 12]. Available from: https://www.w3.org/TR/rdf-syntax-grammar/

30 W3C Recommendation. RDF 1.1 Turtle [Internet]. 2014 [cited 2020 Jul 12].

Available from: https://www.w3.org/TR/turtle/

31 W3C Working Group Note. RDF 1.1 JSON Alternate Serialization (RDF/JSON) [Internet]. 2013 [cited 2020 Jul 12]. Available from: https://www.w3.org/TR/rdf-json/

32 W3C Recommendation. RDF 1.1 N-Triples [Internet]. 2014 [cited 2020 Jul 12].

Available from: https://www.w3.org/TR/n-triples/

33 W3C Recommendation. RDF 1.1 TriG [Internet]. 2014 [cited 2020 Jul 12].

Available from: https://www.w3.org/TR/trig/

34 W3C Team Submission. Notation3 (N3): A readable RDF syntax [Internet].

2011 [cited 2020 Jul 12]. Available from:

https://www.w3.org/TeamSubmission/n3/

35 W3C Recommendation. RDF 1.1 N-Quads [Internet]. 2014 [cited 2020 Jul 12].

Available from: https://www.w3.org/TR/n-quads/

36 W3C Recommendation. OWL 2 Web Ontology Language Document Overview (Second Edition) [Internet]. 2012 [cited 2020 Jul 12]. Available from:

https://www.w3.org/TR/owl2-overview/

37 Abburu S. A survey on ontology reasoners and comparison. International Journal of Computer Applications. 2012; 57(17): 33 – 39.

38 Martinez-Cruz C, Martinez-Cruz C, Blanco I, Blanco I, Vila M, Vila M.

Ontologies versus relational databases: are they so different? A comparison.

Artif Intell Rev. Springer Nature; 2012; 38(4): 271–290. Available from:

10.1007/s10462-011-9251-9

39 Wikidata Query Service. [Internet]. 2020 [cited 2020 Jul 10]. Available from:

https://query.wikidata.org/

40 Eclipse RDF4J. [Internet]. 2020 [cited 2020 Jul 10]. Available from:

https://rdf4j.org/

41 Yoon, B. H., Kim, S. K., & Kim, S. Y. (2017). Use of graph database for the integration of heterogeneous biological data. Genomics & informatics, 15(1), 19.

42 Bezerra C, Freitas F, Santana F. Evaluating Ontologies with Competency Questions. In: 2013 IEEE/WIC/ACM International Joint Conferences on Web Intelligence (WI) and Intelligent Agent Technologies (IAT); 2013; Atlanta, GA, USA: IEEE 2013: 284 – 285.

43 Rector A, Drummond N, Horridge M, Rogers J, Knublauch H, Stevens R, Wang H, Wroe C. OWL pizzas: Practical experience of teaching OWL-DL: Common errors & common patterns. In: 14th International Conference on Knowledge Engineering and Knowledge Management; 2004; Northamptonshire, UK:

Springer, Berlin; 2004: 63 – 81.

44 Manifesto for Agile Software Development. [Internet]. 2020 [cited 2020 Jul 12].

Available from: https://www.agilealliance.org/agile101/the-agile-manifesto/

45 Beck K. Test-driven development: by example. Addison-Wesley Professional;

2003.

46 Schekotihin K, Rodler P, Schmid W, Horridge M, Tudorache T. Test-Driven Ontology Development in Protégé. In: 9th International Conference on Biological Ontology (ICBO); 2018; Corvallis, Oregon, USA: CEUR; 2018: vol 2285.

47 SPDX. Software Package Data Exchange (SPDX®) Specification Version 2.2 [Internet]. 2020 [cited 2020 Oct 04]. Available from: https://spdx.dev/

48 ISO/IEC 19770-2:2015 Information technology - IT asset management - Part 2:

Software identification tag edition 2. ISO; 2015.

49 Eclipse RDF4J. [Internet]. 2020 [cited 2020 Oct 15]. Available from:

https://rdf4j.org/

50 Apache Maven. [Internet]. 2020 [cited 2020 oct 15]. Available from:

https://maven.apache.org/

51 Cellfie. [Internet]. 2020 [cited 2020 Oct 15]. Available from:

https://github.com/protegeproject/cellfie-plugin

52 OntoGraf. [Internet]. 2020 [cited 2020 Oct 15]. Available from:

https://protegewiki.stanford.edu/wiki/OntoGraf

53 Lohmann S, Negru S, Haag F, Ertl T. Visualizing Ontologies with VOWL.

Semantic Web. 2016; 7(4): 399 – 419.

54 Motik B, Shearer R, Horrocks I. Hypertableau reasoning for description logics.

Journal of Artificial Intelligence Research, 36; 2009: 165-228.

55 GitHub. [Internet]. 2020 [cited 2020 Oct 15]. Available from: https://github.com/

56 Valkonen H. Onto-CMDB. Finland. 2020; DOI: 10.5281/zenodo.4090957.

Available from: https://github.com/val0tus/Onto-CMDB/tree/2.0.

57 RDFUnit: an RDF Unit-Testing suite. [Internet]. 2020 [cited 2020 Oct 15].

Available from: https://github.com/AKSW/RDFUnit

58 JUnit. [Internet]. 2020 [cited 2020 Oct 15]. Available from:

https://junit.org/junit5/

59 Kontokostas D, Westphal P, Auer S, Hellmann S, Lehmann J, Cornelissen R, Zaveri A. Test-driven evaluation of linked data quality. In Proceedings of the 23rd international conference on World Wide Web; 2014: 747-758.

Rio parser uploads Turtle file to RDF4J NativeStore

public static void main(String[] args) {

// Define the constants

File dataDir = new File("C:/Users/Default

User.Lenovo/Documents/yamk/YAMK/THESIS/datadir");

String filename = "C:/Users/Default

User.Lenovo/Documents/yamk/YAMK/THESIS/Onto-CMDB.ttl";

// Define RDF4J NativeStore database String indexes = "spoc,posc,cosp";

Repository db = new SailRepository(new NativeStore(dataDir, indexes));

InputStream input = null;

model = Rio.parse(input, "", RDFFormat.TURTLE);

} catch (RDFParseException | UnsupportedRDFormatException | IOException e) {

try (RepositoryConnection conn = db.getConnection()) {

// Add the model to database conn.add(model);

}

catch (RDF4JException e) { }

finally {

// shut down the database db.shutDown();

} } }

The feature unit test cases

@Test

public void testIfhasSWIDandProductTitle() throws Exception { try (RepositoryConnection conn = db.getConnection()) {

String query = "PREFIX : http://www.semanticweb.org/defaultuser/

ontologies/2020/7/Onto-CMDB#> \n"

+ "ASK { :CISCO_IOS_12_4 :hasSWID :Cisco_IOS . :Cisco_IOS :ProductTitle \"Cisco IOS

\"^^xsd:string } \n";

BooleanQuery booleanQuery =

conn.prepareBooleanQuery(QueryLanguage.SPARQL,query);

assert(booleanQuery.evaluate());

conn.close();

db.shutDown();

} }

@Test

public void testIfhasPhysicalElement() throws Exception { try (RepositoryConnection conn = db.getConnection()) {

String query = "PREFIX : <http://www.semanticweb.org/defaultuser/

ontologies/2020/7/Onto-CMDB#> \n"

+ "ASK { :CISCO1841_002 :hasPhysicalElement :Cisco_1841_chassis . } \n";

BooleanQuery booleanQuery =

conn.prepareBooleanQuery(QueryLanguage.SPARQL,query);

assert(booleanQuery.evaluate());

conn.close();

db.shutDown();

} }

@Test

public void testIfhasLocation() throws Exception { try (RepositoryConnection conn = db.getConnection()) {

String query = "PREFIX : <http://www.semanticweb.org/defaultuser/

ontologies/2020/7/Onto-CMDB#> \n"

+ "ASK { :CISCO1841_001 :hasLocation :M1_Riihimaki } \n";

BooleanQuery booleanQuery =

conn.prepareBooleanQuery(QueryLanguage.SPARQL,query);

assert(booleanQuery.evaluate());

conn.close();

db.shutDown();

} }

The schema unit test cases

import com.opencsv.CSVWriter;

public Writer fileWriter;

@Test

public void testCountofClasses() throws Exception { try (RepositoryConnection conn = db.getConnection()) {

String query = "PREFIX : <http://www.semanticweb.org/defaultuser/

ontologies/2020/7/Onto-CMDB#> \n"

+ "SELECT DISTINCT (strafter(str(?s), \"#\") as ?fragment) WHERE {?s a owl:Class} \n";

TupleQuery tupleQuery =

conn.prepareTupleQuery(QueryLanguage.SPARQL,query);

String[] header = {"Classes"};

fileWriter = new FileWriter("C:/TEMP/test.csv", false);

CSVWriter csvWriter = new CSVWriter(fileWriter, ',', CSVWriter.NO_QUOTE_CHARACTER, CSVWriter.NO_ESCAPE_CHARACTER, CSVWriter.DEFAULT_LINE_END);

csvWriter.writeNext(header);

try (TupleQueryResult res = tupleQuery.evaluate()) {

csvWriter.writeNext(new String[]

{solution.getValue("fragment").toString()});

@Test

public void testReadCSVFile() throws Exception {

BufferedReader csvReader = new BufferedReader(new

FileReader("C:/TEMP/test.csv"));

System.out.println(Arrays.toString(data));

}

public void testCountofProduct() throws Exception { try (RepositoryConnection conn = db.getConnection()) {

String query = "PREFIX : <http://www.semanticweb.org/defaultuser/

ontologies/2020/7/Onto-CMDB#> \n"

+ "SELECT ?s WHERE {?s rdf:type :Product } \n";

TupleQuery tupleQuery =

conn.prepareTupleQuery(QueryLanguage.SPARQL,query);

try (TupleQueryResult res = tupleQuery.evaluate()) { int count = 0;

@Test

public void testCountofFRU() throws Exception {

try (RepositoryConnection conn = db.getConnection()) {

String query = "PREFIX : <http://www.semanticweb.org/defaultuser/

ontologies/2020/7/Onto-CMDB#> \n"

+ "SELECT * WHERE {?s ?y :MEM1800-64CF} \n";

TupleQuery tupleQuery = conn.prepareTupleQuery(QueryLanguage.SPARQL,query);

try (TupleQueryResult res = tupleQuery.evaluate()) {

int count = 0;

while (res.hasNext()) {

BindingSet solution = res.next();

System.out.println("?s = " + solution.getValue("s"));

count++;

}

assertEquals(2, count);

} finally {

conn.close();

db.shutDown();

} } }