Mentions légales du service

Skip to content
Snippets Groups Projects
  1. Sep 03, 2014
  2. Aug 26, 2014
    • Stéphane Martin's avatar
      [Kadeploy3d] Bugfix: Use thread context instead of trap context for kill... · 5ba494e2
      Stéphane Martin authored
      [Kadeploy3d] Bugfix: Use thread context instead of trap context for kill kadeploy for INT and TERM with ruby >=2.0.
      
      Since ruby 2.0, it is forbiden to take a lock or synchronize inside trap context.
      To resolve this issue, this patch adds thread inside trap and uses the thread context.
      
      Try this code with thread arguement or not in different ruby version:
      $mumu = Mutex.new
      def fault()
        begin
          $mumu.synchronize do
            puts "int"
          end
        rescue Exception => ex
           puts ex
           puts ex.backtrace
        end
      end
      
      def thread_fault()
        t=Thread.new do
          fault()
        end
        t.join
      end
      
      if ARGV[0] == 'thread'
        Signal::trap("INT") do
          thread_fault()
        end
      else
        Signal::trap("INT") do
          fault()
        end
      end
      
      Process.kill("INT",$$)
      
      Change-Id: I4959d8d45ba74bb6b1452dac7c985daf619b9b02
      5ba494e2
    • Stéphane Martin's avatar
      [Kadeploy3d] Fix the USR1 signal for ruby >= 2.0 · 5d56a176
      Stéphane Martin authored
      Since ruby 2.0, the signal trap has special context.
      This patch add a Thread to resolve this issue.
      
      Change-Id: I365a4ff686a38600dbdc40e3d0db23e0ad1c25de
      5d56a176
    • Stéphane Martin's avatar
      [DB] Merge disconnect function into free function. · 81a56f5c
      Stéphane Martin authored
      Before this patch, the end of database connection must be made in two times:
      disconnect and free. The issue is that kaworkflow calls free without
      disconnect.
      
      Now free function closes the SQL connection if a connection was established
      and disconnect function is deleted. This resolves the kaworkflow issue.
      
      Note for developers:
      
      Kadeploy establishes one SQL connexion on each action (in fact, each connexion
      to server, it can be avoided for the polling if workflow keeps the user right
      only for the polling).  When a workflow is created, a second SQL connection is
      established because the workflow has longer life than execution context.
      
      My opinion is to made only one connection for everything. I was tested with the
      modification of file server.rb: check_database establishes the SQL connection
      and database_handler return the connection. It works fine with concurrency.
      But EJ said that the MySQL module has weird behavior after one week of running.
      
      Change-Id: I2b1610890aded0b538fade4a3fc386857b777127
      81a56f5c
    • JEANVOINE Emmanuel's avatar
  3. Aug 25, 2014
  4. Aug 19, 2014
    • Stéphane Martin's avatar
      [Client] Append the result files instead of overwrite it. · 0ef5e97f
      Stéphane Martin authored
      When the client is called with multi-site the result function will be called
      many times.  But the result files are opened with w+ and it overwrite the file.
      
      This patch use a+ to append the file.  The file will be reseted on argument
      parsing inside the load_outputfile function.
      
      Change-Id: I4aaf313013631a9b1aa6fe90f2369924fa5bbd4a
      0ef5e97f
  5. Aug 13, 2014
  6. Aug 12, 2014
  7. Aug 08, 2014
  8. Aug 07, 2014
Loading