Spring Boot + Jasypt не удается собрать - PullRequest
0 голосов
/ 17 сентября 2018

всем!

В моем приложении Spring Boot я использую Jasypt для работы с зашифрованными свойствами.Но сегодня моя сборка завершилась с ошибкой:

Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.security.crypto.encrypt.TextEncryptor]: Factory method 'textEncryptor' threw exception; nested exception is java.lang.NullPointerException
    at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:185) ~[spring-beans-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:582) ~[spring-beans-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    ... 69 common frames omitted
Caused by: java.lang.NullPointerException: null
    at org.springframework.cloud.context.encrypt.EncryptorFactory.create(EncryptorFactory.java:51) ~[spring-cloud-context-2.0.0.RELEASE.jar:2.0.0.RELEASE]
    at org.springframework.cloud.bootstrap.encrypt.EncryptionBootstrapConfiguration$RsaEncryptionConfiguration.textEncryptor(EncryptionBootstrapConfiguration.java:83) ~[spring-cloud-context-2.0.0.RELEASE.jar:2.0.0.RELEASE]
    at org.springframework.cloud.bootstrap.encrypt.EncryptionBootstrapConfiguration$RsaEncryptionConfiguration$$EnhancerBySpringCGLIB$$80fb9d1d.CGLIB$textEncryptor$0(<generated>) ~[spring-cloud-context-2.0.0.RELEASE.jar:2.0.0.RELEASE]

Что интересно, она не работает только на моей машине.Мои коллеги извлекают из CVS и делают mvn clean install без проблем.

Мы используем эту версию Jasypt

    <dependency>
        <groupId>com.github.ulisesbocchio</groupId>
        <artifactId>jasypt-spring-boot-starter</artifactId>
        <version>2.1.0</version>
    </dependency>

Когда я переключаюсь на более старую версию, такую ​​как 1.16, все работает нормально.Может кто-нибудь сказать мне, что происходит?

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...