PSU Presentation

Jump to: navigation, search

This Wiki page is an edited version of Chinmay's presentation.

Sanger Pathogen Sequencing Unit (PSU)
  • GeneDB is the organism data and annotation database for the Pathogen Sequencing Unit (PSU) at the Sanger Institute, UK
  • Contains 37 organisms, which is expected to grow to 62
  • Artemis is an annotation/DNA graphical interface
  • PSU is currently migrating to chado schema
  • We've implemented a common interface with the two leading open source frameworks: Hibernate and iBatis
Technical - Connections

Connections for the Hibernate engine are configured in the Spring configuration file

<bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource">
               <property name="driverClassName" value="org.postgresql.Driver" />
               <property name="url" value="jdbc:postgresql://" />
               <property name="username" value="DELIBERATELY_BOGUS_NAME"/>
               <property name="password" value="WIBBLE" />
  • Uses a connection pool
  • Connection to the database is specified graphically, so the iBatis configuration file has variables for the location:
<property name="JDBC.Driver" value="org.postgresql.Driver"/>
<property name="JDBC.ConnectionURL” value="jdbc:postgresql://${chado}"/>
<property name="JDBC.Username" value="${username}"/>
<property name="JDBC.Password" value="${password}"/>
  • provide database location, username & password
  • select from scrollable list of feature with residues (organisms in separate Postgres schemas) what to open in Artemis
Technical - Code Generation
  • The shared interface and hibernate implementation were originally generated
  • There’s no explicit code generation (although the Spring and Hibernate runtimes may use them behinds the scenes)
Technical - Transactions
  • Transactions are fully supported
Problems 1, 2, & 3

Creating a gene

genes[0] = new Feature(ORG, GENE, "xfile", false, false, now, now);
FeatureLoc loc = new FeatureLoc(SOURCE_FEATURE, genes[0], 13691, false, 14720, false, (short)1, 0, 0 ,0);
addFeatureProp(genes[0], "description", "A test gene for GMOD meeting");
addSynonymsToFeature(genes[0], "mulder", "scully");
createExon("exon1", genes[0], 13691, 13767, now, 0);
createExon("exon2", genes[0], 14687, 14720, now, 1);

Retrieve a gene

Feature f = sequenceDao.getFeatureByUniqueName("xfile");

Update a gene


private Feature createExon(String name, Feature gene, int min, int max, Timestamp now, int rank) {
        Feature exon = new Feature(ORG, EXON, name, false, false, now, now);
        FeatureLoc loc = new FeatureLoc(SOURCE_FEATURE, exon, min, false, max, false,
                                      (short)1, 0, 0 ,0);
        return exon;
Demo – Sample Problem

Simple web page to demonstrate displaying a basic feature

<st:section name="Naming" id="gene_naming" collapsed="false" collapsible="false"
  <db:synonym name="synonym" var="name" collection="${feature.featureSynonyms}">
    <br /><b>Synonym:</b> <db:list-string collection="${name}" />
<st:section name="Exons" collapsed="false" collapsible="true" hideIfEmpty="true">
            <display:table name="exons" uid="tmp" pagesize="30" class="simple" cellspacing="0"
                 <display:column property="uniqueName" title="Exon"/>
                 <display:column property="featureLocsForSrcFeatureId.fmin" title="Start"/>
                 <display:column property="featureLocsForSrcFeatureId.fmax" title="end"/>
<st:section name="cds" collapsible="true">