Results 1 to 3 of 3

Thread: [JobOperator] Odd way to retrieve JobParameters

  1. #1
    Join Date
    Jun 2008
    Posts
    11

    Default [JobOperator] Odd way to retrieve JobParameters

    Hi,

    Well i'll go directly to the thing confusing me.

    Following the database model, the jobParameters are associated to the JobInstanceId, which actually is correct in terms that if a parameter is changed a new instance is created of the named job.

    But on the JobOperator interface things turn on to be complicated, to retrieve jobParameters we must provide the executionId and not the instanceId. Which leads to a retrieval of duplicate params and unnecessary processing...

    Someone can please explain to me why is it not possible to retrieve the parameters directly by the instanceId? since the inner executions of a given instance will always lead to the same list of parameters?

    Cheers,
    Hassane

  2. #2
    Join Date
    Jun 2005
    Posts
    4,231

    Default

    I'm not 100% clear what you need to do. You can find a JobInstance by id from the JobExplorer, or use JobRepository to locate one by name and parameters (via the last execution). Is that not enough?

  3. #3
    Join Date
    Jun 2008
    Posts
    11

    Default

    Yep actually that was enough, i have created my own jobOperator to meet my needs by using the JobRepository, JobExplorer and even the SimpleJobOperator.

    Well my question about retrieving parameters was that in the SimpleJobOperator, the method getParameters receives a jobExecutionId while it's working with the jobInstanceId.
    So if someone needs to access the parameters of a JobInstance they need to lookup for its executions... just so that the getParameters lookup again for the jobInstanceId... and this feels like going down-and-up for no added value :/

    well, im talking on the basis of my needs since i wanted to access the parameters from the instance level.

    But in the end, your suggestion of re-using the JobExplorer and JobOperator was helpfull.

    Thanks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •