Hugo G
Hugo G

Reputation: 16496

Why does the Jenkins API have packages for jenkins and hudson?

I'm trying to get into Groovy scripting in Jenkins, but there seems to be no docs about this and the API is kind of split between package hudson and jenkins. I understand that Hudson is Jenkins' former name, and my first guess is that the devs didn't rename the old packages, but used the new name for newer code - effectively creating a mess. Is this true or am I missing something?

Upvotes: 0

Views: 61

Answers (1)

dildeepak
dildeepak

Reputation: 1389

You are somewhat right. Jenkins originated from Hudson , so left the old packages and classes as it is for 2 of the obvious reasons:

  1. To support the old legacy classes and codes written/used all over world. Other wise it would be difficult for every developer to either change or use something like @deprecated @SuppressWarnings
  2. It will take more time to change/restructure all the classes for Jenkins. Even Huge Java community also avoid such things and they only restructure the code when it requires the most. Like they did in Dictionary or Vector classes or even Collections framework during generics implementions.

You can also refer this page for some more answers: How to choose between Hudson and Jenkins?

Upvotes: 1

Related Questions