Error while uploading batch import java.lang.IndexOutOfBoundsException: Index: 0, Size: 0

30 views
Skip to first unread message

Ranjit Chavan

unread,
May 22, 2019, 5:24:22 AM5/22/19
to DSpace Community
Hi
my dspce version is 6.0 but i am uploading batch import by following command 
i am getting error  
root@ubcourt:/dspace# bin/dspace import --add --eperson=dspace@localhost --collection=fc51b762-8a25-407e-bd9e-a1db4f3aca71 --source=/home/ubuntu/Desktop/orders/bulksample.zip --mapfile=/home/Desktop/mapdir/mapfile

my Error is like this please give me some solution.

Destination collections:
Started: 1556631079769
Ended: 1556631081964
Elapsed time: 2 secs (2195 msecs)
Exception: Index: 0, Size: 0
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
at java.util.ArrayList.rangeCheck(ArrayList.java:657)
at java.util.ArrayList.set(ArrayList.java:448)
at org.dspace.app.itemimport.ItemImportCLITool.main(ItemImportCLITool.java:344)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.dspace.app.launcher.ScriptLauncher.runOneCommand(ScriptLauncher.java:229)
at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:81)

Vinit Kumar

unread,
May 22, 2019, 8:10:56 AM5/22/19
to Ranjit Chavan, DSpace Community
Maybe DSpace logs will be a better source for troubleshooting. Send your DSpace log file.


--
All messages to this mailing list should adhere to the DuraSpace Code of Conduct: https://duraspace.org/about/policies/code-of-conduct/
---
You received this message because you are subscribed to the Google Groups "DSpace Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dspace-communi...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dspace-community/3d4a5f45-1338-450f-ad45-dd9887ee1332%40googlegroups.com.


--
Regards
Vinit Kumar, Ph.D. 
Assistant Professor,
Department of Library and Information Science
Babasaheb Bhimrao Ambedkar University, 
Rae Bareilly Road, Lucknow 226025

Claudia Jürgen

unread,
May 22, 2019, 8:18:48 AM5/22/19
to dspace-c...@googlegroups.com
Hello,

never worked with zip imports but the command to import zip is different from the one to import from a directory see
https://wiki.duraspace.org/display/DSDOC6x/Importing+and+Exporting+Items+via+Simple+Archive+Format#ImportingandExportingItemsviaSimpleArchiveFormat-AddingItemstoaCollectionfromazipfile
Example
[dspace]/bin/dspace import --add --eperson=joe@user.com --collection=CollectionID --source=items_dir --zip=filename.zip --mapfile=mapfile
Source directory is where your zip file resides

You got
--source=/home/ubuntu/Desktop/orders/bulksample.zip
and no --zip option

Should be something like
--source=/home/ubuntu/Desktop/orders
--zip =bulksample.zip

Hope this helps

Claudia Jürgen


-- 
Claudia Juergen
Eldorado

Technische Universität Dortmund
Universitätsbibliothek
Vogelpothsweg 76
44227 Dortmund

Tel.: +49 231-755 40 43
Fax: +49 231-755 40 32
claudia...@tu-dortmund.de
www.ub.tu-dortmund.de

Wichtiger Hinweis: Die Information in dieser E-Mail ist vertraulich. Sie ist ausschließlich für den Adressaten bestimmt. Sollten Sie nicht der für diese E-Mail bestimmte Adressat sein, unterrichten Sie bitte den Absender und vernichten Sie diese Mail. Vielen Dank.
Unbeschadet der Korrespondenz per E-Mail, sind unsere Erklärungen ausschließlich final rechtsverbindlich, wenn sie in herkömmlicher Schriftform (mit eigenhändiger Unterschrift) oder durch Übermittlung eines solchen Schriftstücks per Telefax erfolgen.

Important note: The information included in this e-mail is confidential. It is solely intended for the recipient. If you are not the intended recipient of this e-mail please contact the sender and delete this message. Thank you. Without prejudice of e-mail correspondence, our statements are only legally binding when they are made in the conventional written form (with personal signature) or when such documents are sent by fax.

Ranjit Chavan

unread,
May 24, 2019, 2:45:09 AM5/24/19
to DSpace Community
Hello i tried 
bin/dspace import --add --eperson=dspace@localhost --collection=fc51b762-8a25-407e-bd9e-a1db4f3aca71 --source=/home/ubuntu/Desktop/orders --zip bulksample.zip --mapfile=mapfile

but showing same error 

Destination collections:
Started: 1558678431419
Ended: 1558678434275
Elapsed time: 2 secs (2856 msecs)
Exception: Index: 0, Size: 0
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
at java.util.ArrayList.rangeCheck(ArrayList.java:657)
at java.util.ArrayList.set(ArrayList.java:448)
at org.dspace.app.itemimport.ItemImportCLITool.main(ItemImportCLITool.java:344)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.dspace.app.launcher.ScriptLauncher.runOneCommand(ScriptLauncher.java:229)
at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:81)

Screenshot.png



i have check log file also showing like this

2019-05-24 11:42:24,986 INFO  org.hibernate.tool.hbm2ddl.TableMetadata @ HHH000261: Table found: public.versionhistory
2019-05-24 11:42:24,987 INFO  org.hibernate.tool.hbm2ddl.TableMetadata @ HHH000037: Columns: [versionhistory_id]
2019-05-24 11:42:24,991 INFO  org.hibernate.tool.hbm2ddl.TableMetadata @ HHH000261: Table found: public.versionitem
2019-05-24 11:42:24,991 INFO  org.hibernate.tool.hbm2ddl.TableMetadata @ HHH000037: Columns: [version_summary, eperson_id, item_id, version_date, version_number, versionitem_id, versionhistory_id]
2019-05-24 11:42:24,996 INFO  org.hibernate.tool.hbm2ddl.TableMetadata @ HHH000261: Table found: public.webapp
2019-05-24 11:42:24,996 INFO  org.hibernate.tool.hbm2ddl.TableMetadata @ HHH000037: Columns: [webapp_id, appname, started, url, isui]
2019-05-24 11:42:25,001 INFO  org.hibernate.tool.hbm2ddl.TableMetadata @ HHH000261: Table found: public.workflowitem
2019-05-24 11:42:25,001 INFO  org.hibernate.tool.hbm2ddl.TableMetadata @ HHH000037: Columns: [collection_id, owner, workflow_id, published_before, item_id, multiple_titles, multiple_files, state]
2019-05-24 11:42:25,005 INFO  org.hibernate.tool.hbm2ddl.TableMetadata @ HHH000261: Table found: public.workspaceitem
2019-05-24 11:42:25,006 INFO  org.hibernate.tool.hbm2ddl.TableMetadata @ HHH000037: Columns: [collection_id, stage_reached, page_reached, published_before, item_id, multiple_titles, multiple_files, workspace_item_id]
Reply all
Reply to author
Forward
0 new messages