Commit Graph

6761 Commits

Author SHA1 Message Date
Marsa Haoua
69233ef4ba Fix delete from DOIOrganiser 2013-10-16 09:27:20 +02:00
Marsa Haoua
7d68f9936a Add delete option. Delete DOI on command line 2013-10-16 09:27:20 +02:00
Marsa Haoua
0251a02190 Add update status values for DOI table 2013-10-16 09:27:20 +02:00
Pascal-Nicolas Becker
a081da4333 Bug fixing DOIIdentifierProvider.
If an Item had more then one DOI delete(Context, DSpaceObject) didn't
delete all of them.
If supports(null) or supports("") was called a IllegalArgumentException
was thrown. No it returns false as expected.
2013-10-16 09:21:28 +02:00
Marsa Haoua
cd2f2feffa Added license header to DOIIdentifierException. 2013-10-16 09:21:28 +02:00
Pascal-Nicolas Becker
35ba75cb50 Set default values for missing mandatory fields in DIM2DataCite crosswalk. 2013-10-16 09:21:28 +02:00
Marsa Haoua
6faaf76bf3 New command line option to turn the command line output off 2013-10-16 09:21:28 +02:00
Pascal-Nicolas Becker
72dde37ace DOIOrganiser uses --help as default. Changed launcher.xml
DOIOrganiser prints help, if no options were used.
DOIOrganiser can be called by [dspace-install]/bin/dspace doi-organiser
now.
2013-10-16 09:21:28 +02:00
Pascal-Nicolas Becker
cc396c7269 Code review of DataCiteConnector.
* Coding Conventions
 * use of reserveDOI for updateMetadata instead of code duplication
 * some less important simplifications
