Search Results

Search found 2 results on 1 pages for 'edijs'.

Page 1/1 | 1 

  • TeamCity swap configuration files

    - by Edijs
    Hi! I have been using CC.NET for a while and decided to try Team City. The initial and default configuration is very easy, but how do I swap configuration files after code is checked out and before unit tests are run. I am using TFS, NUnit. 1. When working locally I have configuration file pointing to local server. 2. On the build server TeamCity get's notification that I have checked-in code and builds new version. 3. Server runs unit tests When on 3rd step server runs unit tests I need to swap configuration files that are pointing to other servers, not the ones I am using locally. How do you accomplish this task in TeamCity? Thanks, Edijs

    Read the article

  • Ruby and Rails Async

    - by Edijs Petersons
    I need to perform long-running operation in ruby/rails asynchronously. Googling around one of the options I find is Sidekiq. class WeeklyReportWorker include Sidekiq::Worker def perform(user, product, year = Time.now.year, week = Date.today.cweek) report = WeeklyReport.build(user, product, year, week) report.save end end # call WeeklyReportWorker.perform_async('user', 'product') Everything works great! But there is a problem. If I keep calling this async method every few seconds, but the actual time heavy operation performs is one minute things won't work. Let me put it in example. 5.times { WeeklyReportWorker.perform_async('user', 'product') } Now my heavy operation will be performed 5 times. Optimally it should have performed only once or twice depending on whether execution of first operaton started before 5th async call was made. Do you have tips how to solve it?

    Read the article

1