From ffc968b1ca373c8710acfc96b69b572118c37e06 Mon Sep 17 00:00:00 2001 From: Holly Mistlebauer Date: Wed, 11 Sep 2013 11:36:06 -0400 Subject: [PATCH 1/4] Holly updated 3 test cases. --- .../suites/AdminSecurity/NewAdminCheckPrivileges.html | 6 +++--- .../suites/AdminSecurity/NewAdminDelete.html | 2 +- .../suites/AdminSecurity/NewAdminFirstLogin.html | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/utilities/acceptance-tests/suites/AdminSecurity/NewAdminCheckPrivileges.html b/utilities/acceptance-tests/suites/AdminSecurity/NewAdminCheckPrivileges.html index cb095ca4..355c44ad 100644 --- a/utilities/acceptance-tests/suites/AdminSecurity/NewAdminCheckPrivileges.html +++ b/utilities/acceptance-tests/suites/AdminSecurity/NewAdminCheckPrivileges.html @@ -128,7 +128,7 @@ verifyElementPresent - link=Restrict Logins + link=Restrict logins @@ -329,7 +329,7 @@ verifyTextPresent - Page Management + Page management @@ -504,7 +504,7 @@ verifyTextPresent - Email Address + Email address diff --git a/utilities/acceptance-tests/suites/AdminSecurity/NewAdminDelete.html b/utilities/acceptance-tests/suites/AdminSecurity/NewAdminDelete.html index 89ceda9a..ea6beae1 100644 --- a/utilities/acceptance-tests/suites/AdminSecurity/NewAdminDelete.html +++ b/utilities/acceptance-tests/suites/AdminSecurity/NewAdminDelete.html @@ -124,7 +124,7 @@ verifyTextPresent - Deleted 1 accounts. + Deleted 1 account. diff --git a/utilities/acceptance-tests/suites/AdminSecurity/NewAdminFirstLogin.html b/utilities/acceptance-tests/suites/AdminSecurity/NewAdminFirstLogin.html index 0543f143..8b0c615a 100644 --- a/utilities/acceptance-tests/suites/AdminSecurity/NewAdminFirstLogin.html +++ b/utilities/acceptance-tests/suites/AdminSecurity/NewAdminFirstLogin.html @@ -223,7 +223,7 @@ verifyTextPresent - Please enter a password between 6 and 12 characters in length. + Password must be between 6 and 12 characters. From 331869b52646a7ba4e620086f432549ca00f6247 Mon Sep 17 00:00:00 2001 From: j2blake Date: Thu, 12 Sep 2013 16:46:50 -0400 Subject: [PATCH 2/4] VIVO-281 Make extended linked data a configurable option. --- doc/upgrade-1.6.html | 78 ++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 72 insertions(+), 6 deletions(-) diff --git a/doc/upgrade-1.6.html b/doc/upgrade-1.6.html index 1e25bdfe..b6ef4ecd 100644 --- a/doc/upgrade-1.6.html +++ b/doc/upgrade-1.6.html @@ -50,6 +50,7 @@
  • Home Page Re-design
  • Auto-loaded RDF files move to the Home directory
  • Support for additional languages
  • +
  • More compact responses to Linked data requests
  • ANYTHING ELSE?
  • @@ -335,8 +336,9 @@ rdf/tbox/filegraph/tbox/vivo-foaf-1.5.owl rdf/tbox/filegraph/tbox/vivo-pws-1.5.owl rdf/tbox/filegraph/tbox/vivo-skos-1.5.owl

    - If you are using a three-tier build process, you will need to add a single line - to the build script so the RDF files will be merged properly across the tiers. So this: + If you are using a three-tier build process, you will need to add two lines + to the build script to accomodate the RDF files, and the language support (see below) + So this:

    <patternset id="appbase.patterns">
     <include name="src/**/*" />
     <include name="lib/**/*" />
    @@ -353,6 +355,7 @@ rdf/tbox/filegraph/tbox/vivo-skos-1.5.owl
    <include name="src/**/*" /> <include name="lib/**/*" /> <include name="rdf/**/*" /> +<include name="languages/**/*" /> <include name="test/**/*" /> <include name="themes/**/*" /> <include name="config/*.properties" /> @@ -387,6 +390,47 @@ rdf/tbox/filegraph/tbox/vivo-skos-1.5.owl Add a new language to VIVO.

    +

    More compact responses to Linked data requests

    +

    + In VIVO 1.6, the response to requests for linked data is changed, to be smaller and faster. +

    +

    + When responding to a request for linked data about an individual, VIVO 1.6 returns: +

    + This data is filtered by the usual VIVO privacy policies, + so properties such as salary or employee ID number may not be revealed + unless the requester has been properly authenticated. +

    +

    + VIVO releases prior to VIVO 1.6 returned a more complex set of statements, + referred to as "extended linked data": +

    + As above, this data was filtered by the VIVO privacy policies. + Although these additional items were included, + extended linked data was based only on relationships from the individual. + Relationships to the individual were not included. +

    +

    + Extended linked data was costly to produce, in terms of resources, + because it required a recursive search of the data model. + Extended linked data typically contained 50% more information than its non-extended equivalent, + and took more than 10 times as long to produce. +

    +

    + VIVO release 1.6 can be configured to produce extended linked data like previous releases. + However, extended linked data will not be supported in future releases. +

    +

    ANYTHING ELSE?

    @@ -614,7 +658,7 @@ rdf/tbox/filegraph/tbox/vivo-skos-1.5.owl - developer.defeatI18nCache = true + developer.defeatI18nCache false @@ -632,7 +676,7 @@ rdf/tbox/filegraph/tbox/vivo-skos-1.5.owl - developer.insertFreemarkerDelimiters = true + developer.insertFreemarkerDelimiters false @@ -647,7 +691,7 @@ rdf/tbox/filegraph/tbox/vivo-skos-1.5.owl - homePage.geoFocusMaps = enabled + homePage.geoFocusMaps enabled @@ -667,13 +711,35 @@ rdf/tbox/filegraph/tbox/vivo-skos-1.5.owl - MultiViews.profilePageTypes=disabled + MultiViews.profilePageTypes disabled + + + Setting this property causes VIVO 1.6 to produce extended responses to requests + for linked data. This provides compatibility with earlier releases. + The default is false. +
    + Extended linked data is costly, in terms of server resource. Typically, extended + linke data contains 50% more information than its non-extended equivalent, and + takes 10 times as long to produce. +
    + Extended linked data will not be supported in future releases of VIVO. + + + + + serveExtendedLinkedData + + + true + + + From 9dcf9d50e19fe32cb37f98918dddaaf55a243cd4 Mon Sep 17 00:00:00 2001 From: j2blake Date: Fri, 13 Sep 2013 14:29:10 -0400 Subject: [PATCH 3/4] Remove superfluous noise from the log. --- .../templatemodels/searchresult/IndividualSearchResult.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/edu/cornell/mannlib/vitro/webapp/web/templatemodels/searchresult/IndividualSearchResult.java b/src/edu/cornell/mannlib/vitro/webapp/web/templatemodels/searchresult/IndividualSearchResult.java index 780f95a2..782c2316 100644 --- a/src/edu/cornell/mannlib/vitro/webapp/web/templatemodels/searchresult/IndividualSearchResult.java +++ b/src/edu/cornell/mannlib/vitro/webapp/web/templatemodels/searchresult/IndividualSearchResult.java @@ -16,18 +16,18 @@ public class IndividualSearchResult extends BaseIndividualSearchResult { public IndividualSearchResult(Individual individual, VitroRequest vreq) { super(individual, vreq); - log.info("Called Individual Search Result"); + log.debug("Called Individual Search Result"); } /* Access methods for templates */ public String getPreferredTitle() { - log.info("Called get Title"); + log.debug("Called get Title"); return individual.getDataValue(CORE + "preferredTitle"); } public String getEmail() { - log.info("Called get Email"); + log.debug("Called get Email"); return individual.getDataValue(CORE + "email"); } From 5b8309bcbccde6b2369a444201676f9cc1d7d383 Mon Sep 17 00:00:00 2001 From: j2blake Date: Fri, 13 Sep 2013 17:24:59 -0400 Subject: [PATCH 4/4] VIVO-262 Complete the push script. Add more checking to extract_files. --- utilities/releaseScripts/4_extract_files.rb | 25 +++++++++++-- utilities/releaseScripts/8_push_changes.rb | 39 +++++++++++++++++++++ 2 files changed, 62 insertions(+), 2 deletions(-) create mode 100644 utilities/releaseScripts/8_push_changes.rb diff --git a/utilities/releaseScripts/4_extract_files.rb b/utilities/releaseScripts/4_extract_files.rb index 6b480338..d223158f 100644 --- a/utilities/releaseScripts/4_extract_files.rb +++ b/utilities/releaseScripts/4_extract_files.rb @@ -21,7 +21,23 @@ require '_common' # # Get the VIVO files and the Vitro files, and remove the .git directories. # -def export_files(vivo_path, vitro_path, tag, export_dir) +def export_files(vivo_path, vitro_path, tag, branch, export_dir) + Dir.chdir(vivo_path) do |path| + cmds = ["git checkout #{branch}", + "git pull", + ] + cmds.delete_at(1) unless is_remote_branch?(branch) + approve_and_execute(cmds, "in #{path}") + end + + Dir.chdir(vitro_path) do |path| + cmds = ["git checkout #{branch}", + "git pull", + ] + cmds.delete_at(1) unless is_remote_branch?(branch) + approve_and_execute(cmds, "in #{path}") + end + approve_and_execute([ "rm -Rf #{File.expand_path("..", export_dir)}", "mkdir -pv #{export_dir}", @@ -31,6 +47,10 @@ def export_files(vivo_path, vitro_path, tag, export_dir) ]) end +def is_remote_branch?(branch) + ! `git branch --list -a origin/#{branch}`.strip.empty? +end + # # ------------------------------------------------------------------------------------ # Main method @@ -39,6 +59,7 @@ end begin tag = Settings.tag_name + branch = Settings.branch_name vivo_path = Settings.vivo_path vitro_path = Settings.vitro_path export_dir = Settings.export_dir @@ -54,7 +75,7 @@ begin get_permission_and_go(p) do puts "Building export area" - export_files(vivo_path, vitro_path, tag, export_dir) + export_files(vivo_path, vitro_path, tag, branch, export_dir) end rescue BadState puts "#{$!.message} - Aborting." diff --git a/utilities/releaseScripts/8_push_changes.rb b/utilities/releaseScripts/8_push_changes.rb new file mode 100644 index 00000000..3bb46eba --- /dev/null +++ b/utilities/releaseScripts/8_push_changes.rb @@ -0,0 +1,39 @@ +=begin +-------------------------------------------------------------------------------- + +Push any branches, tags, or merges back to GitHub. + +-------------------------------------------------------------------------------- +-------------------------------------------------------------------------------- +=end + +$: << File.dirname(File.expand_path(__FILE__)) +require '_common' + +# +# Merge the maintenance branch to the master branch and create the tag. +# +def push_to_origin(repo_path) + Dir.chdir(repo_path) do |path| + approve_and_execute(["git push --all", "git push --tags"], "in #{path}") + end +end + +# +# ------------------------------------------------------------------------------------ +# Main method +# ------------------------------------------------------------------------------------ +# + +begin + vivo_path = Settings.vivo_path + vitro_path = Settings.vitro_path + + get_permission_and_go("OK to push changes to the origin?") do + puts "Merging tags" + push_to_origin(vivo_path) + push_to_origin(vitro_path) + end +rescue BadState + puts "#{$!.message} - Aborting." +end