Re: [Dspace-tech] Problem with Feedback Link

2011-12-14 Thread helix84
My guess is that you don't have localhost.localdomain in your hosts
file (it doesn't resolve to an IP address). Try either

dspace.url = http://localhost:8080/dspace
dspace.hostname = localhost

or

dspace.url = http://127.0.0.1:8080/dspace
dspace.hostname = 127.0.0.1

BTW which version of dspace is that? 1.5.2?

Regards,
~~helix84

--
Cloud Computing - Latest Buzzword or a Glimpse of the Future?
This paper surveys cloud computing today: What are the benefits? 
Why are businesses embracing it? What are its payoffs and pitfalls?
http://www.accelacomm.com/jaw/sdnl/114/51425149/
___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


Re: [Dspace-tech] Space 1.7.0 and special groups

2011-12-14 Thread Clive Gould
Hi Stuart

You kindly helped me customise the special groups code in
/home/dspace/dspace-1.7.0-src-release/dspace-pi/src/main/java/org/dspace/authenticate/LDAPHierarchicalAuthentication.java
to differentiate between staff and student login.

Before I build DSpace 1.7.1 from source can you please confirm that
the patch below should work properly with 1.7.1

Thanks very much

 Clive


   /*
 * New code written by Stuart Lewis and added by Clive Gould on
7th April 2011 (modified 20/10/11)
 */

public int[] getSpecialGroups(Context context, HttpServletRequest request)
{
   try
   {
   if (!context.getCurrentUser().getNetid().equals())
   {
   Group staffGroup = Group.findByName(context, all-staff);
   Group studentsGroup = Group.findByName(context, all-students);

   // Does the username start with a '1', '4', or '7'?
   if ((studentsGroup != null) 
(context.getCurrentUser().getNetid().startsWith(1) ||
context.getCurrentUser().getNetid().startsWith(4) ||
context.getCurrentUser().getNetid().startsWith(7)))
   {
   // Add them to the students group
   return new int[] { studentsGroup.getID() };
   }
   else if (staffGroup != null)
   {
   // Add them to the staff group
   return new int[] { staffGroup.getID() };
   }
   }
   }
   catch (Exception npe) {
   // The user is not an LDAP user, so we don't need to worry about them
   }
   return new int[0];
}

--
Cloud Computing - Latest Buzzword or a Glimpse of the Future?
This paper surveys cloud computing today: What are the benefits? 
Why are businesses embracing it? What are its payoffs and pitfalls?
http://www.accelacomm.com/jaw/sdnl/114/51425149/
___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


[Dspace-tech] Internal System Error

2011-12-14 Thread Fabiana Zollo

Hi everybody,I'm having a problem when I try to access to the DSpace Home Page. 
The message is this below:
Internal System ErrorThe system has experienced an internal error. Please try 
to do what you were doing again, and if problem persists, please contact us so 
we can fix the problem.
I checked the log files in the DSpace directory, and this below is the content 
of the dspace .log file.
Could anyone help me? I haven't made any changes and the system was perfectly 
running before.
Thanks in advance,Fabiana

2011-12-14 12:51:08,187 WARN  org.dspace.storage.rdbms.DataSourceInit @ 
Exception initializing DB pooljava.lang.ClassNotFoundException: at 
java.lang.Class.forName0(Native Method)  at java.lang.Class.forName(Unknown 
Source)  at 
org.dspace.storage.rdbms.DataSourceInit.getDatasource(DataSourceInit.java:38)   
 at 
org.dspace.storage.rdbms.DatabaseManager.initialize(DatabaseManager.java:1513)  
 at 
org.dspace.storage.rdbms.DatabaseManager.getConnection(DatabaseManager.java:585)
 at org.dspace.core.Context.init(Context.java:95)  at 
org.dspace.app.webui.util.UIUtil.obtainContext(UIUtil.java:98)   at 
org.apache.jsp.index_jsp._jspService(index_jsp.java:109) at 
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)   at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:722) at 
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432) 
 at 
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390) at 
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:722) at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at 
org.dspace.utils.servlet.DSpaceWebappServletFilter.doFilter(DSpaceWebappServletFilter.java:78)
   at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:224)
  at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:169)
  at 
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
   at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)   
 at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98) at 
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:928)at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)  at 
org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:987)
   at 
