Skip to content
This repository has been archived by the owner on May 10, 2023. It is now read-only.

Commit

Permalink
Remove excessing logging, restore xoai request profile to default
Browse files Browse the repository at this point in the history
  • Loading branch information
peterdietz committed Aug 21, 2014
1 parent 62b3472 commit bacd014
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@
import org.dspace.xoai.data.DSpaceItem; import org.dspace.xoai.data.DSpaceItem;


/** /**
* BitstreamAccessFilter - To determine if there is a publicly accessible bitstream that is accessible * Does this item have full-text available?
* i.e. publicly accessible bitstream in the content/original bundle
*
* @author Lyncode Development Team <dspace@lyncode.com> * @author Lyncode Development Team <dspace@lyncode.com>
*/ */
public class DSpaceAuthorizationFilter extends DSpaceFilter public class DSpaceAuthorizationFilter extends DSpaceFilter
Expand All @@ -36,7 +38,6 @@ public class DSpaceAuthorizationFilter extends DSpaceFilter
@Override @Override
public DatabaseFilterResult getWhere(Context context) public DatabaseFilterResult getWhere(Context context)
{ {
log.info("GetWhere");
List<Object> params = new ArrayList<Object>(); List<Object> params = new ArrayList<Object>();
return new DatabaseFilterResult("EXISTS (SELECT p.action_id FROM " return new DatabaseFilterResult("EXISTS (SELECT p.action_id FROM "
+ "resourcepolicy p, " + "bundle2bitstream b, " + "bundle bu, " + "resourcepolicy p, " + "bundle2bitstream b, " + "bundle bu, "
Expand All @@ -50,7 +51,6 @@ public DatabaseFilterResult getWhere(Context context)
@Override @Override
public boolean isShown(DSpaceItem item) public boolean isShown(DSpaceItem item)
{ {
log.info("Check if isShown for item: " + item.getIdentifier());
try try
{ {
Context ctx = super.getContext(); Context ctx = super.getContext();
Expand All @@ -73,8 +73,6 @@ public boolean isShown(DSpaceItem item)
} }
} }


//If previous loop didn't return true after it found a readable content bitstream, then nothing readable
log.info("NO accessible bitstream in: " + dsitem.getHandle());
return false; return false;
} }
catch (SQLException ex) catch (SQLException ex)
Expand All @@ -91,7 +89,6 @@ public boolean isShown(DSpaceItem item)
@Override @Override
public SolrFilterResult getQuery() public SolrFilterResult getQuery()
{ {
log.info("SOLR getQuery");
return new SolrFilterResult("item.public:true AND item.publicBitstream:true"); return new SolrFilterResult("item.public:true AND item.publicBitstream:true");
} }


Expand Down
3 changes: 1 addition & 2 deletions dspace/config/crosswalks/oai/xoai.xml
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@


<Contexts> <Contexts>
<Context baseurl="request"> <Context baseurl="request">
<!-- Open Access (Downloadable) --> <!--<Filter refid="bitstreamaccessFilter"/>-->
<Filter refid="bitstreamaccessFilter"/>


<Format refid="oaidc" /> <Format refid="oaidc" />
<Format refid="mets" /> <Format refid="mets" />
Expand Down

0 comments on commit bacd014

Please sign in to comment.