Skip to content
  1. Aug 19, 2020
  2. Aug 02, 2020
    • Carlos Garnacho's avatar
      tracker-extract: Handle dummy modules differently · 02f3ca97
      Carlos Garnacho authored
      Dummy files broke with the nie:DataObject/nie:InformationElement
      split, as tracker-extract just did nothing while tracker-miner-fs
      pre-filled the barebones nie:InformationElement.
      
      We should at least fill in the rdf:types and the extra info to tie
      the nie:InformationElement and nie:DataObject together, so return
      a barebones TrackerResource to have that information successfully
      attached.
      
      Fixes extraction of games, ebooks, and other files using a dummy
      extractor.
      02f3ca97
    • Carlos Garnacho's avatar
      tracker-extract: Avoid copying a variable · 8d9f7fed
      Carlos Garnacho authored
      We just copy and free the mime_type variable, just don't do it.
      8d9f7fed
  3. May 04, 2020
    • Carlos Garnacho's avatar
      tracker-extract: Set a deadline of 30 seconds for extraction tasks · 16cccdfe
      Carlos Garnacho authored
      If we stick longer than that for a single file, it would seem there's
      some trouble processing it. As we're no longer guaranteed to stay in
      control of the extraction thread, just exit the process. As the file
      was being processed at the time of exiting, it would fall through the
      retry/ignore paths we have in place for extractor crashes.
      
      This timeout executes on the same thread/main context that called
      tracker_extract_file(). It is guaranteed to trigger since we offload
      extraction tasks to other threads.
      
      This makes tracker-extract resilient to possible infinite loops that
      might happen in 3rd party code via extractor modules.
      
      Fixes: https://gitlab.gnome.org/GNOME/tracker-miners/-/issues/107
      16cccdfe
  4. May 01, 2020
  5. Apr 27, 2020
  6. Jul 14, 2019
    • Sam Thursfield's avatar
      Rename config.h to config-miners.h · 54144c9a
      Sam Thursfield authored
      This fixes compile warnings which show up when we build with
      -Dtracker_core=subproject. This is an example of the kind of
      warning:
      
          [7/186] Compiling C object 'subprojects/tracker/src/tracker-store/7bb4675@@tracker-store@exe/tracker-config.c.o'.
          In file included from ../subprojects/tracker/src/tracker-store/tracker-config.c:21:
          subprojects/tracker/./config.h:25: warning: "GETTEXT_PACKAGE" redefined
             25 | #define GETTEXT_PACKAGE "tracker"
                |
          In file included from <command-line>:
          ./config.h:25: note: this is the location of the previous definition
             25 | #define GETTEXT_PACKAGE "tracker-miners"
                |
      54144c9a
  7. Jul 12, 2019
    • Sam Thursfield's avatar
      Use G_ADD_PRIVATE() instead of g_type_class_add_private() · 121efa6b
      Sam Thursfield authored
      This fixes deprecation warnings about g_type_class_add_private()
      
      The new G_ADD_PRIVATE() method has been around since GLib 2.38 (we
      already depend on 2.40 at minimum).
      
      See this blog post for more details:
      https://www.bassi.io/articles/2013/06/21/the-king-is-dead/
      
      Fixes https://gitlab.gnome.org/GNOME/tracker/issues/115
      121efa6b
  8. Jul 16, 2018
  9. Dec 16, 2017
    • Sam Thursfield's avatar
      Rename libtracker-common to libtracker-miners-common · 3cee7b92
      Sam Thursfield authored and Sam Thursfield's avatar Sam Thursfield committed
      We made a big compromise when splitting tracker core from tracker-miners
      in that the common code that was needed by both parts would end up
      duplicated. It's ugly but it works fine at the moment and allows us to
      keep all of the common code private.
      
      I had an issue when trying to embed tracker core into tracker-miners as
      a Meson subproject though. Having two targets named tracker-common
      caused confusion as duplicate targets aren't allowed, but they are not
      quite equivalent so we can't just pick one or the other.
      
      To work around this, I've renamed the copy in this repo to
      tracker-miners-common. This only affects the target names, not the
      actual function names.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=789725
      3cee7b92
  10. Jun 29, 2017
  11. Dec 08, 2016
  12. Nov 20, 2016
  13. Jul 14, 2016
    • Sam Thursfield's avatar
      Use TrackerResource instead of TrackerSparqlBuilder in all extractors · 8cc026da
      Sam Thursfield authored and Sam Thursfield's avatar Sam Thursfield committed
      For a long time, all the Tracker extractors have manually constructed a
      SPARQL update command using TrackerSparqlBuilder to represent their
      output. This commit changes all of them to use the TrackerResource
      class instead, which makes the code a lot more concise and readable.
      
      This introduces some API breaks in the internal libtracker-extract
      library. This has been a private library since Tracker 0.16 or earlier,
      so it's fine.
      
      If the extractors only output SPARQL then they are only useful to
      people who are using a SPARQL store. Now we can output a serialization
      format like Turtle as well. This will hopefully make the extract modules
      useful outside of Tracker itself.
      
      I've tried to preserve the behaviour of the extractors as much as
      possible, but there are two things that are now handled differently:
      
        * nao:Tag resources are given a fixed URI based on the tag label, such
          as <urn:tag:My_Tag>. Previously they were inserted as blank nodes,
          so tracker-store would give them unique IDs like <urn:uuid:1234...>
      
        * All extractors created nco:Contact resources for content publishers,
          but previously some would assign fixed URIs based on the name
          <urn:contact:James%20Joyce>, while others would insert them as blank
          nodes so they would be assigned unique IDs like <urn:uuid:1234...>.
          Now, all extractors create nco:Contact resources with fixed URIs
          based on the content creator's name.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=767472
      8cc026da
  14. Jun 09, 2016
    • Sam Thursfield's avatar
      tracker-extract: Improve console output for when extraction fails · e5dd641a
      Sam Thursfield authored
      Old output:
      
          tracker_mimetype_info_get_module: assertion 'info != NULL' failed
          No metadata or extractor modules found to handle this file
      
      New output:
      
          file:///uri/of/file: No metadata or extractor modules found to handle this file
      
      The message is now also printed to stderr rather than stdout, so that
      stdout contains only the metadata itself in whatever output format the
      caller chose.
      e5dd641a
  15. Mar 14, 2016
    • Carlos Garnacho's avatar
      tracker-extract: Propagate urn to the TrackerExtractInfo · 389068a3
      Carlos Garnacho authored
      Now that extraction is performed after the file got initially
      inserted and has an URN, there's no reason we can't pass the
      URN to the TrackerExtractInfo. This would make URNs available
      to extract modules, which have some places where the SPARQL
      produced would be clearer.
      
      This actually opens the path for quite a cleanup, we might
      pass a single TrackerSparqlBuilder to extract modules instead
      of doing the postprocessing we currently perform.
      389068a3
  16. Nov 25, 2015
  17. Aug 04, 2015
  18. Jul 03, 2015
  19. Mar 17, 2015
  20. Jul 28, 2014
  21. Mar 18, 2014
  22. Mar 17, 2014
  23. Mar 14, 2014
    • Martyn Russell's avatar
      tracker-extract: Improve logging, too many debug statements · 737755d6
      Martyn Russell authored
      It was hard to see what was going on with most logs as debug comments.
      
      Also all thread messages are now debug and have been moved into the #ifdef for
      other thread events
      
      It's a bit easier to see what is going on now using -v 2 and there is less
      mess with -v 3
      737755d6
  24. Mar 06, 2014
  25. Jan 21, 2014
  26. Jan 13, 2014
  27. Oct 10, 2013
  28. Dec 16, 2011
  29. Dec 09, 2011
-