mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-14 13:33:08 +00:00
Replace all usages of dspace.url with either dspace.ui.url or dspace.server.url (depending on use case)
This commit is contained in:
@@ -929,7 +929,7 @@ public class ItemExportServiceImpl implements ItemExportService {
|
||||
Locale supportedLocale = I18nUtil.getEPersonLocale(eperson);
|
||||
Email email = Email.getEmail(I18nUtil.getEmailFilename(supportedLocale, "export_success"));
|
||||
email.addRecipient(eperson.getEmail());
|
||||
email.addArgument(ConfigurationManager.getProperty("dspace.url") + "/exportdownload/" + fileName);
|
||||
email.addArgument(ConfigurationManager.getProperty("dspace.ui.url") + "/exportdownload/" + fileName);
|
||||
email.addArgument(ConfigurationManager.getProperty("org.dspace.app.itemexport.life.span.hours"));
|
||||
|
||||
email.send();
|
||||
@@ -947,7 +947,7 @@ public class ItemExportServiceImpl implements ItemExportService {
|
||||
Email email = Email.getEmail(I18nUtil.getEmailFilename(supportedLocale, "export_error"));
|
||||
email.addRecipient(eperson.getEmail());
|
||||
email.addArgument(error);
|
||||
email.addArgument(ConfigurationManager.getProperty("dspace.url") + "/feedback");
|
||||
email.addArgument(ConfigurationManager.getProperty("dspace.ui.url") + "/feedback");
|
||||
|
||||
email.send();
|
||||
} catch (Exception e) {
|
||||
|
@@ -1797,7 +1797,7 @@ public class ItemImportServiceImpl implements ItemImportService, InitializingBea
|
||||
Email email = Email.getEmail(I18nUtil.getEmailFilename(supportedLocale, "bte_batch_import_error"));
|
||||
email.addRecipient(eperson.getEmail());
|
||||
email.addArgument(error);
|
||||
email.addArgument(ConfigurationManager.getProperty("dspace.url") + "/feedback");
|
||||
email.addArgument(ConfigurationManager.getProperty("dspace.ui.url") + "/feedback");
|
||||
|
||||
email.send();
|
||||
} catch (Exception e) {
|
||||
|
@@ -152,11 +152,11 @@ public class GenerateSitemaps {
|
||||
*/
|
||||
public static void generateSitemaps(boolean makeHTMLMap,
|
||||
boolean makeSitemapOrg) throws SQLException, IOException {
|
||||
String sitemapStem = configurationService.getProperty("dspace.url")
|
||||
String sitemapStem = configurationService.getProperty("dspace.ui.url")
|
||||
+ "/sitemap";
|
||||
String htmlMapStem = configurationService.getProperty("dspace.url")
|
||||
String htmlMapStem = configurationService.getProperty("dspace.ui.url")
|
||||
+ "/htmlmap";
|
||||
String handleURLStem = configurationService.getProperty("dspace.url")
|
||||
String handleURLStem = configurationService.getProperty("dspace.ui.url")
|
||||
+ "/handle/";
|
||||
|
||||
File outputDir = new File(configurationService.getProperty("sitemap.dir"));
|
||||
@@ -293,7 +293,7 @@ public class GenerateSitemaps {
|
||||
.getProperty("http.proxy.port"));
|
||||
}
|
||||
|
||||
String sitemapURL = configurationService.getProperty("dspace.url")
|
||||
String sitemapURL = configurationService.getProperty("dspace.ui.url")
|
||||
+ "/sitemap";
|
||||
|
||||
URL url = new URL(engineURL + URLEncoder.encode(sitemapURL, "UTF-8"));
|
||||
|
@@ -583,7 +583,7 @@ public class LogAnalyser {
|
||||
// now do the host name and url lookup
|
||||
hostName = ConfigurationManager.getProperty("dspace.hostname").trim();
|
||||
name = ConfigurationManager.getProperty("dspace.name").trim();
|
||||
url = ConfigurationManager.getProperty("dspace.url").trim();
|
||||
url = ConfigurationManager.getProperty("dspace.ui.url").trim();
|
||||
if ((url != null) && (!url.endsWith("/"))) {
|
||||
url = url + "/";
|
||||
}
|
||||
|
@@ -50,16 +50,16 @@ abstract public class AbstractDSpaceWebapp
|
||||
/**
|
||||
* Construct a particular kind of DSpace application.
|
||||
*
|
||||
* @param kind what kind of application is this? (XMLUI, JSPUI, etc.)
|
||||
* @param kind what kind of application is this?
|
||||
*/
|
||||
public AbstractDSpaceWebapp(String kind) {
|
||||
this.kind = kind;
|
||||
|
||||
started = new Date();
|
||||
|
||||
url = ConfigurationManager.getProperty("dspace.url");
|
||||
url = ConfigurationManager.getProperty("dspace.ui.url");
|
||||
if (null == url) {
|
||||
throw new IllegalStateException("dspace.url is undefined");
|
||||
throw new IllegalStateException("dspace.ui.url is undefined");
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -889,7 +889,7 @@ public class GoogleMetadata {
|
||||
Bitstream bitstream = findLinkableFulltext(item);
|
||||
if (bitstream != null) {
|
||||
StringBuilder path = new StringBuilder();
|
||||
path.append(ConfigurationManager.getProperty("dspace.url"));
|
||||
path.append(ConfigurationManager.getProperty("dspace.ui.url"));
|
||||
|
||||
if (item.getHandle() != null) {
|
||||
path.append("/bitstream/");
|
||||
|
@@ -89,7 +89,7 @@ public class OpenSearchServiceImpl implements OpenSearchService {
|
||||
* Get base search service URL (websvc.opensearch.svccontext)
|
||||
*/
|
||||
protected String getBaseSearchServiceURL() {
|
||||
return configurationService.getProperty("dspace.url") + "/" +
|
||||
return configurationService.getProperty("dspace.server.url") + "/" +
|
||||
configurationService.getProperty("websvc.opensearch.svccontext");
|
||||
}
|
||||
|
||||
@@ -97,7 +97,7 @@ public class OpenSearchServiceImpl implements OpenSearchService {
|
||||
* Get base search UI URL (websvc.opensearch.uicontext)
|
||||
*/
|
||||
protected String getBaseSearchUIURL() {
|
||||
return configurationService.getProperty("dspace.url") + "/" +
|
||||
return configurationService.getProperty("dspace.server.url") + "/" +
|
||||
configurationService.getProperty("websvc.opensearch.uicontext");
|
||||
}
|
||||
|
||||
|
@@ -531,7 +531,7 @@ public class SyndicationFeed {
|
||||
if (dso == null) {
|
||||
if (baseURL == null) {
|
||||
if (request == null) {
|
||||
baseURL = ConfigurationManager.getProperty("dspace.url");
|
||||
baseURL = ConfigurationManager.getProperty("dspace.ui.url");
|
||||
} else {
|
||||
baseURL = (request.isSecure()) ? "https://" : "http://";
|
||||
baseURL += ConfigurationManager.getProperty("dspace.hostname");
|
||||
|
@@ -56,7 +56,7 @@ public class Site extends DSpaceObject {
|
||||
}
|
||||
|
||||
public String getURL() {
|
||||
return ConfigurationManager.getProperty("dspace.url");
|
||||
return ConfigurationManager.getProperty("dspace.ui.url");
|
||||
}
|
||||
|
||||
private SiteService getSiteService() {
|
||||
|
@@ -92,7 +92,7 @@ public class OREDisseminationCrosswalk
|
||||
private Element disseminateItem(Context context, Item item)
|
||||
throws CrosswalkException, IOException, SQLException, AuthorizeException {
|
||||
String oaiUrl = null;
|
||||
String dsUrl = configurationService.getProperty("dspace.url");
|
||||
String dsUrl = configurationService.getProperty("dspace.ui.url");
|
||||
|
||||
String remSource = configurationService.getProperty("oai.ore.authoritative.source");
|
||||
if (remSource == null || remSource.equalsIgnoreCase("oai")) {
|
||||
|
@@ -219,7 +219,7 @@ public class PREMISCrosswalk
|
||||
// b. name of bitstream, if any
|
||||
// c. made-up name based on sequence ID and extension.
|
||||
String sid = String.valueOf(bitstream.getSequenceID());
|
||||
String baseUrl = ConfigurationManager.getProperty("dspace.url");
|
||||
String baseUrl = ConfigurationManager.getProperty("dspace.ui.url");
|
||||
String handle = null;
|
||||
// get handle of parent Item of this bitstream, if there is one:
|
||||
List<Bundle> bn = bitstream.getBundles();
|
||||
|
@@ -1400,7 +1400,7 @@ public abstract class AbstractMETSDisseminator
|
||||
}
|
||||
if (handle != null) {
|
||||
return configurationService
|
||||
.getProperty("dspace.url")
|
||||
.getProperty("dspace.ui.url")
|
||||
+ "/bitstream/"
|
||||
+ handle
|
||||
+ "/"
|
||||
@@ -1410,7 +1410,7 @@ public abstract class AbstractMETSDisseminator
|
||||
} else { //no Handle assigned, so persistent(-ish) URI for bitstream is
|
||||
// Format: {site-base-url}/retrieve/{bitstream-internal-id}
|
||||
return configurationService
|
||||
.getProperty("dspace.url")
|
||||
.getProperty("dspace.ui.url")
|
||||
+ "/retrieve/"
|
||||
+ String.valueOf(bitstream.getID());
|
||||
}
|
||||
|
@@ -497,7 +497,7 @@ public class Email {
|
||||
String to = config.getProperty("mail.admin");
|
||||
String subject = "DSpace test email";
|
||||
String server = config.getProperty("mail.server");
|
||||
String url = config.getProperty("dspace.url");
|
||||
String url = config.getProperty("dspace.ui.url");
|
||||
Email message;
|
||||
try {
|
||||
if (args.length <= 0) {
|
||||
|
@@ -465,7 +465,7 @@ public class SolrServiceImpl implements SearchService, IndexingService {
|
||||
Locale.getDefault(), "internal_error"));
|
||||
email.addRecipient(recipient);
|
||||
email.addArgument(ConfigurationManager
|
||||
.getProperty("dspace.url"));
|
||||
.getProperty("dspace.ui.url"));
|
||||
email.addArgument(new Date());
|
||||
|
||||
String stackTrace;
|
||||
|
@@ -228,7 +228,7 @@ public class AccountServiceImpl implements AccountService {
|
||||
*/
|
||||
protected void sendEmail(Context context, String email, boolean isRegister, RegistrationData rd)
|
||||
throws MessagingException, IOException, SQLException {
|
||||
String base = ConfigurationManager.getProperty("dspace.url");
|
||||
String base = ConfigurationManager.getProperty("dspace.ui.url");
|
||||
|
||||
// Note change from "key=" to "token="
|
||||
String specialLink = new StringBuffer().append(base).append(
|
||||
|
@@ -83,7 +83,7 @@ public class EPersonConsumer implements Consumer {
|
||||
adminEmail.addRecipient(notifyRecipient);
|
||||
|
||||
adminEmail.addArgument(ConfigurationManager.getProperty("dspace.name"));
|
||||
adminEmail.addArgument(ConfigurationManager.getProperty("dspace.url"));
|
||||
adminEmail.addArgument(ConfigurationManager.getProperty("dspace.ui.url"));
|
||||
adminEmail.addArgument(eperson.getFirstName() + " " + eperson.getLastName()); // Name
|
||||
adminEmail.addArgument(eperson.getEmail());
|
||||
adminEmail.addArgument(new Date());
|
||||
|
@@ -72,7 +72,7 @@ public class HandleServiceImpl implements HandleService {
|
||||
return null;
|
||||
}
|
||||
|
||||
String url = configurationService.getProperty("dspace.url")
|
||||
String url = configurationService.getProperty("dspace.ui.url")
|
||||
+ "/handle/" + handle;
|
||||
|
||||
if (log.isDebugEnabled()) {
|
||||
@@ -85,7 +85,7 @@ public class HandleServiceImpl implements HandleService {
|
||||
@Override
|
||||
public String resolveUrlToHandle(Context context, String url)
|
||||
throws SQLException {
|
||||
String dspaceUrl = configurationService.getProperty("dspace.url")
|
||||
String dspaceUrl = configurationService.getProperty("dspace.ui.url")
|
||||
+ "/handle/";
|
||||
String handleResolver = configurationService.getProperty("handle.canonical.prefix");
|
||||
|
||||
|
@@ -38,7 +38,7 @@ public class InfoCheck extends Check {
|
||||
).append("\n");
|
||||
|
||||
sb.append("Url: ").append(
|
||||
ConfigurationManager.getProperty("dspace.url")
|
||||
ConfigurationManager.getProperty("dspace.ui.url")
|
||||
).append("\n");
|
||||
sb.append("\n");
|
||||
|
||||
|
@@ -583,7 +583,7 @@ public class EZIDIdentifierProvider
|
||||
log.warn("{} #{} has no handle -- location not set.",
|
||||
contentServiceFactory.getDSpaceObjectService(dso).getTypeText(dso), dso.getID());
|
||||
} else {
|
||||
String url = configurationService.getProperty("dspace.url")
|
||||
String url = configurationService.getProperty("dspace.ui.url")
|
||||
+ "/handle/" + item.getHandle();
|
||||
log.info("Supplying location: {}", url);
|
||||
mapped.put("_target", url);
|
||||
|
@@ -473,7 +473,7 @@ public class SimpleDSORelationsConverterPlugin
|
||||
// we currently ignore those
|
||||
return null;
|
||||
}
|
||||
String dspaceURL = configurationService.getProperty("dspace.url");
|
||||
String dspaceURL = configurationService.getProperty("dspace.ui.url");
|
||||
String link = "";
|
||||
try {
|
||||
// this currently (DSpace 4.1) works with xmlui and jspui.
|
||||
|
@@ -249,7 +249,7 @@ public class Negotiator {
|
||||
// if html is requested we have to forward to the repositories webui.
|
||||
if ("html".equals(lang)) {
|
||||
urlBuilder.append(DSpaceServicesFactory.getInstance()
|
||||
.getConfigurationService().getProperty("dspace.url"));
|
||||
.getConfigurationService().getProperty("dspace.ui.url"));
|
||||
if (!handle.equals(DSpaceServicesFactory.getInstance()
|
||||
.getConfigurationService().getProperty("handle.prefix") + "/0")) {
|
||||
urlBuilder.append("/handle/");
|
||||
|
@@ -650,7 +650,7 @@ public class StatisticsDataVisits extends StatisticsData {
|
||||
}
|
||||
|
||||
|
||||
String url = ConfigurationManager.getProperty("dspace.url") + "/bitstream/" + identifier + "/";
|
||||
String url = ConfigurationManager.getProperty("dspace.ui.url") + "/bitstream/" + identifier + "/";
|
||||
|
||||
// If we can put the pretty name of the bitstream on the end of the URL
|
||||
try {
|
||||
|
@@ -1041,7 +1041,7 @@ public class BasicWorkflowServiceImpl implements BasicWorkflowService {
|
||||
|
||||
@Override
|
||||
public String getMyDSpaceLink() {
|
||||
return configurationService.getProperty("dspace.url") + "/mydspace";
|
||||
return configurationService.getProperty("dspace.ui.url") + "/mydspace";
|
||||
}
|
||||
|
||||
protected void notifyOfReject(Context context, BasicWorkflowItem workflowItem, EPerson e,
|
||||
|
@@ -161,7 +161,7 @@ public class WorkflowUtils extends Util {
|
||||
|
||||
email.addRecipient(recipient);
|
||||
email.addArgument(ConfigurationManager
|
||||
.getProperty("dspace.url"));
|
||||
.getProperty("dspace.ui.url"));
|
||||
email.addArgument(new Date());
|
||||
email.addArgument(request.getSession().getId());
|
||||
email.addArgument(logInfo);
|
||||
|
@@ -1049,7 +1049,7 @@ public class XmlWorkflowServiceImpl implements XmlWorkflowService {
|
||||
email.addArgument(coll.getName());
|
||||
email.addArgument(rejector);
|
||||
email.addArgument(reason);
|
||||
email.addArgument(ConfigurationManager.getProperty("dspace.url") + "/mydspace");
|
||||
email.addArgument(ConfigurationManager.getProperty("dspace.ui.url") + "/mydspace");
|
||||
|
||||
email.send();
|
||||
} catch (Exception ex) {
|
||||
@@ -1063,7 +1063,7 @@ public class XmlWorkflowServiceImpl implements XmlWorkflowService {
|
||||
|
||||
@Override
|
||||
public String getMyDSpaceLink() {
|
||||
return ConfigurationManager.getProperty("dspace.url") + "/mydspace";
|
||||
return ConfigurationManager.getProperty("dspace.ui.url") + "/mydspace";
|
||||
}
|
||||
|
||||
protected void revokeReviewerPolicies(Context context, Item item) throws SQLException, AuthorizeException {
|
||||
|
@@ -141,7 +141,7 @@ public class SiteTest extends AbstractUnitTest {
|
||||
*/
|
||||
@Test
|
||||
public void testGetURL() {
|
||||
assertThat("testGetURL 0", s.getURL(), equalTo(ConfigurationManager.getProperty("dspace.url")));
|
||||
assertThat("testGetURL 0", s.getURL(), equalTo(ConfigurationManager.getProperty("dspace.ui.url")));
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -449,7 +449,7 @@ public class EZIDIdentifierProviderTest
|
||||
// Evaluate
|
||||
String target = (String) metadata.get("_target");
|
||||
assertEquals("Generates correct _target metadatum",
|
||||
config.getProperty("dspace.url") + "/handle/" + handle,
|
||||
config.getProperty("dspace.ui.url") + "/handle/" + handle,
|
||||
target);
|
||||
assertTrue("Has title", metadata.containsKey("datacite.title"));
|
||||
assertTrue("Has publication year", metadata.containsKey("datacite.publicationyear"));
|
||||
|
@@ -61,7 +61,7 @@ public class DataProviderServlet extends HttpServlet {
|
||||
log.debug("lang = " + lang + ", cType = " + cType + " and pathInfo: " + pathInfo);
|
||||
if (StringUtils.isEmpty(pathInfo) || StringUtils.countMatches(pathInfo, "/") < 2) {
|
||||
String dspaceURI =
|
||||
DSpaceServicesFactory.getInstance().getConfigurationService().getProperty("dspace.url");
|
||||
DSpaceServicesFactory.getInstance().getConfigurationService().getProperty("dspace.ui.url");
|
||||
this.serveNamedGraph(dspaceURI, lang, cType, response);
|
||||
return;
|
||||
}
|
||||
|
@@ -26,7 +26,7 @@ import org.springframework.stereotype.Component;
|
||||
* This operation moves bitstreams within a bundle from one index to another.
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/bundles/<:id-bundle> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/bundles/<:id-bundle> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "move", "path": "
|
||||
* /_links/bitstreams/1/href", "from": "/_links/bitstreams/0/href"]'
|
||||
* </code>
|
||||
|
@@ -16,7 +16,7 @@ import org.springframework.stereotype.Component;
|
||||
* Implementation for EPerson requires certificate patches.
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/epersons/eperson/<:id-eperson> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/epersons/eperson/<:id-eperson> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "replace", "path": "
|
||||
* /certificate", "value": true|false]'
|
||||
* </code>
|
||||
|
@@ -16,7 +16,7 @@ import org.springframework.stereotype.Component;
|
||||
* Implementation for EPerson password patches.
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/epersons/eperson/<:id-eperson> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/epersons/eperson/<:id-eperson> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "replace", "path": "
|
||||
* /email", "value": "new@email"]'
|
||||
* </code>
|
||||
|
@@ -16,7 +16,7 @@ import org.springframework.stereotype.Component;
|
||||
* Implementation for EPerson canLogin patches.
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/epersons/eperson/<:id-eperson> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/epersons/eperson/<:id-eperson> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "replace", "path": "
|
||||
* /canLogin", "value": true|false]'
|
||||
* </code>
|
||||
|
@@ -16,7 +16,7 @@ import org.springframework.stereotype.Component;
|
||||
* Implementation for EPerson netid patches.
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/epersons/eperson/<:id-eperson> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/epersons/eperson/<:id-eperson> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "replace", "path": "
|
||||
* /netid", "value": "newNetId"]'
|
||||
* </code>
|
||||
|
@@ -15,7 +15,7 @@ import org.springframework.stereotype.Component;
|
||||
* Implementation for EPerson password patches.
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/epersons/eperson/<:id-eperson> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/epersons/eperson/<:id-eperson> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "replace", "path": "
|
||||
* /password", "value": "newpassword"]'
|
||||
* </code>
|
||||
|
@@ -17,7 +17,7 @@ import org.springframework.stereotype.Component;
|
||||
* This is the implementation for Item resource patches.
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/item/<:id-item> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/item/<:id-item> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "replace", "path": "
|
||||
* /discoverable", "value": true|false]'
|
||||
* </code>
|
||||
|
@@ -18,7 +18,7 @@ import org.springframework.stereotype.Component;
|
||||
* This is the implementation for Item resource patches.
|
||||
* <p>
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/item/<:id-item> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/item/<:id-item> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "replace", "path": "
|
||||
* /withdrawn", "value": true|false]'
|
||||
* </code>
|
||||
|
@@ -179,7 +179,7 @@ public class SubmissionService {
|
||||
checksum.setValue(source.getChecksum());
|
||||
data.setCheckSum(checksum);
|
||||
data.setSizeBytes(source.getSizeBytes());
|
||||
data.setUrl(configurationService.getProperty("dspace.url") + "/api/" + BitstreamRest.CATEGORY + "/" + English
|
||||
data.setUrl(configurationService.getProperty("dspace.server.url") + "/api/" + BitstreamRest.CATEGORY + "/" + English
|
||||
.plural(BitstreamRest.NAME) + "/" + source.getID() + "/content");
|
||||
return data;
|
||||
}
|
||||
|
@@ -28,7 +28,7 @@ import org.springframework.util.Assert;
|
||||
* "/sections/<:name-of-the-form>/<:metadata>/-"
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "add", "path": "
|
||||
* /sections/traditionalpageone/dc.title/-", "value": {"value": "Add new
|
||||
* title"}}]'
|
||||
@@ -38,7 +38,7 @@ import org.springframework.util.Assert;
|
||||
* "/sections/<:name-of-the-form>/<:metadata>/<:idx-zero-based>"
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "add", "path": "
|
||||
* /sections/traditionalpageone/dc.title/1", "value": {"value": "Add new
|
||||
* title"}}]'
|
||||
@@ -48,7 +48,7 @@ import org.springframework.util.Assert;
|
||||
* "/sections/<:name-of-the-form>/<:metadata>"
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "add", "path": "
|
||||
* /sections/traditionalpageone/dc.title", "value": [{"value": "Add new first
|
||||
* title"}, {"value": "Add new second title"}]}]'
|
||||
|
@@ -21,7 +21,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
* instance to put the 3rd author as 1st author you need to run:
|
||||
*
|
||||
* <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "move", "from": "
|
||||
* /sections/traditionalpageone/dc.contributor.author/2", "path": "
|
||||
* /sections/traditionalpageone/dc.contributor.author/0"}]'
|
||||
|
@@ -21,7 +21,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
* "/sections/<:name-of-the-form>/<:metadata>/<:idx-zero-based>"
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "remove", "path": "
|
||||
* /sections/traditionalpageone/dc.title/1"}]'
|
||||
* </code>
|
||||
@@ -30,7 +30,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
* "/sections/<:name-of-the-form>/<:metadata>"
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "remove", "path": "
|
||||
* /sections/traditionalpageone/dc.title"}]'
|
||||
* </code>
|
||||
|
@@ -28,7 +28,7 @@ import org.springframework.util.Assert;
|
||||
* must return an error.
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "replace", "path": "
|
||||
* /sections/traditionalpageone/dc.title/0", "value": {"value": "Add new
|
||||
* title", "language": "en"}}]'
|
||||
@@ -37,7 +37,7 @@ import org.springframework.util.Assert;
|
||||
* It is also possible to change only a single attribute of the {@link MetadataValueRest} (except the "place").
|
||||
*
|
||||
* Example: <code>
|
||||
* curl -X PATCH http://${dspace.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* curl -X PATCH http://${dspace.server.url}/api/submission/workspaceitems/<:id-workspaceitem> -H "
|
||||
* Content-Type: application/json" -d '[{ "op": "replace", "path": "
|
||||
* /sections/traditionalpageone/dc.title/0/language", "value": "it"}]'
|
||||
* </code>
|
||||
|
@@ -42,7 +42,7 @@ public class LicenseStep extends org.dspace.submit.step.LicenseStep implements A
|
||||
String acceptanceDate = bitstreamService.getMetadata(bitstream, DCTERMS_RIGHTSDATE);
|
||||
result.setAcceptanceDate(acceptanceDate);
|
||||
result.setUrl(
|
||||
configurationService.getProperty("dspace.url") + "/api/" + BitstreamRest.CATEGORY + "/" + English
|
||||
configurationService.getProperty("dspace.server.url") + "/api/" + BitstreamRest.CATEGORY + "/" + English
|
||||
.plural(BitstreamRest.NAME) + "/" + bitstream.getID() + "/content");
|
||||
result.setGranted(true);
|
||||
}
|
||||
|
@@ -139,8 +139,8 @@ public class RdfIT extends AbstractWebClientIntegrationTest {
|
||||
ResponseEntity<String> response = getResponseAsString(REDIRECTION_PATH + "/" + communityHandle);
|
||||
// Expect a 303 (See Other) response code, redirecting us to the HTTP URI of the Community
|
||||
assertThat(response.getStatusCode(), equalTo(HttpStatus.SEE_OTHER));
|
||||
// Expect location of redirection to be [dspace.url]/handle/[community_handle]
|
||||
// Expect location of redirection to be [dspace.ui.url]/handle/[community_handle]
|
||||
assertThat(response.getHeaders().getLocation(), equalTo(
|
||||
URI.create(configurationService.getProperty("dspace.url") + "/handle/" + communityHandle + "/")));
|
||||
URI.create(configurationService.getProperty("dspace.ui.url") + "/handle/" + communityHandle + "/")));
|
||||
}
|
||||
}
|
||||
|
@@ -106,7 +106,7 @@ public class BitstreamEntryGenerator extends DSpaceATOMEntry {
|
||||
if (this.deposit != null && this.deposit.isNoOp()) {
|
||||
// just use the dspace url as the
|
||||
// property
|
||||
String cfg = ConfigurationManager.getProperty("dspace.url");
|
||||
String cfg = ConfigurationManager.getProperty("dspace.ui.url");
|
||||
entry.setId(cfg);
|
||||
|
||||
return;
|
||||
|
@@ -162,7 +162,7 @@ public class ItemEntryGenerator extends DSpaceATOMEntry {
|
||||
|
||||
// if we get this far, then we just use the dspace url as the
|
||||
// property
|
||||
String cfg = ConfigurationManager.getProperty("dspace.url");
|
||||
String cfg = ConfigurationManager.getProperty("dspace.ui.url");
|
||||
entry.setId(cfg);
|
||||
|
||||
// FIXME: later on we will maybe have a workflow page supplied
|
||||
@@ -246,7 +246,7 @@ public class ItemEntryGenerator extends DSpaceATOMEntry {
|
||||
return;
|
||||
}
|
||||
|
||||
String base = ConfigurationManager.getProperty("dspace.url");
|
||||
String base = ConfigurationManager.getProperty("dspace.ui.url");
|
||||
|
||||
// if there's no base URL, we are stuck
|
||||
if (base == null) {
|
||||
|
@@ -421,7 +421,7 @@ public class SWORDUrlManager {
|
||||
}
|
||||
|
||||
String handle = item.getHandle();
|
||||
String bsLink = ConfigurationManager.getProperty("dspace.url");
|
||||
String bsLink = ConfigurationManager.getProperty("dspace.ui.url");
|
||||
|
||||
if (handle != null && !"".equals(handle)) {
|
||||
bsLink = bsLink + "/bitstream/" + handle + "/" +
|
||||
|
@@ -407,7 +407,7 @@ public class SwordUrlManager {
|
||||
}
|
||||
|
||||
String handle = item.getHandle();
|
||||
String bsLink = ConfigurationManager.getProperty("dspace.url");
|
||||
String bsLink = ConfigurationManager.getProperty("dspace.ui.url");
|
||||
|
||||
if (handle != null && !"".equals(handle)) {
|
||||
bsLink = bsLink + "/bitstream/" + handle + "/" +
|
||||
|
@@ -26,14 +26,11 @@ dspace.dir = /dspace
|
||||
dspace.hostname = localhost
|
||||
|
||||
# DSpace server backend webapp URL. Include port number etc.
|
||||
dspace.baseUrl = http://localhost:8080/server
|
||||
dspace.server.url = http://localhost:8080/server
|
||||
#dspace.baseUrl = http://localhost:8080/server
|
||||
|
||||
# Full link your end users will use to access DSpace. This is the URL of your angular UI
|
||||
dspace.url = http://localhost:3000
|
||||
|
||||
# Optional: DSpace URL for mobile access
|
||||
# This
|
||||
#dspace.mobileUrl = http://mobile.example.com
|
||||
dspace.ui.url = http://localhost:3000
|
||||
|
||||
# Name of the site
|
||||
dspace.name = DSpace at My University
|
||||
@@ -234,7 +231,7 @@ identifier.doi.namespaceseparator = dspace/
|
||||
#
|
||||
# Items in DSpace receive a unique URL, stored in dc.identifier.uri
|
||||
# after it is generated during the submission process.
|
||||
handle.canonical.prefix = ${dspace.url}/handle/
|
||||
handle.canonical.prefix = ${dspace.ui.url}/handle/
|
||||
|
||||
# If you register with CNRI's handle service at http://www.handle.net/,
|
||||
# these links can be generated as permalinks using http://hdl.handle.net/
|
||||
@@ -1349,7 +1346,7 @@ webui.feed.item.author = dc.contributor.author
|
||||
|
||||
# Customize the image icon included with the site-wide feeds:
|
||||
# Must be an absolute URL, e.g.
|
||||
## webui.feed.logo.url = ${dspace.url}/themes/mysite/images/mysite-logo.png
|
||||
## webui.feed.logo.url = ${dspace.ui.url}/themes/mysite/images/mysite-logo.png
|
||||
|
||||
# iTunes Podcast Enhanced RSS Feed Properties
|
||||
# Add all the communities / collections, separated by commas (no spaces) that should
|
||||
|
@@ -29,7 +29,7 @@ oai.solr.url=${solr.server}/oai
|
||||
# Format - oai:PREFIX:HANDLE
|
||||
oai.identifier.prefix = ${dspace.hostname}
|
||||
# Base url for bitstreams
|
||||
oai.bitstream.baseUrl = ${dspace.url}
|
||||
oai.bitstream.baseUrl = ${dspace.ui.url}
|
||||
|
||||
# Base Configuration Directory
|
||||
oai.config.dir = ${dspace.dir}/config/crosswalks/oai
|
||||
|
@@ -849,9 +849,9 @@ Common usage:
|
||||
|
||||
${dspace.dir}/bin/dspace create-administrator
|
||||
|
||||
You should then be able to access your DSpace's 'home page':
|
||||
You should then be able to access your DSpace's REST API:
|
||||
|
||||
${dspace.url}
|
||||
${dspace.server.url}
|
||||
|
||||
====================================================================
|
||||
</echo>
|
||||
|
Reference in New Issue
Block a user