2013-10-16 09:21:28 +02:00
Pascal-Nicolas Becker
407627e9d2 Check if a DOI is reserved before it get registered. 2013-10-16 09:21:28 +02:00
Pascal-Nicolas Becker
f036847a0b Changed DOI status from int to Integer.
DatabaseManager.queryTable(Context, String, String, Object[]) uses the
toString() method. So we use Integer instead of ints for the status of a
DOI.
2013-10-16 09:21:28 +02:00
Marsa Haoua
8590258bb7 Some Exception Handling and change value from DOI status from DOI table 2013-10-16 09:21:28 +02:00
Pascal-Nicolas Becker
075ec63470 DataCiteConnector: remove cache.
We introduced the cache to get better performance while reserving and
registering DOIs. To be able to process new submissions independently
from the status of the registration agency API we introduced a cron job
that registers and reserves doi. It is not important if the cronjob is
some seconds faster or not. The cache brought some new problems and
makes the code more complicated. As it is not needed any more I removed
it.
2013-10-16 09:21:28 +02:00
Pascal-Nicolas Becker
e10fac21f0 Continued refactoring of DOIOrganiser. 2013-10-16 09:21:28 +02:00
Pascal-Nicolas Becker
3dd5e6df5f Fix typo in method name. 2013-10-16 09:21:28 +02:00
Pascal-Nicolas Becker
dc4e53b10e Added method to DOIOrganiser to send alert mails. 2013-10-16 09:21:27 +02:00
Pascal-Nicolas Becker
bd92496a7d Started Refactoring of DOIOrganiser. Code cleanup. 2013-10-16 09:21:27 +02:00
Marsa Haoua
13f35891d4 Little Convention Code 2013-10-16 09:21:27 +02:00
Marsa Haoua
7fa57d84ca Perform some conventions code and fixed little bugs 2013-10-16 09:21:27 +02:00
Pascal-Nicolas Becker
404bc1c6bf Simpliefied code of DOIIdentifierProvider. Enhanced Exception handling. 2013-10-16 09:21:27 +02:00
Pascal-Nicolas Becker
66c99dfae0 Use DOIIdentifierException in org.dspace.identifier.DOI. 2013-10-16 09:21:27 +02:00
Pascal-Nicolas Becker
9b3e23efb0 Do not return booleans on several DOI actions.
Booleans returned on reserving, registering, updating metadata and
deleting of a doi where used to signal a problem with metadata
convertion. This should be done with the enhanced Exception handling.
2013-10-16 09:21:27 +02:00
Pascal-Nicolas Becker
fdf19de9a0 Add some more error codes and a method to get the error code. 2013-10-16 09:21:27 +02:00
Pascal-Nicolas Becker
6b611a721a Started to enhance exception handling. 2013-10-16 09:21:27 +02:00
Pascal-Nicolas Becker
37fe97c6cb Created DOIIdentifierException to enhance exception handling. 2013-10-16 09:21:27 +02:00
Pascal-Nicolas Becker
f249644495 Moved DOIIdentifierProvier.formatIdentifier to DOI.formatIdentifier. 2013-10-16 09:21:27 +02:00
Marsa Haoua
edc4ceaa28 Update metadata for a given DOI Identifier or an Item or a Handle 2013-10-16 09:21:27 +02:00
Marsa Haoua
66be510a64 We build a cron Job for Doi identifier reservation and registration. 2013-10-16 09:21:27 +02:00
Pascal-Nicolas Becker
d44320305c Code cleanup. 2013-10-16 09:21:27 +02:00
Pascal-Nicolas Becker
ba906ddaba Little change on some comments and a log message. 2013-10-16 09:21:27 +02:00
johlton
4bc7b2e58c Reviewed comments and messages. Corrected typos and grammar. 2013-10-16 09:21:27 +02:00
Pascal-Nicolas Becker
f27fe22f62 Remove stub EZIDConnector and old test class. 2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
08416a3009 Repaird method to delete DOIs. 2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
e9516b4f3a Some more clean up. 2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
86af008796 Changed ExceptionHandling in DOIIdentifierProvider.
DOIIdentifierProvider and DataCiteConnector will throw more
IdentifierExceptions and less other Exceptions, like RuntimeException,
IllegalArgumentException or IllegalStateExceptions.
IdentifierServiceImpl catches IdentifierException but not the other
ones. If IdentifierServicesImpl catches an IdentiferException it may go
on with the next IdentifierProvider and not the complete user action
will stop.
2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
8adbec5538 Added method to register DOIs. Added Debug information. 2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
a367c9ca6a Removes stub method to purge cache out ouf EZIDConnector. 2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
b3e6caffc8 Changed handling of cache in DataCiteConnector.
The cache don't need to be purged manually. It will be purged
automatically after some time. The cache holding time can be configured
the default is set to 120 sec.
2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
b57baab397 Added a method to delete metadata of a DOI. 2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
0b3ad8456f Added method to reserve a DOI. 2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
188a018653 DOIIdentifierProvider loads prefix out of dspace.cfg. 2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
63a5ae626b DataCiteConnector.sendMetadataPostRequest(...) implemented. 2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
8a006faf4a Added method to check if a DOI is reserved. 2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
9ef0319c19 Adds method to send http delete to DataCite.
Cleanedup code to eleminate code duplication: Added a method to send
HTTP requests and to parse the response into a DataCiteResponse object.
The request speficie methods creates the request and uses the new
message to send them to Datacite.
2013-10-16 09:21:26 +02:00
Pascal-Nicolas Becker
b8752e0ddc Implements methods to connect to DataCite.
Refactored the method to send get requests to DataCite so it can be used
for the metadata and the doi api.
Implemented a method to send a post request to the doi api.
2013-10-16 09:21:25 +02:00
Pascal-Nicolas Becker
04863a996e Cleanup DOI extension. 2013-10-16 09:21:25 +02:00
Pascal-Nicolas Becker
40af20407b Repair broken merge.
Forgot to merge the dependency to org.apache.httpcomponents.
2013-10-16 09:21:25 +02:00
Pascal-Nicolas Becker
3f87ed2535 Restructured DOI extension.
Renamed DOIDataCiteIdentifierProvider into DOIIdentifierProvider.
Added interface org.dspace.identifier.doi.DOIConnector to be able to
support different registration agencies.
Moved spring configuration into
dspace/config/spring/api/identifier-service.xml.
Began development of org.dspace.identifier.doi.DataCiteConnector.
2013-10-16 09:21:25 +02:00
Pascal-Nicolas Becker
8695a69228 Adds method resolveUrltoHandle to HandleManager.
Simple method to get the handle to a url constructed by the
HandleManager before.
2013-10-16 09:21:25 +02:00
Pascal-Nicolas Becker
b97a80804f Continued implementation of DOIDataCiteIdentifierProvider.
Implemented isDOIRegistered(...).
Change the API a littlebit as some protected methods needs more
arguments like a DSpace Context.
2013-10-16 09:21:25 +02:00