Robin
Robin

Reputation: 1746

Cannot resolve 'setCasServerUrlPrefix' in 'SingleSignOutFilter'

After a recent upgrade of a Spring Boot application that relies on CAS for authentication, the project no longer compiles due to the fact that the setCasServerUrlPrefix method can't be found on SingleSignOutFilter:

java: cannot find symbol
  symbol:   method setCasServerUrlPrefix(java.lang.String)
  location: variable singleSignOutFilter of type org.jasig.cas.client.session.SingleSignOutFilter

The involved code is:

@Bean
public SingleSignOutFilter singleSignOutFilter() {
    SingleSignOutFilter singleSignOutFilter = new SingleSignOutFilter();
    singleSignOutFilter.setCasServerUrlPrefix("...");
    singleSignOutFilter.setIgnoreInitConfiguration(true);

    return singleSignOutFilter;
}

How to update the code to still set this value even though the setter doesn't exist anymore?

Upvotes: 5

Views: 1348

Answers (1)

Robin
Robin

Reputation: 1746

It looks like this method has been removed since cas-client 3.6.0 (reference commit) as it was not used internally so calling setCasServerUrlPrefix is no longer needed.

Not really semantic-version-friendly as there were no deprecation cycle and this change is introduced in a point release but at least, it is safe to remove from your code base.

Upvotes: 5

Related Questions