# # Defines the mappings for UDD in D2R (see https://picoforge.int-evry.fr/cgi-bin/twiki/view/Helios_wp3/Web/UltimateDebianDatabaseToRDF) # $Id: mapping.n3 308 2010-08-05 12:01:13Z berger_o $ @prefix map: <file:/home/olivier/d2r-server-0.6/mapping.n3#> . @prefix db: <> . @prefix vocab: <http://testforge.int-evry.fr/d2r-server/vocab/resource/> . @prefix vocabClass: <http://testforge.int-evry.fr/d2r-server/vocab/resource/class/> . @prefix vocabProperty: <http://testforge.int-evry.fr/d2r-server/vocab/resource/property/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix owl: <http://www.w3.org/2002/07/owl#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @prefix jdbc: <http://d2rq.org/terms/jdbc/> . @prefix d2r: <http://sites.wiwiss.fu-berlin.de/suhl/bizer/d2r-server/config.rdf#> . @prefix helios_bt: <http://heliosplatform.sourceforge.net/ontologies/2010/05/helios_bt.owl#> . @prefix bom: <http://www.ifi.uzh.ch/ddis/evoont/2008/11/bom#> . @prefix flow: <http://www.w3.org/2005/01/wf/flow#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix sioc: <http://rdfs.org/sioc/ns#> . #@prefix dc: <http://purl.org/dc/elements/1.1/> . @prefix dc: <http://purl.org/dc/terms/> . #----------------- # FIRST SECTION : general configuration of the D2R environment # CUSTOMIZE d2r:baseURI <> a d2r:Server; rdfs:label "D2R Server"; d2r:baseURI <http://kilauea.int-evry.fr:8180/d2r-server/>; # d2r:port 2020; d2r:documentMetadata [ rdfs:comment "This comment is custom document metadata."; ]; # d2r:vocabularyIncludeInstances true; . # CUSTOMIZE d2rq:jdbcDSN, d2rq:username, d2rq:password map:database a d2rq:Database; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:jdbcDSN "jdbc:postgresql://127.0.0.1/UDD"; # d2rq:jdbcDSN "jdbc:postgresql://localhost/UDD?user=udd&password=coin123"; d2rq:username "udd"; d2rq:password "coin123"; d2rq:resultSizeLimit 500; . #----------------- # Map TABLE 'bugs' to 'debbugs/' prefix as bom:Issue entities ## REMOVE : View d2r_bugs (contents of the bugs table plus de-enumed severity) map:debbugs a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "debbugs/@@bugs.id@@"; d2rq:class helios_bt:BugtrackerIssue; d2rq:classDefinitionLabel "Debian bugs as known in UDD"; . # debbugs/ entities labels map:debbugs_label a d2rq:PropertyBridge; d2rq:belongsToClassMap map:debbugs; d2rq:property rdfs:label; d2rq:pattern "Debian bug #@@bugs.id@@"; . # debbugs/ entities' bom:bugUrl (string required by BOM) map:debbugs_bugurl a d2rq:PropertyBridge; d2rq:belongsToClassMap map:debbugs; d2rq:property bom:bugURL; d2rq:propertyDefinitionLabel "bug URL"; # d2rq:uriPattern "http://bugs.debian.org/@@bugs.id@@"; d2rq:pattern "http://bugs.debian.org/@@bugs.id@@"; . # debbugs/ entities' sameAs to http://bugs.debian.org/xxxx URI map:debbugs_sameasurl a d2rq:PropertyBridge; d2rq:belongsToClassMap map:debbugs; d2rq:property owl:sameAs; d2rq:uriPattern "http://bugs.debian.org/@@bugs.id@@"; . map:debbugs_sameasurl2 a d2rq:PropertyBridge; d2rq:belongsToClassMap map:debbugs; d2rq:property owl:sameAs; d2rq:uriPattern "http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=@@bugs.id@@"; . # debbugs/ entities' bom:number (bug number) map:debbugs_id a d2rq:PropertyBridge; d2rq:belongsToClassMap map:debbugs; d2rq:property bom:number; d2rq:column "bugs.id"; d2rq:datatype xsd:int; . # debbugs/ entities' dc:title (bug number) map:debbugs_title a d2rq:PropertyBridge; d2rq:belongsToClassMap map:debbugs; d2rq:property dc:title; d2rq:propertyDefinitionLabel "bugs title"; d2rq:column "bugs.title"; . #----- # LINK Between binary packages and bugs map:debbugs_bpackage a d2rq:PropertyBridge; d2rq:belongsToClassMap map:debbugs; d2rq:property bom:isIssueOf; d2rq:propertyDefinitionLabel "binary package of bug"; # # # d2rq:column "d2r_bugsouterjoin.package"; # # d2rq:uriPattern "package/@@d2r_bugsouterjoin.package@@"; d2rq:uriPattern "bpackage/@@bugs.package@@"; . #----- # LINK Between source packages and bugs map:debbugs_spackage a d2rq:PropertyBridge; d2rq:belongsToClassMap map:debbugs; d2rq:property bom:isIssueOf; d2rq:propertyDefinitionLabel "source package of bug"; d2rq:uriPattern "spackage/@@bugs.source@@"; . # TODO : needs further testing most probably : # example of <https://bugzilla.gnome.org/show_bug.cgi?id=615782, merged-upstream: http://bugzilla.gnome.org/show_bug.cgi?id=620628> (http://testforge.int-evry.fr:8080/d2r-server/page/debbugs/585794) # Link to other bugs reported elsewhere map:debbugs_forwarded a d2rq:PropertyBridge; d2rq:belongsToClassMap map:debbugs; d2rq:property helios_bt:reportedAlsoIn; d2rq:propertyDefinitionLabel "bugs forwarded"; d2rq:uriColumn "bugs.forwarded"; # d2rq:condition "bugs.forwarded <> ''"; d2rq:condition "bugs.forwarded LIKE 'http%'"; . # map:debbugs_arrival a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:debbugs; # d2rq:property vocab:bugs_arrival; # d2rq:propertyDefinitionLabel "bugs arrival"; # d2rq:column "d2r_bugsouterjoin.arrival"; # d2rq:datatype xsd:dateTime; # . map:DebianStatusTable a d2rq:TranslationTable; # Would need proper state ? by defining debbugs specific ontology d2rq:translation [ d2rq:databaseValue "pending"; d2rq:rdfValue bom:Resolved; ]; d2rq:translation [ d2rq:databaseValue "done"; d2rq:rdfValue bom:Closed; ]; d2rq:translation [ d2rq:databaseValue "forwarded"; d2rq:rdfValue bom:Verified; ]; d2rq:translation [ d2rq:databaseValue "pending-fixed"; d2rq:rdfValue flow:Resolved; ]; d2rq:translation [ d2rq:databaseValue "fixed"; d2rq:rdfValue bom:Closed; ]; . map:debbugs_status a d2rq:PropertyBridge; d2rq:belongsToClassMap map:debbugs; d2rq:property bom:hasState; d2rq:propertyDefinitionLabel "bugs status"; d2rq:uriColumn "bugs.status"; d2rq:translateWith map:DebianStatusTable; . map:debbugs_debbugsstatus a d2rq:PropertyBridge; d2rq:belongsToClassMap map:debbugs; d2rq:property vocabProperty:status; # d2rq:propertyDefinitionLabel "bugs status"; d2rq:column "bugs.status"; d2rq:additionalPropertyDefinitionProperty map:DebbugsStatus; . map:DebbugsStatus a d2rq:AdditionalProperty; d2rq:propertyName rdfs:label; d2rq:propertyValue "Debbugs status"; . # map:SeverityTable a d2rq:TranslationTable; # d2rq:translation [ d2rq:databaseValue "critical"; d2rq:rdfValue debbugs:Critical; ]; # d2rq:translation [ d2rq:databaseValue "wishlist"; d2rq:rdfValue debbugs:Wishlist; ]; # d2rq:translation [ d2rq:databaseValue "minor"; d2rq:rdfValue debbugs:Minor; ]; # d2rq:translation [ d2rq:databaseValue "fixed"; d2rq:rdfValue debbugs:Fixed; ]; # d2rq:translation [ d2rq:databaseValue "grave"; d2rq:rdfValue debbugs:Grave; ]; # d2rq:translation [ d2rq:databaseValue "normal"; d2rq:rdfValue debbugs:Normal; ]; # d2rq:translation [ d2rq:databaseValue "important"; d2rq:rdfValue debbugs:Important; ]; # d2rq:translation [ d2rq:databaseValue "serious"; d2rq:rdfValue debbugs:Serious; ]. # map:debbugs_severity a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:debbugs; # d2rq:property vocab:bugs_severity; # d2rq:uriColumn "d2r_bugsouterjoin.severity"; # # d2rq:propertyDefinitionLabel "bugs severity"; # # d2rq:uriPattern "debbugs:@@d2r_bugsouterjoin.severity@@"; # d2rq:translateWith map:SeverityTable # . #------------- # Map 'debbugs/' bugs to 'bugsubmitters/' accounts # Bugs seen for their submitters (bugs submitted ?), to make queries # into the view instead of the bugs table : the link is made on the # sha1mailto of the email of the submitter map:bugsubm a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "debbugs/@@d2r_v_bug_submitters.id@@"; d2rq:class helios_bt:BugtrackerIssue; d2rq:classDefinitionLabel "Submitted bugs intermediary Classmap : not needed for direct access"; . # Link between sioc:UserAccount and bug's bom:hasReporter map:bugsubm_submitter a d2rq:PropertyBridge; d2rq:belongsToClassMap map:bugsubm; d2rq:property bom:hasReporter; d2rq:uriPattern "bugsubmitters/@@d2r_v_bug_submitters.sha1mailto@@"; . # Maps VIEW 'd2r_v_bug_submitters' to sioc:UserAccount entities in "bugsubmitters/" map:siocsubmitters a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "bugsubmitters/@@d2r_v_bug_submitters.sha1mailto@@"; d2rq:class sioc:UserAccount; d2rq:classDefinitionLabel "Bug submitters accounts intermediary Classmap : not needed for direct access"; . map:siocsubmitters_label a d2rq:PropertyBridge; d2rq:belongsToClassMap map:siocsubmitters; d2rq:property rdfs:label; d2rq:pattern "SIOC account of Debian bug reporter @@d2r_v_bug_submitters.submitter_name@@"; . # sioc account names as extracted from the name part of the submitter emails map:siocsubmitters_name a d2rq:PropertyBridge; d2rq:belongsToClassMap map:siocsubmitters; d2rq:property sioc:name; d2rq:column "d2r_v_bug_submitters.submitter_name"; . # sioc email (mailto+sha1 encoded) of the submitter email map:siocsubmitters_emailsha1 a d2rq:PropertyBridge; d2rq:belongsToClassMap map:siocsubmitters; d2rq:property sioc:email_sha1; d2rq:column "d2r_v_bug_submitters.sha1mailto"; . # Link between sioc accounts and foaf people in "foafcarnivore/" map:siocsubmitters_foaf a d2rq:PropertyBridge; d2rq:belongsToClassMap map:siocsubmitters; d2rq:property sioc:account_of; d2rq:uriPattern "foafcarnivore/@@d2r_v_bug_submitters.mailtosha1@@"; . #----------- # Maps VIEW 'd2r_v_carnivore' to foaf:Persons in 'foafcarnivore/' map:foafcarnivore a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "foafcarnivore/@@d2r_v_carnivore.mailtosha1@@"; d2rq:class foaf:Person; d2rq:classDefinitionLabel "FOAF profile of a Debian contributor"; . map:foafcarnivore_label a d2rq:PropertyBridge; d2rq:belongsToClassMap map:foafcarnivore; d2rq:property rdfs:label; d2rq:pattern "FOAF profile of Debian contributor @@d2r_v_carnivore.name@@"; . # Provide foaf:names (from carnivore entries) to foaf:Persons map:foafcarnivore_name a d2rq:PropertyBridge; d2rq:belongsToClassMap map:foafcarnivore; d2rq:property foaf:name; d2rq:propertyDefinitionLabel "name"; d2rq:column "d2r_v_carnivore.name"; . # DISABLED for privacy issues : don't display email # map:foafcarnivore_address a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:foafcarnivore; # d2rq:property foaf:mbox; # d2rq:propertyDefinitionLabel "email"; # d2rq:uriPattern "mailto:@@d2r_v_carnivore.email@@"; # . # Provides foaf:mbox_sha1sum for foaf:Persons map:foafcarnivore_addressSHA1 a d2rq:PropertyBridge; d2rq:belongsToClassMap map:foafcarnivore; d2rq:property foaf:mbox_sha1sum; d2rq:column "d2r_v_carnivore.mailtosha1"; . # Provides sameAs links between different identities through multiple # GPG keys of same developer known of carnivore map:foafcarnivore_key a d2rq:PropertyBridge; d2rq:belongsToClassMap map:foafcarnivore; d2rq:property owl:sameAs; d2rq:uriPattern "carnivorekey/@@d2r_v_carnivore.key@@"; . # # for those who have submitters known by carnivore # map:debbugs_submitcar a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:debbugs; # d2rq:property debbugs:hasSubmitter; # d2rq:propertyDefinitionLabel "bugs submitter known by carnivore"; # d2rq:uriPattern "foafcarnivore/@@d2r_bugsouterjoin.carnivore_id@@"; # d2rq:condition "d2r_bugsouterjoin.carnivore_id IS NOT NULL" # . # map:debbugs_submitter a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:debbugs; # d2rq:property debbugs:hasSubmitter; # d2rq:propertyDefinitionLabel "bugs submitter"; # # d2rq:uriPattern "foafdebbugs/@@d2r_bugsouterjoin.sha1mail@@"; # d2rq:uriPattern "foafcarnivore/@@bugs.submitter_email@@"; # # d2rq:condition "d2r_bugsouterjoin.carnivore_id IS NULL" # . # map:debbugs_owner a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:debbugs; # d2rq:property vocab:bugs_owner; # d2rq:propertyDefinitionLabel "bugs owner"; # d2rq:column "d2r_bugsouterjoin.owner"; # . # map:debbugs_last_modified a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:debbugs; # d2rq:property vocab:bugs_last_modified; # d2rq:propertyDefinitionLabel "bugs last_modified"; # d2rq:column "d2r_bugsouterjoin.last_modified"; # d2rq:datatype xsd:dateTime; # . # map:debbugs_affects_stable a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:debbugs; # d2rq:property vocab:bugs_affects_stable; # d2rq:propertyDefinitionLabel "bugs affects_stable"; # d2rq:column "d2r_bugsouterjoin.affects_stable"; # d2rq:datatype xsd:boolean; # . # map:debbugs_affects_testing a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:debbugs; # d2rq:property vocab:bugs_affects_testing; # d2rq:propertyDefinitionLabel "bugs affects_testing"; # d2rq:column "d2r_bugsouterjoin.affects_testing"; # d2rq:datatype xsd:boolean; # . # map:debbugs_affects_unstable a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:debbugs; # d2rq:property vocab:bugs_affects_unstable; # d2rq:propertyDefinitionLabel "bugs affects_unstable"; # d2rq:column "d2r_bugsouterjoin.affects_unstable"; # d2rq:datatype xsd:boolean; # . # map:debbugs_affects_experimental a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:debbugs; # d2rq:property vocab:bugs_affects_experimental; # d2rq:propertyDefinitionLabel "bugs affects_experimental"; # d2rq:column "d2r_bugsouterjoin.affects_experimental"; # d2rq:datatype xsd:boolean; # . # map:debbugs_done a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:debbugs; # d2rq:property vocab:bugs_done; # d2rq:propertyDefinitionLabel "bugs done"; # d2rq:column "d2r_bugsouterjoin.done"; # . # # View d2r_t_bugsubmitters (bug submitters with email addresses exploded) # map:foafdebbugs a d2rq:ClassMap; # d2rq:dataStorage map:database; # d2rq:uriPattern "foafdebbugs/@@d2r_t_bugsubmitters.sha1mail@@"; # # d2rq:class vocab:bugs; # d2rq:class foaf:Person; # d2rq:classDefinitionLabel "FOAF profile of a UDD bug submitter"; # . # map:foafdebbugs_submitter_phrase a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:foafdebbugs; # d2rq:property foaf:name; # d2rq:propertyDefinitionLabel "bug submitter name"; # d2rq:column "d2r_t_bugsubmitters.email_phrase"; # . # map:debbugs_submitter_address a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:foafdebbugs; # d2rq:property foaf:mbox; # d2rq:propertyDefinitionLabel "bug submitter email"; # # d2rq:column "d2r_bugsouterjoin.email_address"; # d2rq:uriPattern "mailto:@@d2r_t_bugsubmitters.email_address@@"; # . # map:debbugs_submitter_addressSHA1 a d2rq:PropertyBridge; # d2rq:belongsToClassMap map:foafdebbugs; # d2rq:property foaf:mbox_sha1sum; # d2rq:column "d2r_t_bugsubmitters.sha1mailto"; # . # source packages which have bugs submitted on them map:spackage a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "spackage/@@d2r_spackage.source@@"; d2rq:class helios_bt:DistributionSourcePackage; d2rq:classDefinitionLabel "A Debian source package"; . map:spackage_label a d2rq:PropertyBridge; d2rq:belongsToClassMap map:spackage; d2rq:property rdfs:label; d2rq:pattern "Debian source package @@d2r_spackage.source@@"; . map:spackage_name a d2rq:PropertyBridge; d2rq:belongsToClassMap map:spackage; d2rq:property helios_bt:name; d2rq:column "d2r_spackage.source"; . # Declare source packages same as their corresponding PTS aliases map:spackage_sameaspts a d2rq:PropertyBridge; d2rq:belongsToClassMap map:spackage; d2rq:property owl:sameAs; d2rq:uriPattern "http://packages.qa.debian.org/@@d2r_spackage.source@@"; . # TODO : add pointer to homepage as a doap:homepage or like map:bpackage a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "bpackage/@@d2r_bpackage.package@@"; d2rq:class helios_bt:DistributionBinaryPackage; d2rq:classDefinitionLabel "A Debian binary package"; . map:bpackage_label a d2rq:PropertyBridge; d2rq:belongsToClassMap map:bpackage; d2rq:property rdfs:label; d2rq:pattern "Debian binary package @@d2r_bpackage.package@@"; . map:bpackage_source a d2rq:PropertyBridge; d2rq:belongsToClassMap map:bpackage; d2rq:property helios_bt:isBinaryOf; d2rq:uriPattern "spackage/@@d2r_bpackage.source@@"; . # TODO: add helios_bt:isMergedInto for links in bugs_merged_with #----------------- # Ubuntu bugs # similar mappings as for debbugs map:ubuntulpbug a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "ubuntulpbug/@@ubuntu_bugs.bug@@"; d2rq:class helios_bt:BugtrackerIssue; d2rq:classDefinitionLabel "Ubuntu bugs as known in UDD"; . map:ubuntulpbug_label a d2rq:PropertyBridge; d2rq:belongsToClassMap map:ubuntulpbug; d2rq:property rdfs:label; d2rq:pattern "Ubuntu bug #@@ubuntu_bugs.bug@@"; . map:ubuntulpbug_bugurl a d2rq:PropertyBridge; d2rq:belongsToClassMap map:ubuntulpbug; d2rq:property bom:bugURL; d2rq:propertyDefinitionLabel "bug URL"; d2rq:pattern "http://bugs.launchpad.net/ubuntu/+bug/@@ubuntu_bugs.bug@@"; . # Not sure this one is the best URL... map:ubuntulpbug_sameasurl a d2rq:PropertyBridge; d2rq:belongsToClassMap map:ubuntulpbug; d2rq:property owl:sameAs; d2rq:uriPattern "http://bugs.launchpad.net/ubuntu/+bug/@@ubuntu_bugs.bug@@"; . map:ubuntulpbug_id a d2rq:PropertyBridge; d2rq:belongsToClassMap map:ubuntulpbug; d2rq:property bom:number; d2rq:column "ubuntu_bugs.bug"; d2rq:datatype xsd:int; . map:ubuntulpbug_title a d2rq:PropertyBridge; d2rq:belongsToClassMap map:ubuntulpbug; d2rq:property dc:title; d2rq:propertyDefinitionLabel "bugs title"; d2rq:column "ubuntu_bugs.title"; . # Link with bug reporters map:ubuntulpbug_reporter a d2rq:PropertyBridge; d2rq:belongsToClassMap map:ubuntulpbug; d2rq:property bom:hasReporter; d2rq:uriPattern "lpsiocreporter/@@ubuntu_bugs.reporter_login@@"; . # SIOC UserAccounts for bug reporters map:lpsiocreporter a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "lpsiocreporter/@@ubuntu_bugs.reporter_login@@"; d2rq:class sioc:UserAccount; d2rq:classDefinitionLabel "LP Bug reporters accounts intermediary Classmap : not needed for direct access"; . map:lpsiocreporter_label a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpsiocreporter; d2rq:property rdfs:label; d2rq:pattern "SIOC account of Ubuntu bug reporter @@ubuntu_bugs.reporter_name@@"; . map:lpsiocreporter_name a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpsiocreporter; d2rq:property sioc:name; d2rq:column "ubuntu_bugs.reporter_name"; . # Link between sioc accounts and foaf people map:lpsiocreporter_foaf a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpsiocreporter; d2rq:property sioc:account_of; d2rq:uriPattern "lpuserfoaf/@@ubuntu_bugs.reporter_login@@"; . # FOAF Persons for bug reporters map:lpuserfoaf a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "lpuserfoaf/@@ubuntu_bugs.reporter_login@@"; d2rq:class foaf:Person; d2rq:classDefinitionLabel "FOAF profile of an Ubuntu bug reporter"; . map:lpuserfoaf_label a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpuserfoaf; d2rq:property rdfs:label; d2rq:pattern "FOAF profile of Ubuntu bug reporter @@ubuntu_bugs.reporter_name@@"; . map:lpuserfoaf_name a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpuserfoaf; d2rq:property foaf:name; d2rq:propertyDefinitionLabel "name"; d2rq:column "ubuntu_bugs.reporter_name"; . # Bugs for bug subscribers map:lpbugsubsfoaf a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "ubuntulpbug/@@ubuntu_bugs_subscribers.bug@@"; d2rq:class helios_bt:BugtrackerIssue; . # FOAF Persons for bug subscribers map:lpbugsubsfoaf_subscriber a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpbugsubsfoaf; d2rq:property bom:hasCCPerson; d2rq:uriPattern "lpuserfoaf/@@ubuntu_bugs_subscribers.subscriber_login@@"; . # Bugs for bug subscribers map:lpbugsubsfoaf a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "ubuntulpbug/@@ubuntu_bugs_subscribers.bug@@"; d2rq:class helios_bt:BugtrackerIssue; . #------------------ # Launchpad Tasks # "Upstream bugs" (not sure the criterion is good on distro empty) map:lpbugtaskpackage a d2rq:ClassMap; d2rq:dataStorage map:database; # d2rq:uriPattern "lpbugtaskpackage/@@ubuntu_bugs_tasks.bug@@"; d2rq:uriPattern "ubuntulpbug/@@ubuntu_bugs_tasks.bug@@"; d2rq:class helios_bt:BugtrackerIssue; d2rq:condition "ubuntu_bugs_tasks.distro = ''"; . # Only the package in path map:lpbugtaskpackage_sameasurl a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpbugtaskpackage; d2rq:property owl:sameAs; d2rq:uriPattern "http://bugs.launchpad.net/@@ubuntu_bugs_tasks.package@@/+bug/@@ubuntu_bugs_tasks.bug@@"; . # Link to other bugs reported elsewhere with reportedAlsoIn map:lpbugtaskpackage_watch a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpbugtaskpackage; d2rq:property helios_bt:reportedAlsoIn; d2rq:uriColumn "ubuntu_bugs_tasks.watch"; d2rq:condition "ubuntu_bugs_tasks.watch LIKE 'http%'"; . #-- # Distro bugs in the LP bug tasks # We give them URIs in the form '.../lpbugtaskdistropackage/Debian_134' map:lpbugtaskdistropackage a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "lpbugtaskdistropackage/@@ubuntu_bugs_tasks.distro@@_@@ubuntu_bugs_tasks.bug@@"; d2rq:class helios_bt:BugtrackerIssue; d2rq:condition "ubuntu_bugs_tasks.distro <> ''"; . # Here path contains distro and package # We use postgres expression for the LOWER() map:lpbugtaskdistropackage_sameasurl a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpbugtaskdistropackage; d2rq:property owl:sameAs; d2rq:uriSqlExpression "'http://bugs.launchpad.net/' || LOWER(ubuntu_bugs_tasks.distro) || '/+source/' || ubuntu_bugs_tasks.package || '/+b\ ug/' || ubuntu_bugs_tasks.bug"; . # Link to other bugs reported elsewhere map:lpbugtaskdistropackage_watch a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpbugtaskdistropackage; d2rq:property bom:bugUrl; d2rq:column "ubuntu_bugs_tasks.watch"; d2rq:condition "ubuntu_bugs_tasks.watch LIKE 'http%'"; . #-- # Debian bugs in LP bug tasks : needs the new # 'd2r_t_debian_bugs_tasks' table mapping Ubuntu bugs to their Debian # bugs tasks map:lpbugtaskdistrodebian a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "lpbugtaskdistropackage/Debian_@@d2r_t_debian_bugs_tasks.bug@@"; d2rq:class helios_bt:BugtrackerIssue; . # adds a seeAlso to the Debian bug from table 'bugs' map:lpbugtaskdistrodebian_watch a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpbugtaskdistrodebian; d2rq:property rdfs:seeAlso; d2rq:uriPattern "debbugs/@@d2r_t_debian_bugs_tasks.debian_bugid@@"; . # sameas with canonical Debian URL map:lpbugtaskdistrodebian_sameas a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpbugtaskdistrodebian; d2rq:property owl:sameAs; d2rq:uriPattern "http://bugs.debian.org/@@d2r_t_debian_bugs_tasks.debian_bugid@@"; . #----- # Bind bug tasks for other distros to the Ubuntu bug with reportedAlsoIn links # Special case of tasks that correspond to Ubuntu bugs : we consider # them the same so we don't add a different bug for the "first" # subtask. map:lpbugtaskdistropackage2 a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "ubuntulpbug/@@ubuntu_bugs_tasks.bug@@"; d2rq:class helios_bt:BugtrackerIssue; # d2rq:condition "ubuntu_bugs_tasks.distro <> '' AND ubuntu_bugs_tasks.distro <> 'Ubuntu'"; d2rq:condition "ubuntu_bugs_tasks.distro <> 'Ubuntu'"; . # The URI contains the Distro map:lpbugtaskdistropackage_maintask a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpbugtaskdistropackage2; d2rq:property helios_bt:reportedAlsoIn; d2rq:propertyDefinitionLabel "bugs forwarded"; d2rq:uriPattern "lpbugtaskdistropackage/@@ubuntu_bugs_tasks.distro@@_@@ubuntu_bugs_tasks.bug@@"; . map:lpbugtaskdistropackage_status a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpbugtaskdistropackage2; d2rq:property vocabProperty:status; # d2rq:propertyDefinitionLabel "bugs status"; d2rq:column "ubuntu_bugs_tasks.status"; # d2rq:additionalPropertyDefinitionProperty map:DebbugsStatus; . #----- # LINK Between source packages and bugs map:lpbugtaskubuntupackage a d2rq:ClassMap; d2rq:dataStorage map:database; # d2rq:uriPattern "lpbugtaskdistropackage/@@ubuntu_bugs_tasks.bug@@"; d2rq:uriPattern "ubuntulpbug/@@ubuntu_bugs_tasks.bug@@"; d2rq:class helios_bt:BugtrackerIssue; d2rq:condition "ubuntu_bugs_tasks.distro = 'Ubuntu'"; . map:lpbugtaskubuntupackage_status a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpbugtaskubuntupackage; d2rq:property vocabProperty:status; # d2rq:propertyDefinitionLabel "bugs status"; d2rq:column "ubuntu_bugs_tasks.status"; # d2rq:additionalPropertyDefinitionProperty map:DebbugsStatus; . # Fix Released # Invalid # Fix Committed # New # Opinion # In Progress # Expired # Confirmed # Triaged # Unknown # Incomplete # Won't Fix map:lpbugtaskubuntupackage_spackage a d2rq:PropertyBridge; d2rq:belongsToClassMap map:lpbugtaskubuntupackage; d2rq:property bom:isIssueOf; d2rq:propertyDefinitionLabel "source package of bug"; d2rq:uriPattern "ubuntuspackage/@@ubuntu_bugs_tasks.package@@"; . #--------- # Source packages for ubuntu bugs # source packages which have bugs submitted on them map:ubuntuspackage a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "ubuntuspackage/@@ubuntu_sources.source@@"; d2rq:class helios_bt:DistributionSourcePackage; d2rq:classDefinitionLabel "An ubuntu source package"; . map:ubuntuspackage_label a d2rq:PropertyBridge; d2rq:belongsToClassMap map:ubuntuspackage; d2rq:property rdfs:label; d2rq:pattern "Ubuntu source package @@ubuntu_sources.source@@"; . map:ubuntuspackage_name a d2rq:PropertyBridge; d2rq:belongsToClassMap map:ubuntuspackage; d2rq:property helios_bt:name; d2rq:column "ubuntu_sources.source"; . # Here path contains distro and package map:ubuntuspackage_sameasurl a d2rq:PropertyBridge; d2rq:belongsToClassMap map:ubuntuspackage; d2rq:property owl:sameAs; d2rq:uriPattern "http://bugs.launchpad.net/ubuntu/+source/@@ubuntu_sources.source@@"; . |