Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LibreClinica-odm module as a part of parent build process #8

Merged
merged 57 commits into from
Sep 9, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
83f8b63
Initial setup for LibreClinica-odm module
toskrip Apr 2, 2019
a62b249
Merge branch 'lc-develop' into lc-odm
toskrip Apr 12, 2019
86e0247
issue 9: updated commons-fileupload from 1.2 to 1.3.3
chae-reliatec Apr 16, 2019
f47be6d
Merge branch 'lc-issue9-update_file_uploads' into lc-develop
chae-reliatec Apr 16, 2019
265b146
issue 9: updated commons-fileupload from 1.2 to 1.3.3
chae-reliatec Apr 16, 2019
2ed6b03
Merge branch 'lc-issue9-update_file_uploads' into lc-develop
chae-reliatec Apr 16, 2019
4b5f587
added database changes for the quartz scheduler to the liquibase migr…
chae-reliatec May 9, 2019
e3d38d5
since the library updates the export didn't worked and this fixes the…
chae-reliatec May 9, 2019
e3b45af
updated XslTTransformJob to use saxon instead of xalan for the export…
chae-reliatec May 14, 2019
6b9dbe2
Merge branch 'lc-spring5' into lc-develop
chae-reliatec May 14, 2019
290160a
fixed 'changeLogCreateTables.xml' liquibase script to detect if the u…
chae-reliatec May 21, 2019
678d9e4
Merge pull request #12 from reliatec-gmbh/update_migration_scripts_fo…
chae-reliatec May 21, 2019
3a7e225
send message 'is ub a ldapuser??' to the logger at DEBUG level
chae-reliatec May 23, 2019
7e197f0
Merge pull request #14 from reliatec-gmbh/is_ub_a_ldapuser
chae-reliatec May 23, 2019
b338163
Merge branch 'lc-develop' of https://github.com/reliatec-gmbh/LibreCl…
chae-reliatec May 24, 2019
7035e36
fixed issue #15 UpdateSubStudyServlet to persist all changed values
chae-reliatec May 24, 2019
34ef239
Merge pull request #16 from reliatec-gmbh/issue_15_changes_for_the_si…
chae-reliatec May 24, 2019
ad8b21b
removed duplicate loadings of 'global_functions_javascript.js' and 'i…
chae-reliatec May 24, 2019
eacd70f
Merge pull request #18 from reliatec-gmbh/issue_17_poor_performance_i…
chae-reliatec May 24, 2019
474301e
'Notes & Discrepancies Assigned to Me' calculation fixed
chae-reliatec May 28, 2019
8c7f81a
Merge pull request #24 from reliatec-gmbh/issue_19-count_of_dn_assign…
chae-reliatec May 28, 2019
19eaeff
dn of crfs with state 'initial data entry' will be opened in edit mode
chae-reliatec May 28, 2019
91f8191
when button 'view within record' is used the correct section is opene…
chae-reliatec May 29, 2019
ec65a64
Merge pull request #25 from reliatec-gmbh/issue_20_view_discrepancy_n…
chae-reliatec May 29, 2019
557d87e
changed OCFileRename.rename to create unique file names
chae-reliatec May 29, 2019
532b3c2
Merge pull request #26 from reliatec-gmbh/issue_21-unwished_deletion_…
chae-reliatec May 29, 2019
337fda3
set collectStats to false in datainfo.properties
chae-reliatec May 29, 2019
5569119
Merge pull request #27 from reliatec-gmbh/issue_22-deactivate_collect…
chae-reliatec May 29, 2019
d6d7980
filter duplicate results from DatasetDAO query to reduce memory footp…
chae-reliatec May 29, 2019
4d756bd
Merge pull request #29 from reliatec-gmbh/issue_23-reduce_memory_foot…
chae-reliatec May 29, 2019
47fa434
changed current favicon to the LibreClinica version
chae-reliatec May 29, 2019
ada5c3c
changed groupId to 'org.libreclinica' and artifactId to 'LibreClinica'
chae-reliatec May 29, 2019
12c5c25
Merge pull request #31 from reliatec-gmbh/issue_30-change_groupId_and…
chae-reliatec May 29, 2019
89bd439
issue 32: removed news box from login page
chae-reliatec Sep 2, 2019
90ffb13
Merge pull request #41 from reliatec-gmbh/issue_32_remove_news_box_fr…
chae-reliatec Sep 2, 2019
dc5c975
issue 42: removed unused class RssReaderServlet
chae-reliatec Sep 2, 2019
dee31ed
Merge pull request #45 from reliatec-gmbh/issue_42_remove_RssReaderSe…
chae-reliatec Sep 2, 2019
e3449fe
issue 43: removed unused lib rome:rome
chae-reliatec Sep 2, 2019
98f1d97
Merge pull request #46 from reliatec-gmbh/issue_43_remove_unused_lib_…
chae-reliatec Sep 2, 2019
b6812ad
issue 44: removed unused lib rome:rome-fetcher
chae-reliatec Sep 2, 2019
e31abeb
Merge pull request #47 from reliatec-gmbh/issue_43_remove_unused_lib_…
chae-reliatec Sep 2, 2019
60e42db
issue 40: reenabled logging when the user has logged out
chae-reliatec Sep 2, 2019
a638495
Merge pull request #48 from reliatec-gmbh/issue_40_audit_user_activit…
chae-reliatec Sep 2, 2019
5dc6d8c
issue 38: show 'Support' link in the main menu only if a url is confi…
chae-reliatec Sep 3, 2019
ce4df81
Merge pull request #49 from reliatec-gmbh/issue_38_show_support_link_…
chae-reliatec Sep 3, 2019
81e3d4d
Merge with lc-develop
toskrip Sep 4, 2019
7dca0ee
Re-enable build with odm module
toskrip Sep 4, 2019
b6d8ad1
changed version from 0.2.0 to 0.3.0
chae-reliatec Sep 5, 2019
9cd22ea
Merge branch 'lc-snapshot-v0.3.0' into lc-develop
chae-reliatec Sep 5, 2019
7606f3f
Fix deprecated hibernate methods and hibernate mapping for x_form_name
toskrip Sep 6, 2019
de223b3
Merge branch 'lc-develop' into lc-dao
toskrip Sep 6, 2019
dcb5bb3
Merge branch 'lc-develop' into lc-odm
toskrip Sep 6, 2019
e74e14f
Merge pull request #54 from toskrip/lc-dao
chae-reliatec Sep 6, 2019
69e9917
Merge branch 'lc-develop' of https://github.com/reliatec-gmbh/LibreCl…
chae-reliatec Sep 6, 2019
ce5defe
fixed warnings for class StudyUserRoleDao
chae-reliatec Sep 6, 2019
4b81806
Merge pull request #58 from reliatec-gmbh/lc-code-maintenance
chae-reliatec Sep 6, 2019
dc92584
Merge branch 'lc-develop' into lc-odm
toskrip Sep 9, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
target/
odm/src/main/java/
odm/target/
pom.xml.tag
pom.xml.releaseBackup
pom.xml.versionsBackup
Expand All @@ -8,9 +10,11 @@ release.properties
.project
.settings/
.idea/
LibreClinica.iml
OpenClinica.iml
web/src/main/resources/datainfo.properties
core/*.iml
odm/*.iml
web/*.iml
ws/*.iml
.DS_Store
Expand All @@ -20,10 +24,6 @@ ws/.DS_Store

# git
*.orig
/ws/*.iml
/web/OpenClinica-web.iml
/core/OpenClinica-core.iml
/core/OpenClinica-core.iml

# netbeans
nb-configuration.xml
10 changes: 0 additions & 10 deletions .hgignore

This file was deleted.

45 changes: 26 additions & 19 deletions core/pom.xml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>OpenClinica-core</artifactId>
<artifactId>LibreClinica-core</artifactId>
<packaging>jar</packaging>
<name>OpenClinica Core</name>
<name>LibreClinica Core</name>
<parent>
<groupId>org.akaza.openclinica</groupId>
<artifactId>OpenClinica</artifactId>
<version>3.14</version>
<groupId>org.libreclinica</groupId>
<artifactId>LibreClinica</artifactId>
<version>0.3.0</version>
</parent>
<dependencies>
<dependency>
Expand Down Expand Up @@ -125,13 +125,11 @@
<dependency>
<groupId>commons-fileupload</groupId>
<artifactId>commons-fileupload</artifactId>
<version>1.2.1</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>1.4</version>
<scope>compile</scope>
</dependency>
<dependency>
Expand Down Expand Up @@ -231,10 +229,11 @@
<version>1.4</version>
</dependency>
<dependency>
<groupId>org.akaza.openclinica.odm</groupId>
<artifactId>openclinica-odm</artifactId>
<groupId>org.libreclinica.odm</groupId>
<artifactId>LibreClinica-odm</artifactId>
<version>2.2</version>
</dependency>
<dependency>
<dependency>
<groupId>org.mvel</groupId>
<artifactId>mvel2</artifactId>
<version>2.0.19</version>
Expand All @@ -254,16 +253,24 @@
</dependency>

<dependency>
<groupId>org.codehaus.jackson</groupId>
<artifactId>jackson-core-lgpl</artifactId>
<version>1.8.1</version>
</dependency>
<groupId>org.codehaus.jackson</groupId>
<artifactId>jackson-core-lgpl</artifactId>
<version>1.8.1</version>
</dependency>

<dependency>
<groupId>org.codehaus.jackson</groupId>
<artifactId>jackson-mapper-lgpl</artifactId>
<version>1.8.1</version>
</dependency>
<dependency>
<groupId>org.codehaus.jackson</groupId>
<artifactId>jackson-mapper-lgpl</artifactId>
<version>1.8.1</version>
</dependency>
<dependency>
<groupId>net.sf.saxon</groupId>
<artifactId>saxon</artifactId>
</dependency>
<dependency>
<groupId>net.sf.saxon</groupId>
<artifactId>saxon-dom</artifactId>
</dependency>
</dependencies>
<!-- @pgawade 16-NOV-2010 unit tests through maven -->

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -362,8 +362,8 @@ private Properties setDataInfoProperties() {
DATAINFO.setProperty("rss.more", rss_more);

String supportURL = DATAINFO.getProperty("supportURL");
if (supportURL == null || supportURL.isEmpty())
supportURL = "https://www.openclinica.com/support";
if (supportURL == null || supportURL.trim().isEmpty())
supportURL = "";
DATAINFO.setProperty("supportURL", supportURL);

DATAINFO.setProperty("show_unique_id", "1");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -704,7 +704,7 @@ public DatasetBean initialDatasetData(int datasetId) {
}

protected String getDefinitionCrfItemSql(String sedIds, String itemIds) {
return "select item.*, sed.study_event_definition_id as sed_id, sed.name as sed_name, crf.crf_id, crf.name as crf_name"
return "select DISTINCT item.*, sed.study_event_definition_id as sed_id, sed.name as sed_name, crf.crf_id, crf.name as crf_name"
+ " from study_event_definition sed, event_definition_crf edc, crf, crf_version cv,item_form_metadata ifm, item"
+ " where sed.study_event_definition_id in " + sedIds + " and item.item_id in " + itemIds
+ " and sed.study_event_definition_id = edc.study_event_definition_id and edc.crf_id = crf.crf_id"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import org.hibernate.Session;
import org.hibernate.SessionFactory;
import org.hibernate.internal.SessionImpl;
import org.hibernate.query.Query;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.orm.hibernate5.HibernateTemplate;
Expand All @@ -32,27 +33,27 @@ public String getDomainClassName() {
public T findById(Integer id) {
getSessionFactory().getStatistics().logSummary();
String query = "from " + getDomainClassName() + " do where do.id = :id";
org.hibernate.Query q = getCurrentSession().createQuery(query);
q.setInteger("id", id);
return (T) q.uniqueResult();
Query<T> q = getCurrentSession().createQuery(query);
q.setParameter("id", id);
return q.uniqueResult();
}

@SuppressWarnings("unchecked")
@Transactional
public ArrayList<T> findAll() {
getSessionFactory().getStatistics().logSummary();
String query = "from " + getDomainClassName() + " do";
org.hibernate.Query q = getCurrentSession().createQuery(query);
return (ArrayList<T>) q.list();
Query<T> q = getCurrentSession().createQuery(query);
return new ArrayList<T>(q.list());
}

@SuppressWarnings("unchecked")
public T findByOcOID(String OCOID){
getSessionFactory().getStatistics().logSummary();
String query = "from " + getDomainClassName() + " do where do.oc_oid = :oc_oid";
org.hibernate.Query q = getCurrentSession().createQuery(query);
q.setString("oc_oid", OCOID);
return (T) q.uniqueResult();
Query<T> q = getCurrentSession().createQuery(query);
q.setParameter("oc_oid", OCOID);
return q.uniqueResult();
}

@Transactional
Expand All @@ -65,19 +66,17 @@ public T saveOrUpdate(T domainObject) {
@Transactional
public Serializable save(T domainObject) {
getSessionFactory().getStatistics().logSummary();
Serializable id = getCurrentSession().save(domainObject);
return id;
return getCurrentSession().save(domainObject);
}



@SuppressWarnings("unchecked")
@Transactional
public T findByColumnName(Object id,String key) {
String query = "from " + getDomainClassName() + " do where do."+key +"= ?";
org.hibernate.Query q = getCurrentSession().createQuery(query);
q.setParameter(0, id);
return (T) q.uniqueResult();
}
public T findByColumnName(Object id, String key) {
String query = "from " + getDomainClassName() + " do where do." + key + " = :key_value";
Query<T> q = getCurrentSession().createQuery(query);
q.setParameter("key_value", id);
return q.uniqueResult();
}

public Long count() {
return (Long) getCurrentSession().createQuery("select count(*) from " + domainClass().getName()).uniqueResult();
Expand Down Expand Up @@ -107,7 +106,8 @@ public Session getCurrentSession(String schema) {
//CoreResources.setSchema(sessionImpl.connection());
}
} catch (SQLException e) {
logger.error(e.getMessage(), e); }
logger.error(e.getMessage(), e);
}
}
return session;
}
Expand All @@ -120,6 +120,4 @@ public void setHibernateTemplate(HibernateTemplate hibernateTemplate) {
this.hibernateTemplate = hibernateTemplate;
}



}
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import org.akaza.openclinica.domain.CompositeIdDomainObject;
import org.hibernate.Session;
import org.hibernate.SessionFactory;
import org.hibernate.query.Query;
import org.springframework.orm.hibernate5.HibernateTemplate;
import org.springframework.transaction.annotation.Transactional;

Expand All @@ -25,8 +26,8 @@ public String getDomainClassName() {
public ArrayList<T> findAll() {
getSessionFactory().getStatistics().logSummary();
String query = "from " + getDomainClassName() + " do";
org.hibernate.Query q = getCurrentSession().createQuery(query);
return (ArrayList<T>) q.list();
Query<T> q = getCurrentSession().createQuery(query);
return new ArrayList<T>(q.list());
}

@Transactional
Expand All @@ -41,16 +42,15 @@ public Serializable save(T domainObject) {
getSessionFactory().getStatistics().logSummary();
Serializable id = getCurrentSession().save(domainObject);
return id;
}


}

@SuppressWarnings("unchecked")
@Transactional
public T findByColumnName(Object id,String key) {
String query = "from " + getDomainClassName() + " do where do."+key +"= ?";
org.hibernate.Query q = getCurrentSession().createQuery(query);
q.setParameter(0, id);
return (T) q.uniqueResult();
String query = "from " + getDomainClassName() + " do where do."+key +"= :id";
Query<T> q = getCurrentSession().createQuery(query);
q.setParameter("id", id);
return q.uniqueResult();
}

public Long count() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

import org.akaza.openclinica.domain.datamap.StudyUserRole;
import org.akaza.openclinica.domain.user.UserAccount;
import org.hibernate.query.Query;

public class StudyUserRoleDao extends CompositeIdAbstractDomainDao<StudyUserRole> {

Expand All @@ -16,11 +17,11 @@ public Class<StudyUserRole> domainClass() {
public ArrayList<StudyUserRole> findAllUserRolesByUserAccount(UserAccount userAccount, int studyId, int parentStudyId) {
String query = "from " + getDomainClassName()
+ " where user_name=:username AND status_id=1 AND ( study_id=:studyId OR study_id=:parentStudyId) ";
org.hibernate.Query q = getCurrentSession().createQuery(query);
Query<StudyUserRole> q = getCurrentSession().createQuery(query);
q.setParameter("username", userAccount.getUserName());
q.setInteger("studyId", studyId);
q.setInteger("parentStudyId", parentStudyId);
return (ArrayList<StudyUserRole>) q.list();
q.setParameter("studyId", studyId);
q.setParameter("parentStudyId", parentStudyId);
return new ArrayList<StudyUserRole>(q.list());
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public class CrfVersion extends DataMapDomainObject {
private List<Section> sections;
private List<EventDefinitionCrf> eventDefinitionCrfs;
private Set decisionConditions = new HashSet(0);
private Set<ItemGroupMetadata> itemGroupMetadatas;;
private Set<ItemGroupMetadata> itemGroupMetadatas;

public CrfVersion() {
}
Expand Down Expand Up @@ -211,7 +211,7 @@ public void setXform(String xform) {
this.xform = xform;
}

@Column(name = "xformName")
@Column(name = "xform_name")
public String getXformName() {
return xformName;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@
@Entity
@Table(name = "rule_set_rule")
@GenericGenerator(name = "id-generator", strategy = "native", parameters = { @Parameter(name = "sequence_name", value = "rule_set_rule_id_seq") })
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
public class RuleSetRuleBean extends AbstractAuditableMutableDomainObject implements Serializable {

RuleSetBean ruleSetBean;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ public class XsltTransformJob extends QuartzJobBean {
private AuditEventDAO auditEventDAO;
private DatasetDAO datasetDao;

private final TransformerFactory transformerFactory = TransformerFactory.newInstance();
private final TransformerFactory transformerFactory = new net.sf.saxon.TransformerFactoryImpl();

// POST PROCESSING VARIABLES
public static final String POST_PROC_DELETE_OLD = "postProcDeleteOld";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<validCheckSum>30d56b8377711e93debdac333aa217d</validCheckSum>
<preConditions onFail="MARK_RAN">
<dbms type="postgresql" />
<sqlCheck expectedResult="t"> <![CDATA[select substring(replace((string_to_array(version(), ' '))[2],'.','')from 1 for 2)::integer < 90 ]]></sqlCheck>
<sqlCheck expectedResult="t"> <![CDATA[select current_setting('server_version_num')::integer < 90000 ]]></sqlCheck>
</preConditions>
<sql splitStatements="false">
DROP LANGUAGE IF EXISTS plpgsql;
Expand Down
47 changes: 47 additions & 0 deletions core/src/main/resources/migration/lc-1.0.0/update_to_spring5.xml
Original file line number Diff line number Diff line change
Expand Up @@ -67,4 +67,51 @@
</column>
</addColumn>
</changeSet>
<changeSet author="cha" id="1555001321719-11">
<addColumn tableName="oc_qrtz_job_details">
<column name="is_nonconcurrent" type="boolean"></column>
</addColumn>
</changeSet>
<changeSet author="cha" id="1555001321719-12">
<addColumn tableName="oc_qrtz_job_details">
<column name="is_update_data" type="boolean"></column>
</addColumn>
</changeSet>
<changeSet author="cha" id="1555001321719-13">
<addColumn tableName="oc_qrtz_fired_triggers">
<column name="is_nonconcurrent" type="boolean"></column>
</addColumn>
</changeSet>
<changeSet author="cha" id="1555001321719-14">
<addColumn tableName="oc_qrtz_fired_triggers">
<column name="is_update_data" type="boolean"></column>
</addColumn>
</changeSet>
<changeSet author="cha" id="1555001321719-15">
<addColumn tableName="oc_qrtz_fired_triggers">
<column name="sched_time" type="BIGINT">
<constraints nullable="false"/>
</column>
</addColumn>
</changeSet>
<changeSet author="cha" id="1555001321719-16">
<dropColumn tableName="oc_qrtz_job_details">
<column name="is_volatile"/>
</dropColumn>
</changeSet>
<changeSet author="cha" id="1555001321719-17">
<dropColumn tableName="oc_qrtz_job_details">
<column name="is_stateful"/>
</dropColumn>
</changeSet>
<changeSet author="cha" id="1555001321719-18">
<dropColumn tableName="oc_qrtz_fired_triggers">
<column name="is_volatile"/>
</dropColumn>
</changeSet>
<changeSet author="cha" id="1555001321719-19">
<dropColumn tableName="oc_qrtz_triggers">
<column name="is_volatile"/>
</dropColumn>
</changeSet>
</databaseChangeLog>
Loading