We have a large number of Pentaho transformations that are currently
deployed using Springboot executable jar files. We plan to convert the
existing Pentaho transformations  to Hop pipelines and have similar
Springboot deployments.

When I try to embed Hop pipelines in a Springboot application and run a
pipeline using the Springboot executable jar file I get the following error
message (also attached the logs).










*org.apache.hop.core.exception.HopException: Unable to find plugin with ID
'Hop' at org.apache.hop.core.encryption.Encr.init(Encr.java:47) at
org.apache.hop.core.HopClientEnvironment.init(HopClientEnvironment.java:120)
at
org.apache.hop.core.HopClientEnvironment.init(HopClientEnvironment.java:76)
at org.apache.hop.core.HopEnvironment.init(HopEnvironment.java:114)*


 I, however, am able to run the same code in an IDE or using mvn
spring-boot:run. It looks like a class loading issue that I am not able to
figure out and I am sure someone might be able to provide some guidance. I
am attaching the example I used (JDK 17, Hop 2.9.0).


I really appreciate your help.

Regards
RG
{\rtf1\ansi\ansicpg1252\cocoartf2513
\cocoatextscaling0\cocoaplatform0{\fonttbl\f0\froman\fcharset0 Times-Roman;}
{\colortbl;\red255\green255\blue255;\red0\green0\blue0;}
{\*\expandedcolortbl;;\cssrgb\c0\c0\c0;}
\margl1440\margr1440\vieww10800\viewh8400\viewkind0
\deftab720
\pard\pardeftab720\partightenfactor0

\f0\fs24 \cf2 \expnd0\expndtw0\kerning0
\outl0\strokewidth0 \strokec2 Users-MacBook-Pro-2:SampleHopApp User$ java -jar 
target/hopapp-1.0.0.jar \
SLF4J: Class path contains multiple SLF4J providers.\
SLF4J: Found provider 
[ch.qos.logback.classic.spi.LogbackServiceProvider@2ef1e4fa]\
SLF4J: Found provider [org.slf4j.nop.NOPServiceProvider@306a30c7]\
SLF4J: See https://www.slf4j.org/codes.html#multiple_bindings for an 
explanation.\
SLF4J: Actual provider is of type 
[ch.qos.logback.classic.spi.LogbackServiceProvider@2ef1e4fa]\
\
  .   ____          _            __ _ _\
 /\\\\ / ___'_ __ _ _(_)_ __  __ _ \\ \\ \\ \\\
( ( )\\___ | '_ | '_| | '_ \\/ _` | \\ \\ \\ \\\
 \\\\/  ___)| |_)| | | | | || (_| |  ) ) ) )\
  '  |____| .__|_| |_|_| |_\\__, | / / / /\
 =========|_|==============|___/=/_/_/_/\
 :: Spring Boot ::                (v3.0.0)\
\
Hop configuration file not found, not serializing: 
/Users/User/Desktop/SampleHopApp/config/hop-config.json\
org.apache.hop.core.exception.HopException: \
Unable to find plugin with ID 'Hop'\
\
        at org.apache.hop.core.encryption.Encr.init(Encr.java:47)\
        at 
org.apache.hop.core.HopClientEnvironment.init(HopClientEnvironment.java:120)\
        at 
org.apache.hop.core.HopClientEnvironment.init(HopClientEnvironment.java:76)\
        at org.apache.hop.core.HopEnvironment.init(HopEnvironment.java:114)\
        at org.apache.hop.core.HopEnvironment.init(HopEnvironment.java:77)\
        at com.example.hopapp.HopApplication.run(HopApplication.java:34)\
        at 
org.springframework.boot.SpringApplication.callRunner(SpringApplication.java:767)\
        at 
org.springframework.boot.SpringApplication.callRunners(SpringApplication.java:751)\
        at 
org.springframework.boot.SpringApplication.run(SpringApplication.java:315)\
        at 
org.springframework.boot.SpringApplication.run(SpringApplication.java:1302)\
        at 
org.springframework.boot.SpringApplication.run(SpringApplication.java:1291)\
        at com.example.hopapp.HopApplication.main(HopApplication.java:27)\
        at 
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\
        at 
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)\
        at 
java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\
        at java.base/java.lang.reflect.Method.invoke(Method.java:568)\
        at 
org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:49)\
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:95)\
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:58)\
        at 
org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:65)\
}
{\rtf1\ansi\ansicpg1252\cocoartf2513
\cocoatextscaling0\cocoaplatform0{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
{\colortbl;\red255\green255\blue255;}
{\*\expandedcolortbl;;}
\margl1440\margr1440\vieww10800\viewh8400\viewkind0
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\pardirnatural\partightenfactor0

\f0\fs24 \cf0 Users-MacBook-Pro-2:SampleHopApp User$ mvn spring-boot:run\
[INFO] Scanning for projects...\
[INFO] \
[INFO] -------------------------< com.example:hopapp >-------------------------\
[INFO] Building Apache Hop Spring Boot App 1.0.0\
[INFO] --------------------------------[ jar ]---------------------------------\
[INFO] \
[INFO] >>> spring-boot-maven-plugin:3.0.0:run (default-cli) > test-compile @ 
hopapp >>>\
[INFO] \
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ hopapp 
---\
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, 
i.e. build is platform dependent!\
[INFO] skip non existing resourceDirectory 
/Users/User/Desktop/SampleHopApp/src/main/resources\
[INFO] \
[INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) @ hopapp ---\
[INFO] Nothing to compile - all classes are up to date\
[INFO] \
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ 
hopapp ---\
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, 
i.e. build is platform dependent!\
[INFO] skip non existing resourceDirectory 
/Users/User/Desktop/SampleHopApp/src/test/resources\
[INFO] \
[INFO] --- maven-compiler-plugin:3.8.1:testCompile (default-testCompile) @ 
hopapp ---\
[INFO] No sources to compile\
[INFO] \
[INFO] <<< spring-boot-maven-plugin:3.0.0:run (default-cli) < test-compile @ 
hopapp <<<\
[INFO] \
[INFO] \
[INFO] --- spring-boot-maven-plugin:3.0.0:run (default-cli) @ hopapp ---\
[INFO] Attaching agents: []\
SLF4J: Class path contains multiple SLF4J providers.\
SLF4J: Found provider 
[ch.qos.logback.classic.spi.LogbackServiceProvider@5aaa6d82]\
SLF4J: Found provider [org.slf4j.nop.NOPServiceProvider@73a28541]\
SLF4J: See https://www.slf4j.org/codes.html#multiple_bindings for an 
explanation.\
SLF4J: Actual provider is of type 
[ch.qos.logback.classic.spi.LogbackServiceProvider@5aaa6d82]\
\
  .   ____          _            __ _ _\
 /\\\\ / ___'_ __ _ _(_)_ __  __ _ \\ \\ \\ \\\
( ( )\\___ | '_ | '_| | '_ \\/ _` | \\ \\ \\ \\\
 \\\\/  ___)| |_)| | | | | || (_| |  ) ) ) )\
  '  |____| .__|_| |_|_| |_\\__, | / / / /\
 =========|_|==============|___/=/_/_/_/\
 :: Spring Boot ::                (v3.0.0)\
\
Hop configuration file not found, not serializing: 
/Users/User/Desktop/SampleHopApp/config/hop-config.json\
2025/02/09 19:22:50 - add-constants - Executing this pipeline using the Local 
Pipeline Engine with run configuration 'local'\
2025/02/09 19:22:50 - add-constants - Execution started for pipeline 
[add-constants]\
2025/02/09 19:22:55 - generate 1 row.0 - Finished processing (I=0, O=0, R=0, 
W=1, U=0, E=0)\
2025/02/09 19:22:55 - add constants.0 - Finished processing (I=0, O=0, R=1, 
W=1, U=0, E=0)\
Pipeline executed successfully\
2025/02/09 19:22:55 - add-constants - Execution finished on a local pipeline 
engine with run configuration 'local'\
[INFO] ------------------------------------------------------------------------\
[INFO] BUILD SUCCESS\
[INFO] ------------------------------------------------------------------------\
[INFO] Total time: 11.407 s\
[INFO] Finished at: 2025-02-09T19:22:55-05:00\
[INFO] ------------------------------------------------------------------------}

<<attachment: HopSpringBootSample.zip>>

Reply via email to