Skip to content

Commit

Permalink
add example-csv for 1.6
Browse files Browse the repository at this point in the history
  • Loading branch information
fereira committed Jun 15, 2015
1 parent 550f6ca commit 0c6b240
Show file tree
Hide file tree
Showing 36 changed files with 5,346 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

You need to modify certains files to ingest data using this example.

Here are the files that need to be modified:

1. vivo.model.xml

check that the database information is configured correctly for your system. By default, it will
connect to a database called vitrodb_test on localhost

2. run-csv.sh

set to the directory where the harvester was installed
HARVESTER_INSTALL_DIR
(Note: there may be other shell scripts which have a set HARVESTER_INSTALL_DIR which
will need to modified)

3. csvtojdbc.config.xml

change inputFile name to your csv data source

5. all the changenamespace-*.config.xml files

change the "newNamespace" value to the namespace of your VIVO instance

Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2010-2011 VIVO Harvester Team. For full list of contributors, please see the AUTHORS file provided.
All rights reserved.
This program and the accompanying materials are made available under the terms of the new BSD license which accompanies this distribution, and is available at http://www.opensource.org/licenses/bsd-license.html
-->
<!--
<% Changenamespace is a tool to change the uri of the incoming data to a generated uri of the associated vivo. %>
<% ===== %>
<% The generated uri will be in the base name space of the vivo with a unique identifying number. This tool is %>
<% the way new resources are prepared to be added to a vivo. The actual adding of resources happens with the use %>
<% of the transfer tool. %>
-->
<Task>
<!--INPUT : for more information please see the given config file -->
<!--
<% <Param name="inputModel">The input model is the jena model which stores the recently harvested information %>
<% which will be altered by the changenamespace tool. %>
-->
<Param name="inputModel">harvested-data.model.xml</Param>

<!--VIVO : for more information please see the given config file -->
<!--
<% <Param name="vivoModel"> The vivo model points to the model within vivo which is used as a reference to ensure %>
<% the new uri doesn't exist already and cause an issue if imported to that vivo instance. %>
-->
<Param name="vivoModel">vivo.model.xml</Param>

<!-- OPTIONS -->
<!--
<% <Param name="oldNamespace"> This refers to the namespace being switched from. It operates as a filter on the %>
<% harvested data in order to be sure that only the chosen namspace is being altered %>
<% <Param name="newNamespace"> The namespace put here should agree with the namespace of the vivo being harvested %>
<% into. %>
-->

<Param name="oldNamespace">http://vivoweb.org/harvest/csvfile/org/</Param>
<Param name="newNamespace">http://vivo.sample.edu/individual/</Param>
<!--
<% <Param name="errorLogging"> This parameter determines if a change in namespace will produce an error message. If %>
<% a change in the namespace should not be happening then this flag should be enabled. %>
<% %>
-->
<!-- <Param name="errorLogging">true</Param> -->
<Param name="wordiness">INFO</Param>
</Task>
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2010-2011 VIVO Harvester Team. For full list of contributors, please see the AUTHORS file provided.
All rights reserved.
This program and the accompanying materials are made available under the terms of the new BSD license which accompanies this distribution, and is available at http://www.opensource.org/licenses/bsd-license.html
-->
<!--
<% Changenamespace is a tool to change the uri of the incoming data to a generated uri of the associated vivo. %>
<% ===== %>
<% The generated uri will be in the base name space of the vivo with a unique identifying number. This tool is %>
<% the way new resources are prepared to be added to a vivo. The actual adding of resources happens with the use %>
<% of the transfer tool. %>
-->
<Task>
<!--INPUT : for more information please see the given config file -->
<!--
<% <Param name="inputModel">The input model is the jena model which stores the recently harvested information %>
<% which will be altered by the changenamespace tool. %>
-->
<Param name="inputModel">harvested-data.model.xml</Param>


<!--VIVO : for more information please see the given config file -->
<!--
<% <Param name="vivoModel"> The vivo model points to the model within vivo which is used as a reference to ensure %>
<% the new uri doesn't exist already and cause an issue if imported to that vivo instance. %>
-->
<Param name="vivoModel">vivo.model.xml</Param>

<!-- OPTIONS -->
<!--
<% <Param name="oldNamespace"> This refers to the namespace being switched from. It operates as a filter on the %>
<% harvested data in order to be sure that only the chosen namspace is being altered %>
<% <Param name="newNamespace"> The namespace put here should agree with the namespace of the vivo being harvested %>
<% into. %>
-->
<Param name="oldNamespace">http://vivoweb.org/harvest/csvfile/person/</Param>
<Param name="newNamespace">http://vivo.sample.edu/individual/</Param>
<!--
<% <Param name="errorLogging"> This parameter determines if a change in namespace will produce an error message. If %>
<% a change in the namespace should not be happening then this flag should be enabled. %>
<% %>
-->
<!-- <Param name="errorLogging">true</Param> -->
<Param name="wordiness">INFO</Param>
</Task>
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2010-2011 VIVO Harvester Team. For full list of contributors, please see the AUTHORS file provided.
All rights reserved.
This program and the accompanying materials are made available under the terms of the new BSD license which accompanies this distribution, and is available at http://www.opensource.org/licenses/bsd-license.html
-->
<!--
<% Changenamespace is a tool to change the uri of the incoming data to a generated uri of the associated vivo. %>
<% ===== %>
<% The generated uri will be in the base name space of the vivo with a unique identifying number. This tool is %>
<% the way new resources are prepared to be added to a vivo. The actual adding of resources happens with the use %>
<% of the transfer tool. %>
-->
<Task>
<!--INPUT : for more information please see the given config file -->
<!--
<% <Param name="inputModel">The input model is the jena model which stores the recently harvested information %>
<% which will be altered by the changenamespace tool. %>
-->
<Param name="inputModel">harvested-data.model.xml</Param>

<!--VIVO : for more information please see the given config file -->
<!--
<% <Param name="vivoModel"> The vivo model points to the model within vivo which is used as a reference to ensure %>
<% the new uri doesn't exist already and cause an issue if imported to that vivo instance. %>
-->
<Param name="vivoModel">vivo.model.xml</Param>

<!-- OPTIONS -->
<!--
<% <Param name="oldNamespace"> This refers to the namespace being switched from. It operates as a filter on the %>
<% harvested data in order to be sure that only the chosen namspace is being altered %>
<% <Param name="newNamespace"> The namespace put here should agree with the namespace of the vivo being harvested %>
<% into. %>
-->
<Param name="oldNamespace">http://vivoweb.org/harvest/csvfile/position/</Param>
<Param name="newNamespace">http://vivo.sample.edu/individual/</Param>
<!--
<% <Param name="errorLogging"> This parameter determines if a change in namespace will produce an error message. If %>
<% a change in the namespace should not be happening then this flag should be enabled. %>
<% %>
-->
<!-- <Param name="errorLogging">true</Param> -->
<Param name="wordiness">INFO</Param>
</Task>
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2010-2011 VIVO Harvester Team. For full list of contributors, please see the AUTHORS file provided.
All rights reserved.
This program and the accompanying materials are made available under the terms of the new BSD license which accompanies this distribution, and is available at http://www.opensource.org/licenses/bsd-license.html
-->

<Config>
<Param name="wordiness">INFO</Param>
<Param name="inputModel">harvested-data.model.xml</Param>
<Param name="vivoModel">vivo.model.xml</Param>
<Param name="oldNamespace">http://vivoweb.org/harvest/csvfile/timeInterval/</Param>
<Param name="newNamespace">http://vivo.sample.edu/individual/</Param>
<Param name="errorLogging">true</Param>
</Config>
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2010-2011 VIVO Harvester Team. For full list of contributors, please see the AUTHORS file provided.
All rights reserved.
This program and the accompanying materials are made available under the terms of the new BSD license which accompanies this distribution, and is available at http://www.opensource.org/licenses/bsd-license.html
-->
<!--
<% Changenamespace is a tool to change the uri of the incoming data to a generated uri of the associated vivo. %>
<% ===== %>
<% The generated uri will be in the base name space of the vivo with a unique identifying number. This tool is %>
<% the way new resources are prepared to be added to a vivo. The actual adding of resources happens with the use %>
<% of the transfer tool. %>
-->
<Task>
<!--INPUT : for more information please see the given config file -->
<!--
<% <Param name="inputModel">The input model is the jena model which stores the recently harvested information %>
<% which will be altered by the changenamespace tool. %>
-->
<Param name="inputModel">harvested-data.model.xml</Param>


<!--VIVO : for more information please see the given config file -->
<!--
<% <Param name="vivoModel"> The vivo model points to the model within vivo which is used as a reference to ensure %>
<% the new uri doesn't exist already and cause an issue if imported to that vivo instance. %>
-->
<Param name="vivoModel">vivo.model.xml</Param>

<!-- OPTIONS -->
<!--
<% <Param name="oldNamespace"> This refers to the namespace being switched from. It operates as a filter on the %>
<% harvested data in order to be sure that only the chosen namspace is being altered %>
<% <Param name="newNamespace"> The namespace put here should agree with the namespace of the vivo being harvested %>
<% into. %>
-->
<Param name="oldNamespace">http://vivoweb.org/harvest/csvfile/vcard/</Param>
<Param name="newNamespace">http://vivo.sample.edu/individual/</Param>
<!--
<% <Param name="errorLogging"> This parameter determines if a change in namespace will produce an error message. If %>
<% a change in the namespace should not be happening then this flag should be enabled. %>
<% %>
-->
<!-- <Param name="errorLogging">true</Param> -->
<Param name="wordiness">INFO</Param>
</Task>
Loading

0 comments on commit 0c6b240

Please sign in to comment.