jobs

How to set to a QUARTZ JOB to start only when an another JOB finished, stopped?

时光怂恿深爱的人放手 提交于 2019-12-05 11:51:19
问题 I have a QUARTZ JOB which is starts every 10 minutes. If a JOB doesn't finish in 10 minutes, in the next 10th minute another JOB will start. What I want is: the next JOB (after every 10 minute) should start only, if the previous JOB has finished running. Is there any way to do it? 回答1: Quartz Documentation @DisallowConcurrentExecution is an annotation that can be added to the Job class that tells Quartz not to execute multiple instances of a given job definition (that refers to the given job

Jenkins delete builds older than latest 20 builds for all jobs

十年热恋 提交于 2019-12-05 08:17:20
I am in the process of cleaning up Jenkins (it was setup incorrectly) and I need to delete builds that are older than the latest 20 builds for every job. Is there any way to automate this using a script or something? I found many solutions to delete certain builds for specific jobs, but I can't seem to find anything for all jobs at once. Any help is much appreciated. Dave Bacher You can use the Jenkins Script Console to iterate through all jobs, get a list of the N most recent and perform some action on the others. import jenkins.model.Jenkins import hudson.model.Job MAX_BUILDS = 20 for (job

How to schedule Pentaho Kettle transformations?

自闭症网瘾萝莉.ら 提交于 2019-12-05 07:34:31
问题 I've set up four transformations in Kettle. Now, I would like to schedule them so that they will run daily at a certain time and one after the another. For example, tranformation1 -> transformation2 -> transformation3 -> transformation4 should run daily at 8.00 am. How can I do that? 回答1: You can execute transformation from the command line using the tool Pan: Pan.bat /file:transform.ktr /param:name=value The syntax might be different depending on your system - check out the link above for

Multiple delayed job processes starting same job

耗尽温柔 提交于 2019-12-05 05:19:52
I'm using delayed job in a setup where I run multiple workers. For the sake of my question, it doesn't really matter, but let's say I run 10 workers (doing that in development mode currently). The problem I am having is that two different workers sometimes start working on the same job, calling the perform method on my job object. To the best of my understanding Delayed Job is using pessimistic locking to prevent this from happening, but it seems it sometimes still have enough time to lock steal the job before the first worker has time to actually lock it. I'm just asking to see if anyone else

Sidekiq retry count in job

别来无恙 提交于 2019-12-05 01:15:18
Is there a way to get the retry count for the current job? I want the job to stop, not crash, after x retries. I would like to ask the retry count in the perform method so I could simply return if the retry count equals x. def perform(args) return if retry_count > 5 ... end Using Sidekiq 2.12. Edit I (not the OP) have the same question but for a different reason. If the job is being retried I want to do additional sanity checking to make sure the job is needed and to quit retrying if it is no longer expected to succeed because something external changed since it was queued. So, is there a way

Android JobScheduler onStartJob called multiple times

ε祈祈猫儿з 提交于 2019-12-05 00:55:53
The JobScheduler calls onStartJob() multiple times, although the job finished. Everything works fine, if I schedule one single job and wait until it has finished. However, if I schedule two or more jobs with different IDs at the same time, then onStartJob() is called again after invoking jobFinished() . For example I schedule job 1 and job 2 with exactly the same parameters except the ID, then the order is: onStartJob() for job 1 and job 2 Both jobs finish, so jobFinished() is invoked for both of them After that onStartJob() is called again for both jobs with the same ID My job is very basic

How to be notified when a script's background job completes?

我的梦境 提交于 2019-12-04 20:48:48
My question is very similar to this one except that my background process was started from a script. I could be doing something wrong but when I try this simple example: #!/bin/bash set -mb # enable job control and notification sleep 5 & I never receive notification when the sleep background command finishes. However, if I execute the same directly in the terminal, $ set -mb $ sleep 5 & $ [1]+ Done sleep 5 I see the output that I expect. I'm using bash on cygwin. I'm guessing that it might have something to do with where the output is directed, but trying various output redirection, I'm not

hadoop job tracker cannot start up

 ̄綄美尐妖づ 提交于 2019-12-04 17:44:23
Under the Single Node Setup I try to run a single node example The jobtracker start however fails with exception : 2013-04-30 17:12:54,984 INFO org.apache.hadoop.metrics2.impl.MetricsConfig: loaded properties from hadoop-metrics2.properties 2013-04-30 17:12:54,994 INFO org.apache.hadoop.metrics2.impl.MetricsSourceAdapter: MBean for source MetricsSystem,sub=Stats registered. 2013-04-30 17:12:54,995 INFO org.apache.hadoop.metrics2.impl.MetricsSystemImpl: Scheduled snapshot period at 10 second(s). 2013-04-30 17:12:54,995 INFO org.apache.hadoop.metrics2.impl.MetricsSystemImpl: JobTracker metrics

How to make the client download a very large file that is genereted on the fly

无人久伴 提交于 2019-12-04 13:43:56
问题 I have an export function that read the entire database and create a .xls file with all the records. Then the file is sent to the client. Of course, the time of export the full database requires a lot of time and the request will soon end in a timeout error. What is the best solution to handle this case? I heard something about making a queue with Redis for example but this will require two requests: one for starting the job that will generate the file and the second to download the generated

Online Job Portal System Use Case Diagrams

好久不见. 提交于 2019-12-04 13:21:46
问题 I want to have a correct use case diagram for an online job portal system. Here is my attemp: I have some doubts: I can't see where making "Login" use case witch is an important use case for this system. This use case diagram is not showing the difference between a simple visitor and a registered one. The former could view vacancies, view advice without the obligation for having an account. The latter could view vacancies, view advice, upload CV (after be logged), apply for a job (after be