Skip to content

Toolchain: CONTENTdm compound PDFs #492

@xing93111

Description

@xing93111

On this page:
https://github.com/MarcusBarnes/mik/wiki/Toolchain:-CONTENTdm-compound-PDFs
I read for compound PDFs, CdmPhpDocuments class should be used. However, when I run mik

billg@lib10:/data/projects/arca$ ./mik/mik -c ./collections/AUebooks/config.ini
Commencing MIK.
PHP Fatal error:  Uncaught Error: Class 'mik\filegetters\CdmPhpDocuments' not found in /data/projects/arca/mik/mik:170
Stack trace:
#0 {main}
  thrown in /data/projects/arca/mik/mik on line 170

Then, I went to mik/src/filegetters and mik/src/writers. I found a class named CdmPdfDocuments. So I thought maybe there are typos on the document, and changed the class name to CdmPdfDocuments. However, it still does not work. The output gives corrupted PDFs.

This is the collection: http://digicon.athabascau.ca/cdm/landingpage/collection/AUebooks

The following is my configuration ini file:

; Trying out the compound thing

[CONFIG]
config_id = AUebooks
last_updated_on = "2018-10-11"
last_update_by = "hx"

[FETCHER]
class = Cdm
; The alias of the CONTENTdm collection.
alias = AUebooks
ws_url = "http://deck.cs.athabascau.ca/dmwebservices/index.php?q="
; 'record_key' should always be 'pointer' for CONTENTdm fetchers.
record_key = pointer
temp_directory = "/data/projects/arca/tmp"

[METADATA_PARSER]
class = mods\CdmToMods
alias = AUebooks
ws_url = "http://deck.cs.athabascau.ca/dmwebservices/index.php?q="
; Path to the csv file that contains the CONTENTdm to MODS mappings.
mapping_csv_path = '/data/projects/arca/collections/AUebooks/mapping.csv'
; Include the migrated from uri into your generated metadata (e.g., MODS)
include_migrated_from_uri = "http://digicon.athabascau.ca/cdm/ref/collection/"
repeatable_wrapper_elements[] = extension
repeatable_wrapper_elements[] = name
repeatable_wrapper_elements[] = subject
repeatable_wrapper_elements[] = identifier
repeatable_wrapper_elements[] = titleInfo
repeatable_wrapper_elements[] = title
repeatable_wrapper_elements[] = relatedItem
use_nicknames = true

[FILE_GETTER]
class = CdmPdfDocuments
alias = AUebooks
input_directories[] =
ws_url = "http://deck.cs.athabascau.ca/dmwebservices/index.php?q="
utils_url = "http://deck.cs.athabascau.ca/utils/"
temp_directory = "/data/projects/arca/tmp"

[WRITER]
class = CdmPdfDocuments
alias = AUebooks
output_directory = "/data/projects/arca/collections/AUebooks/output"
metadata_filename =
postwritehooks[] = "php extras/scripts/postwritehooks/move_packages_by_extension.php"
postwritehooks[] = "php extras/scripts/postwritehooks/validate_mods.php"
postwritehooks[] = "php extras/scripts/postwritehooks/object_timer.php"
postwritehooks[] = "php extras/scripts/shutdownhooks/delete_temp_files.php"
; Note: During testing we only generate MODS datastreams. In production, comment this line out.
; datastreams[] = MODS

[MANIPULATORS]
; filegettermanipulators[] = "CdmSingleFile|pdf"
; filegettermanipulators[] = "CdmCompound|Document-PDF"
fetchermanipulators[] = "CdmCompound|Document-PDF"
;metadatamanipulators[] = "FilterModsTopic|subject"
;metadatamanipulators[] = "AddContentdmData"
;metadatamanipulators[] = "AddUuidToMods"
;metadatamanipulators[] = "InsertXmlFromTemplate|null0|/Users/brandon/sfuvault/mik/manipulations/athabasca_manipulations/origininfo.xml"
;metadatamanipulators[] = "InsertXmlFromTemplate|null1|/Users/brandon/sfuvault/mik/manipulations/athabasca_manipulations/physicalDescription.xml"

[LOGGING]
path_to_log = "/data/projects/arca/tmp/mik.log"
path_to_manipulator_log = "/data/projects/arca/tmp/manipulator.log"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions