Changeset 670:7928f08e0c01

Show
Ignore:
Timestamp:
10/11/07 16:09:25 (1 year ago)
Author:
Greg Von Kuster <greg@bx.psu.edu>
branch:
default
convert_revision:
svn:9bcadc22-80f8-0310-8a53-c8f022958886/galaxy/trunk@2011
Message:

Initial fix for concurrent update db issue (still using psycopg). Commented out "job requeued" log statement. Changed error reporting email in config.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • lib/galaxy/jobs/__init__.py

    r636 r670  
    135135                if job_state == JOB_WAIT:  
    136136                    new_waiting.append( job ) 
    137                     log.debug( "job has been requeued" ) 
     137                    #log.debug( "job has been requeued" ) 
    138138                elif job_state == JOB_ERROR: 
    139139                    log.info( "job %d ended with an error" %job.job_id ) 
  • lib/galaxy/model/mapping.py

    r657 r670  
    33are encapsulated here.  
    44""" 
     5import logging 
     6log = logging.getLogger( __name__ ) 
    57 
    68import pkg_resources 
     
    253255            if table.columns.has_key( "update_time" ): 
    254256                table.columns['update_time'].type = TIMESTAMP() 
    255                 table.columns['update_time'].type = TIMESTAMP() 
    256     # Connect the metadata the database.  
    257     metadata.connect( url, **kwargs ) 
     257    # Connect the metadata to the database.  
     258    if url.find( "sqlite" ) < 0 and url.find( '///' ) >= 0: 
     259        import psycopg 
     260        try: 
     261            dbconn = url.split('///') 
     262            dbtype = dbconn[0] 
     263            dbname = dbconn[1] 
     264            def connect(): 
     265                connection = psycopg.connect( 'dbname=%s' %dbname ) 
     266                connection.set_isolation_level(1) 
     267                return connection 
     268            engine = create_engine('%s///' %dbtype, creator=connect) 
     269            metadata.connect( engine ) 
     270        except: 
     271            log.exception( "error connecting to database using connection: '%s'." % url ) 
     272            metadata.connect( url, **kwargs ) 
     273    else: 
     274        metadata.connect( url, **kwargs ) 
    258275    ## metadata.engine.echo = True 
    259276    # Create tables if needed 
  • test/functional/test_history_functions.py

    r663 r670  
    88        self.history_options() 
    99        self.check_page_for_string( 'logged in</a> to store or switch histories.' ) 
    10         self.login( email='test2@bx.psu.edu' ) #Just to make sure we hav created this account since it is used to share histories 
     10        self.login( email='test2@bx.psu.edu' ) #Just to make sure we have created this account since it is used to share histories 
    1111        self.logout() 
    1212    def test_05_new_history_then_delete( self ): 
  • universe_wsgi.ini.sample

    r640 r670  
    8181# Mail 
    8282smtp_server = coltrane.bx.psu.edu 
    83 error_email_to = james@bx.psu.edu 
     83error_email_to = galaxy_bugs@bx.psu.edu 
    8484 
    8585# Use the new iframe / javascript based layout