org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:539)
  at 
org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:298)
 at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)  
 at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)   at 
java.lang.Thread.run(Unknown Source)2011-12-14 12:51:08,187 WARN  
org.dspace.jsp @ 
anonymous:no_context:database_error:java.sql.SQLException\colon; 
java.lang.ClassNotFoundException\colon; java.sql.SQLException: 
java.lang.ClassNotFoundException: at 
org.dspace.storage.rdbms.DataSourceInit.getDatasource(DataSourceInit.java:149)  
 at 
org.dspace.storage.rdbms.DatabaseManager.initialize(DatabaseManager.java:1513)  
 at 
org.dspace.storage.rdbms.DatabaseManager.getConnection(DatabaseManager.java:585)
 at org.dspace.core.Context.init(Context.java:95)  at 
org.dspace.app.webui.util.UIUtil.obtainContext(UIUtil.java:98)   at 
org.apache.jsp.index_jsp._jspService(index_jsp.java:109) at 
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)   at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:722) at 
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432) 
 at 
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390) at 
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:722) at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at 
org.dspace.utils.servlet.DSpaceWebappServletFilter.doFilter(DSpaceWebappServletFilter.java:78)
   at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at 

[Dspace-tech] SEVERE: Exception unloading sessions to persistent storage

2011-12-14 Thread helix84
Hello,

my DSpace repository is 1.8.0 with XMLUI and Discovery enabled.

I've been having a problem with it every few days - DSpace stops
responding and Tomcat has to be restarted. The following error is
logged many times:

SEVERE: Exception unloading sessions to persistent storage
java.io.FileNotFoundException:
/var/lib/tomcat6/work/Catalina/localhost/_/SESSIONS.ser (Too many open
files)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.init(FileOutputStream.java:209)
at java.io.FileOutputStream.init(FileOutputStream.java:99)
at 
org.apache.catalina.session.StandardManager.doUnload(StandardManager.java:495)
at 
org.apache.catalina.session.StandardManager$PrivilegedDoUnload.run(StandardManager.java:89)
at java.security.AccessController.doPrivileged(Native Method)
at 
org.apache.catalina.session.StandardManager.unload(StandardManager.java:458)
at 
org.apache.catalina.session.StandardManager.stop(StandardManager.java:673)
at 
org.apache.catalina.core.StandardContext.stop(StandardContext.java:4774)
at 
org.apache.catalina.core.StandardContext.reload(StandardContext.java:3385)
at 
org.apache.catalina.loader.WebappLoader.backgroundProcess(WebappLoader.java:426)
at 
org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1309)
at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1601)
at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1590)
at java.lang.Thread.run(Thread.java:636)


I tried to google for the error and found much about Too many open
files in Tomcat and even DSpace, but this particular error Exception
unloading sessions to persistent storage seems to be unique.

cat /proc/sys/fs/file-max
101728

Is there someone who can help me debug this issue? Thanks.

Regards,
~~helix84

--
Cloud Computing - Latest Buzzword or a Glimpse of the Future?
This paper surveys cloud computing today: What are the benefits? 
Why are businesses embracing it? What are its payoffs and pitfalls?
http://www.accelacomm.com/jaw/sdnl/114/51425149/
___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


Re: [Dspace-tech] Internal System Error

2011-12-14 Thread George S Kozak
Fabiana:

I think the  problem is with your database.I don't know which kind you are 
using Postgres or Oracle, but you should check to see if it is running.  Also, 
if it is running, you should check to see that the permissions are set so that 
the dspace user can read and write to the database.

George Kozak
Digital Library Specialist
Cornell University Library Information Technologies (CUL-IT)
501 Olin Library
Cornell University
Ithaca, NY 14853
607-255-8924

From: Fabiana Zollo [mailto:picc...@hotmail.it]
Sent: Wednesday, December 14, 2011 6:59 AM
To: dspace-tech@lists.sourceforge.net
Subject: [Dspace-tech] Internal System Error

Hi everybody,
I'm having a problem when I try to access to the DSpace Home Page. The message 
is this below:

Internal System Error
The system has experienced an internal error. Please try to do what you were 
doing again, and if problem persists, please contact us so we can fix the 
problem.

I checked the log files in the DSpace directory, and this below is the content 
of the dspace .log file.

Could anyone help me? I haven't made any changes and the system was perfectly 
running before.

Thanks in advance,
Fabiana


2011-12-14 12:51:08,187 WARN  org.dspace.storage.rdbms.DataSourceInit @ 
Exception initializing DB pool
java.lang.ClassNotFoundException:
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at 
org.dspace.storage.rdbms.DataSourceInit.getDatasource(DataSourceInit.java:38)
at 
org.dspace.storage.rdbms.DatabaseManager.initialize(DatabaseManager.java:1513)
at 
org.dspace.storage.rdbms.DatabaseManager.getConnection(DatabaseManager.java:585)
at org.dspace.core.Context.init(Context.java:95)
at org.dspace.app.webui.util.UIUtil.obtainContext(UIUtil.java:98)
at org.apache.jsp.index_jsp._jspService(index_jsp.java:109)
at 
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at 
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
at 
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at 
org.dspace.utils.servlet.DSpaceWebappServletFilter.doFilter(DSpaceWebappServletFilter.java:78)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:224)
at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:169)
at 
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)
at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98)
at 
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:928)
at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)
at 
org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:987)
at 
org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:539)
at 
org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:298)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown 
Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown 
Source)
at java.lang.Thread.run(Unknown Source)
2011-12-14 12:51:08,187 WARN  org.dspace.jsp @ 
anonymous:no_context:database_error:java.sql.SQLException\colon; 
java.lang.ClassNotFoundException\colon;
java.sql.SQLException: java.lang.ClassNotFoundException:
at 
org.dspace.storage.rdbms.DataSourceInit.getDatasource(DataSourceInit.java:149)
at 
org.dspace.storage.rdbms.DatabaseManager.initialize(DatabaseManager.java:1513)
at 
org.dspace.storage.rdbms.DatabaseManager.getConnection(DatabaseManager.java:585)
at org.dspace.core.Context.init(Context.java:95)
at org.dspace.app.webui.util.UIUtil.obtainContext(UIUtil.java:98)
at org.apache.jsp.index_jsp._jspService(index_jsp.java:109)

Re: [Dspace-tech] Internal System Error

2011-12-14 Thread Mark H. Wood
On Wed, Dec 14, 2011 at 12:58:42PM +0100, Fabiana Zollo wrote:
 
 Hi everybody,I'm having a problem when I try to access to the DSpace Home 
 Page. The message is this below:
 Internal System ErrorThe system has experienced an internal error. Please try 
 to do what you were doing again, and if problem persists, please contact us 
 so we can fix the problem.
 I checked the log files in the DSpace directory, and this below is the 
 content of the dspace .log file.
 Could anyone help me? I haven't made any changes and the system was perfectly 
 running before.
 Thanks in advance,Fabiana
 
 2011-12-14 12:51:08,187 WARN org.dspace.storage.rdbms.DataSourceInit @ 
 Exception initializing DB pool
java.lang.ClassNotFoundException:
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)  

That looks to me like a damaged value for the config/dspace.cfg
setting db.driver.  If you're using PostgreSQL then the value should
be org.postgresql.Driver, and if Oracle then oracle.jdbc.OracleDriver.

-- 
Mark H. Wood, Lead System Programmer   mw...@iupui.edu
Asking whether markets are efficient is like asking whether people are smart.


pgpFSi2rp1IRO.pgp
Description: PGP signature
--
Cloud Computing - Latest Buzzword or a Glimpse of the Future?
This paper surveys cloud computing today: What are the benefits? 
Why are businesses embracing it? What are its payoffs and pitfalls?
http://www.accelacomm.com/jaw/sdnl/114/51425149/___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


Re: [Dspace-tech] List Items in the Initial Collections Display

2011-12-14 Thread Joseph
Peter,
That's a good idea.  At what level did you add that link.  XSL or in an aspect?

There is a drawback of funneling the user into the browse by title for
those of us using discovery, since the discovery facets don't show up
inside browse.  But at this point, it's better than a (semi)blank
page.

-Joseph



On Tue, Nov 29, 2011 at 11:50, Peter Dietz pdiet...@gmail.com wrote:
 Hi Joseph,

 We've run across this usability stumbling block too.

 You get to a collection and there's nothing in it (atleast it looks that
 way). Our interest was to add browse-by-title and show some 20 results. We
 haven't done that yet, but we've atleast added a link to Click Here to show
 all submissions after the 5 recent entries. And it alteast gives the user a
 logical path in to the contents of the collection.
 https://kb.osu.edu/dspace/handle/1811/37112


 Peter Dietz



 On Tue, Nov 29, 2011 at 11:30 AM, Joseph joseph.rho...@gmail.com wrote:

 Dear Dspace-tech,

 Great great job to Remei Quero and Àlex Magaz Graça for
 https://wiki.duraspace.org/display/~alexm/Usability+Test+Report

 There were several great points made, but I'm going to focus on one;
  When the user clicks on a collection, they either see no items, or
 recently submitted items.
 Both of which are not always what we want.

 Have any of you modified your collections pages to display items in
 your collection (such as would be viewed if the user clicked on a
 Browse by option).

 Or do you have ideas how you might do this?

 -Joseph


 --
 All the data continuously generated in your IT infrastructure
 contains a definitive record of customers, application performance,
 security threats, fraudulent activity, and more. Splunk takes this
 data and makes sense of it. IT sense. And common sense.
 http://p.sf.net/sfu/splunk-novd2d
 ___
 DSpace-tech mailing list
 DSpace-tech@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/dspace-tech



--
Cloud Computing - Latest Buzzword or a Glimpse of the Future?
This paper surveys cloud computing today: What are the benefits? 
Why are businesses embracing it? What are its payoffs and pitfalls?
http://www.accelacomm.com/jaw/sdnl/114/51425149/
___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


Re: [Dspace-tech] List Items in the Initial Collections Display

2011-12-14 Thread Peter Dietz
Hi Joseph,

We made that change from XSL. Our xmlui is based off of dri2xhtml /
Reference, we just match on the div, so try:

https://gist.github.com/1477527
!-- adding the 'View all' link --
xsl:template match=dri:div[@n='collection-recent-submission'] |
dri:div[@n='community-recent-submission']
xsl:apply-templates select=./dri:head/
ul class=ds-artifact-list
xsl:apply-templates select=./dri:referenceSet
mode=summaryList/
/ul
div id=more-link
a
xsl:attribute name=href
xsl:value-of
select=/dri:document/dri:body/dri:div/dri:div/dri:div/dri:list/dri:item[3]/dri:xref/@target/
/xsl:attribute
xsl:textView all submissions /xsl:text
/a
/div
/xsl:template

This code was written by my coworker Brian Stamper.


Peter Dietz



On Wed, Dec 14, 2011 at 11:55 AM, Joseph joseph.rho...@gmail.com wrote:

 Peter,
 That's a good idea.  At what level did you add that link.  XSL or in an
 aspect?

 There is a drawback of funneling the user into the browse by title for
 those of us using discovery, since the discovery facets don't show up
 inside browse.  But at this point, it's better than a (semi)blank
 page.

 -Joseph



 On Tue, Nov 29, 2011 at 11:50, Peter Dietz pdiet...@gmail.com wrote:
  Hi Joseph,
 
  We've run across this usability stumbling block too.
 
  You get to a collection and there's nothing in it (atleast it looks that
  way). Our interest was to add browse-by-title and show some 20 results.
 We
  haven't done that yet, but we've atleast added a link to Click Here to
 show
  all submissions after the 5 recent entries. And it alteast gives the
 user a
  logical path in to the contents of the collection.
  https://kb.osu.edu/dspace/handle/1811/37112
 
 
  Peter Dietz
 
 
 
  On Tue, Nov 29, 2011 at 11:30 AM, Joseph joseph.rho...@gmail.com
 wrote:
 
  Dear Dspace-tech,
 
  Great great job to Remei Quero and Àlex Magaz Graça for
  https://wiki.duraspace.org/display/~alexm/Usability+Test+Reporthttps://wiki.duraspace.org/display/%7Ealexm/Usability+Test+Report
 
  There were several great points made, but I'm going to focus on one;
   When the user clicks on a collection, they either see no items, or
  recently submitted items.
  Both of which are not always what we want.
 
  Have any of you modified your collections pages to display items in
  your collection (such as would be viewed if the user clicked on a
  Browse by option).
 
  Or do you have ideas how you might do this?
 
  -Joseph
 
 
 
 --
  All the data continuously generated in your IT infrastructure
  contains a definitive record of customers, application performance,
  security threats, fraudulent activity, and more. Splunk takes this
  data and makes sense of it. IT sense. And common sense.
  http://p.sf.net/sfu/splunk-novd2d
  ___
  DSpace-tech mailing list
  DSpace-tech@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/dspace-tech
 
 

--
Cloud Computing - Latest Buzzword or a Glimpse of the Future?
This paper surveys cloud computing today: What are the benefits? 
Why are businesses embracing it? What are its payoffs and pitfalls?
http://www.accelacomm.com/jaw/sdnl/114/51425149/___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


Re: [Dspace-tech] Space 1.7.0 and special groups

2011-12-14 Thread Stuart Lewis
Hi Clive,

The authentication classes have changed very little (if at all) over the past 
few versions, so the code should still work fine.

Thanks,


Stuart Lewis
Digital Development Manager
Te Tumu Herenga The University of Auckland Library
Auckland Mail Centre, Private Bag 92019, Auckland 1142, New Zealand
Ph: +64 (0)9 373 7599 x81928


On 15/12/2011, at 12:51 AM, Clive Gould wrote:

 Hi Stuart
 
 You kindly helped me customise the special groups code in
 /home/dspace/dspace-1.7.0-src-release/dspace-pi/src/main/java/org/dspace/authenticate/LDAPHierarchicalAuthentication.java
 to differentiate between staff and student login.
 
 Before I build DSpace 1.7.1 from source can you please confirm that
 the patch below should work properly with 1.7.1
 
 Thanks very much
 
 Clive
 
 
   /*
 * New code written by Stuart Lewis and added by Clive Gould on
 7th April 2011 (modified 20/10/11)
 */
 
public int[] getSpecialGroups(Context context, HttpServletRequest request)
{
   try
   {
   if (!context.getCurrentUser().getNetid().equals())
   {
   Group staffGroup = Group.findByName(context, all-staff);
   Group studentsGroup = Group.findByName(context, all-students);
 
   // Does the username start with a '1', '4', or '7'?
   if ((studentsGroup != null) 
 (context.getCurrentUser().getNetid().startsWith(1) ||
 context.getCurrentUser().getNetid().startsWith(4) ||
 context.getCurrentUser().getNetid().startsWith(7)))
   {
   // Add them to the students group
   return new int[] { studentsGroup.getID() };
   }
   else if (staffGroup != null)
   {
   // Add them to the staff group
   return new int[] { staffGroup.getID() };
   }
   }
   }
   catch (Exception npe) {
   // The user is not an LDAP user, so we don't need to worry about 
 them
   }
   return new int[0];
}




--
Cloud Computing - Latest Buzzword or a Glimpse of the Future?
This paper surveys cloud computing today: What are the benefits? 
Why are businesses embracing it? What are its payoffs and pitfalls?
http://www.accelacomm.com/jaw/sdnl/114/51425149/
___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


[Dspace-tech] creating a checkbox

2011-12-14 Thread Blanco, Jose
I want to create a checkbox that will eventually be rendered as:

input type=checkbox name=checkall onclick=checkUncheckAll(this);  /

I have tried this:

CheckBox select1 = 
actions.addCheckBox(checkall).setValue(Select);
select1.setLabel(Select);
select1.addOption(onclick=checkUncheckAll(this););

But this gives me:

input name=checkall type=checkbox value=onclick=checkUncheckAll(this); /

So how do I get the, 

onclick=checkUncheckAll(this);  

?

Thank you,
Jose

--
Cloud Computing - Latest Buzzword or a Glimpse of the Future?
This paper surveys cloud computing today: What are the benefits? 
Why are businesses embracing it? What are its payoffs and pitfalls?
http://www.accelacomm.com/jaw/sdnl/114/51425149/
___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


Re: [Dspace-tech] creating a checkbox

2011-12-14 Thread Mark Diggory
Jose, at this time handlers need to be added in xslt. You can find the
template that generates checkbox from DRI to XHTML and create one that
refines to match @name and the @id of the div it is inside and add your
handlers there.

Mark


On Wednesday, December 14, 2011, Blanco, Jose blan...@umich.edu wrote:
 I want to create a checkbox that will eventually be rendered as:

 input type=checkbox name=checkall onclick=checkUncheckAll(this);
 /

 I have tried this:

CheckBox select1 =
actions.addCheckBox(checkall).setValue(Select);
select1.setLabel(Select);
select1.addOption(onclick=checkUncheckAll(this););

 But this gives me:

 input name=checkall type=checkbox
value=onclick=checkUncheckAll(this); /

 So how do I get the,

 onclick=checkUncheckAll(this);

 ?

 Thank you,
 Jose


--
 Cloud Computing - Latest Buzzword or a Glimpse of the Future?
 This paper surveys cloud computing today: What are the benefits?
 Why are businesses embracing it? What are its payoffs and pitfalls?
 http://www.accelacomm.com/jaw/sdnl/114/51425149/
 ___
 DSpace-tech mailing list
 DSpace-tech@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/dspace-tech

--
10 Tips for Better Server Consolidation
Server virtualization is being driven by many needs.  
But none more important than the need to reduce IT complexity 
while improving strategic productivity.  Learn More! 
http://www.accelacomm.com/jaw/sdnl/114/51507609/___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


Re: [Dspace-tech] SEVERE: Exception unloading sessions to persistent storage

2011-12-14 Thread Mark Diggory
Disable session persistence in tomcat? It's not really ever needed. But I
suspect that either there's a leak in some code leaving files open or you
don't have enough I nodes for your file system...

Mark

On Wednesday, December 14, 2011, helix84 heli...@centrum.sk wrote:
 Hello,

 my DSpace repository is 1.8.0 with XMLUI and Discovery enabled.

 I've been having a problem with it every few days - DSpace stops
 responding and Tomcat has to be restarted. The following error is
 logged many times:

 SEVERE: Exception unloading sessions to persistent storage
 java.io.FileNotFoundException:
 /var/lib/tomcat6/work/Catalina/localhost/_/SESSIONS.ser (Too many open
 files)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.init(FileOutputStream.java:209)
at java.io.FileOutputStream.init(FileOutputStream.java:99)
at
org.apache.catalina.session.StandardManager.doUnload(StandardManager.java:495)
at
org.apache.catalina.session.StandardManager$PrivilegedDoUnload.run(StandardManager.java:89)
at java.security.AccessController.doPrivileged(Native Method)
at
org.apache.catalina.session.StandardManager.unload(StandardManager.java:458)
at
org.apache.catalina.session.StandardManager.stop(StandardManager.java:673)
at
org.apache.catalina.core.StandardContext.stop(StandardContext.java:4774)
at
org.apache.catalina.core.StandardContext.reload(StandardContext.java:3385)
at
org.apache.catalina.loader.WebappLoader.backgroundProcess(WebappLoader.java:426)
at
org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1309)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1601)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1590)
at java.lang.Thread.run(Thread.java:636)


 I tried to google for the error and found much about Too many open
 files in Tomcat and even DSpace, but this particular error Exception
 unloading sessions to persistent storage seems to be unique.

 cat /proc/sys/fs/file-max
 101728

 Is there someone who can help me debug this issue? Thanks.

 Regards,
 ~~helix84


--
 Cloud Computing - Latest Buzzword or a Glimpse of the Future?
 This paper surveys cloud computing today: What are the benefits?
 Why are businesses embracing it? What are its payoffs and pitfalls?
 http://www.accelacomm.com/jaw/sdnl/114/51425149/
 ___
 DSpace-tech mailing list
 DSpace-tech@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/dspace-tech

attachment: Attachment001.png--
10 Tips for Better Server Consolidation
Server virtualization is being driven by many needs.  
But none more important than the need to reduce IT complexity 
while improving strategic productivity.  Learn More! 
http://www.accelacomm.com/jaw/sdnl/114/51507609/___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


Re: [Dspace-tech] SEVERE: Exception unloading sessions to persistent storage

2011-12-14 Thread Andrea Schweer
Hi helix84,

On 15/12/11 03:37, helix84 wrote:
 I tried to google for the error and found much about Too many open
 files in Tomcat and even DSpace, but this particular error Exception
 unloading sessions to persistent storage seems to be unique.

I didn't have your particular issue (I only just upgraded my repos to
1.7.2, maybe this is a 1.8 thing), but we've had to bump the ulimit up
-- /proc/sys/fs/file-max is reasonably high for us too, but the problem
was the limit of #files _per user_.  ulimit -n should tell you what that
is, or on a RedHat system look at /etc/security/limits.conf.

ls -l /proc/${TOMCAT_PID}/fd/ | wc -l
shows you how many files are open by the tomcat process, where
TOMCAT_PID=`/usr/bin/jps | grep Bootstrap | cut -d ' ' -f 1`
(you'll probably need to run this as root).

We're logging #open files and tomcat sometimes has up to 3000 files --
our ulimit (RedHat default) originally was 1024.

#open files drops with each full garbage collection, and I suspect this
is somehow connected to the Cocoon sitemaps -- maybe it's
https://issues.apache.org/jira/browse/COCOON-1261 where they say that
this isn't a bug.

cheers,
Andrea

-- 
Dr Andrea Schweer
IRR Technical Specialist, ITS Information Systems
The University of Waikato, Hamilton, New Zealand


--
10 Tips for Better Server Consolidation
Server virtualization is being driven by many needs.  
But none more important than the need to reduce IT complexity 
while improving strategic productivity.  Learn More! 
http://www.accelacomm.com/jaw/sdnl/114/51507609/
___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


[Dspace-tech] Can not update dspace index

2011-12-14 Thread wang maple
Hi ,ereryone

Today, I want to enable dspace1.5 running under WindowsXP to search
Chinese results and do some work below:
1、modified [dspace]\dspace.cfg
# Chinese analyzer
search.analyzer = org.apache.lucene.analysis.cn.ChineseAnalyzer
2、run dsrun command in command line
F:\dspace\bindsrun org.dspace.search.DSIndexer

But there are lots of error messages

F:\dspace\binun.bat
'un.bat'   is not recognized as an
internal or external command, runnable program or batch file.

F:\dspace\binM Version: $Revision: 3705 $
'M' is not recognized as an
internal or external command, runnable program or batch file.

F:\dspace\binM Date: $Date: 2009-04-12 01:02:24 +0800 (? 12 �� 2009
) $
'M'  is not recognized as an
internal or external command, runnable program or batch file.


My environmental parameter PATH CLASSPATH JAVA_HOME are all correct
How can i resolve this problem?

Thanks very much and waitting for your answer.

Yours
maple

--
10 Tips for Better Server Consolidation
Server virtualization is being driven by many needs.  
But none more important than the need to reduce IT complexity 
while improving strategic productivity.  Learn More! 
http://www.accelacomm.com/jaw/sdnl/114/51507609/___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech