Revision d3ff9c69 src/gr/ebs/gss/server/ejb/ExternalAPIBean.java
b/src/gr/ebs/gss/server/ejb/ExternalAPIBean.java | ||
---|---|---|
1851 | 1851 |
stats.setFileCount(dao.getFileCount(userId)); |
1852 | 1852 |
Long fileSize = dao.getFileSize(userId); |
1853 | 1853 |
stats.setFileSize(fileSize); |
1854 |
Long quota = getConfiguration().getLong("quota", new Long(52428800L));
|
|
1854 |
Long quota = getQuota(userId);
|
|
1855 | 1855 |
Long quotaLeft = quota - fileSize; |
1856 | 1856 |
stats.setQuotaLeftSize(quotaLeft); |
1857 | 1857 |
return stats; |
... | ... | |
1985 | 1985 |
*/ |
1986 | 1986 |
private Long getQuotaLeft(Long userId){ |
1987 | 1987 |
Long fileSize = dao.getFileSize(userId); |
1988 |
Long quota = getConfiguration().getLong("quota", new Long(52428800L));
|
|
1988 |
Long quota = getQuota(userId);
|
|
1989 | 1989 |
return quota - fileSize; |
1990 | 1990 |
} |
1991 | 1991 |
|
1992 |
/** |
|
1993 |
* Gets the quota for specified userId |
|
1994 |
* @param userId |
|
1995 |
* @return |
|
1996 |
*/ |
|
1997 |
private Long getQuota(@SuppressWarnings("unused") Long userId){ |
|
1998 |
Long quota = getConfiguration().getLong("quota", new Long(52428800L)); |
|
1999 |
return quota; |
|
2000 |
} |
|
2001 |
|
|
1992 | 2002 |
public void rebuildSolrIndex() { |
1993 | 2003 |
MessageProducer sender = null; |
1994 | 2004 |
Session session = null; |
Also available in: Unified diff