timja / jenkins-gh-issues-poc-06-18

0 stars 0 forks source link

[JENKINS-54571] Problem with jcasc compatibility plugin and job priority in Jenkins #4107

Open timja opened 5 years ago

timja commented 5 years ago

Hi, 
I am trying to use configuration as code Jenkins plugin and I have problems with custom plugins.
 
I am trying to import these two configs:

'1.1' encoding='UTF-8'?>
"PrioritySorter@3.6.0">
  "linked-list">
    
      0
      -1
      "jenkins.advancedqueue.jobinclusion.strategy.ViewBasedJobInclusionStrategy">
All
false
.*
      
      
      false
      false
      .*
      true
      

  0
  "jenkins.advancedqueue.priority.strategy.BuildParameterStrategy">
    PRIORITY
  

      
    
  
 

and

'1.1' encoding='UTF-8'?>
"PrioritySorter@3.6.0">
  true
  true
  "jenkins.advancedqueue.sorter.strategy.AbsoluteStrategy">
    5
    3
  
 

 
but I am keep getting these kind of errors: 

 Caused by: io.jenkins.plugins.casc.ConfiguratorException: Invalid configuration elements for type class jenkins.advancedqueue.PrioritySorterConfiguration : allowpriorityonjobs.

 
I am trying to import this: 

unclassified:
  prioritysorterconfiguration:
    allowpriorityonjobs: true 

 
I have no clues how to write custom configurator, how to make current one to work and does that makes sense since this does not work out of the box and error does not tell which properties are supported. I am assuming that I might need to change to source code. 
 
Any hints are more than welcome. Thank you in advance. 
 
Best,
Ljubisa. 


Originally reported by ljubisap, imported from: Problem with jcasc compatibility plugin and job priority in Jenkins
  • assignee: fr123k
  • status: In Progress
  • priority: Major
  • resolution: Unresolved
  • imported: 2022/01/10
timja commented 5 years ago

ctran:

ljubisap: were you able to figure this out?

timja commented 5 years ago

ljubisap:

ctran No. We moved back from using this approach since it was not mature enough. 

timja commented 5 years ago

ctran:

Yeah, I was afraid you were going to say that.  That's a shame jcasc can't handle everything.

Thanks for the reply.

timja commented 3 years ago

fr123k:

Now it's time to give it a next try maybe.

Checkout the following github PR https://github.com/jenkinsci/priority-sorter-plugin/pull/62.