vladmihalcea / hypersistence-optimizer

Hypersistence Optimizer allows you to get the most out of JPA and Hibernate. By scanning your application configuration and mappings, Hypersistence Optimizer can tell you what changes you need to do to speed up your data access layer.
https://vladmihalcea.com/hypersistence-optimizer/
Apache License 2.0
318 stars 43 forks source link

HypersistenceOptimizer: Symbol not found #180

Closed AlexanderNZ closed 2 years ago

AlexanderNZ commented 2 years ago

Hi All,

I'm having trouble installing the trial for hypersistence optimizer. I want to roll it out in my org but also want a bit more detail before buying.

Here's what I've done:

❯ ./maven-install.sh
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------< org.apache.maven:standalone-pom >-------------------
[INFO] Building Maven Stub Project (No POM) 1
[INFO] --------------------------------[ pom ]---------------------------------
[INFO]
[INFO] --- maven-install-plugin:2.4:install-file (default-cli) @ standalone-pom ---
[INFO] Installing /Users/Alex/Downloads/hypersistence-optimizer-2.6.0-trial/lib/hypersistence-optimizer-2.6.0-trial.jar to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial/hypersistence-optimizer-2.6.0-trial.jar
[INFO] Installing /var/folders/s4/4b8kj2052yz941j71t7003pc0000gp/T/mvninstall10688612564219904417.pom to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial/hypersistence-optimizer-2.6.0-trial.pom
[INFO] Installing /Users/Alex/Downloads/hypersistence-optimizer-2.6.0-trial/lib/hypersistence-optimizer-2.6.0-trial-sources.jar to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial/hypersistence-optimizer-2.6.0-trial-sources.jar
[INFO] Installing /Users/Alex/Downloads/hypersistence-optimizer-2.6.0-trial/lib/hypersistence-optimizer-2.6.0-trial-javadoc.jar to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial/hypersistence-optimizer-2.6.0-trial-javadoc.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  0.151 s
[INFO] Finished at: 2022-09-27T10:29:04+13:00
[INFO] ------------------------------------------------------------------------
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------< org.apache.maven:standalone-pom >-------------------
[INFO] Building Maven Stub Project (No POM) 1
[INFO] --------------------------------[ pom ]---------------------------------
[INFO]
[INFO] --- maven-install-plugin:2.4:install-file (default-cli) @ standalone-pom ---
[INFO] Installing /Users/Alex/Downloads/hypersistence-optimizer-2.6.0-trial/lib/hypersistence-optimizer-2.6.0-trial-jre6.jar to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial-jre6/hypersistence-optimizer-2.6.0-trial-jre6.jar
[INFO] Installing /var/folders/s4/4b8kj2052yz941j71t7003pc0000gp/T/mvninstall2608047261612511560.pom to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial-jre6/hypersistence-optimizer-2.6.0-trial-jre6.pom
[INFO] Installing /Users/Alex/Downloads/hypersistence-optimizer-2.6.0-trial/lib/hypersistence-optimizer-2.6.0-trial-jre6-sources.jar to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial-jre6/hypersistence-optimizer-2.6.0-trial-jre6-sources.jar
[INFO] Installing /Users/Alex/Downloads/hypersistence-optimizer-2.6.0-trial/lib/hypersistence-optimizer-2.6.0-trial-jre6-javadoc.jar to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial-jre6/hypersistence-optimizer-2.6.0-trial-jre6-javadoc.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  0.122 s
[INFO] Finished at: 2022-09-27T10:29:04+13:00
[INFO] ------------------------------------------------------------------------
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------< org.apache.maven:standalone-pom >-------------------
[INFO] Building Maven Stub Project (No POM) 1
[INFO] --------------------------------[ pom ]---------------------------------
[INFO]
[INFO] --- maven-install-plugin:2.4:install-file (default-cli) @ standalone-pom ---
[INFO] Installing /Users/Alex/Downloads/hypersistence-optimizer-2.6.0-trial/lib/hypersistence-optimizer-2.6.0-trial-jakarta.jar to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial-jakarta/hypersistence-optimizer-2.6.0-trial-jakarta.jar
[INFO] Installing /var/folders/s4/4b8kj2052yz941j71t7003pc0000gp/T/mvninstall5140198703164644350.pom to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial-jakarta/hypersistence-optimizer-2.6.0-trial-jakarta.pom
[INFO] Installing /Users/Alex/Downloads/hypersistence-optimizer-2.6.0-trial/lib/hypersistence-optimizer-2.6.0-trial-jakarta-sources.jar to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial-jakarta/hypersistence-optimizer-2.6.0-trial-jakarta-sources.jar
[INFO] Installing /Users/Alex/Downloads/hypersistence-optimizer-2.6.0-trial/lib/hypersistence-optimizer-2.6.0-trial-jakarta-javadoc.jar to /Users/Alex/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial-jakarta/hypersistence-optimizer-2.6.0-trial-jakarta-javadoc.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  0.118 s
[INFO] Finished at: 2022-09-27T10:29:05+13:00
[INFO] ------------------------------------------------------------------------

image image

image

The contents of ~/.m2/repository/io/hypersistence/hypersistence-optimizer/2.6.0-trial are:

image

I can't think of why this might be happening. Has anyone encountered this before? I'm sure it's something simple that I've missed, but I've also gone through the install doc a few times now and haven't found any steps that I've missed (aside from configuring the logger)

Is anyone able to spot anything or offer any advice?

vladmihalcea commented 2 years ago

You can use the trial branch, which provides various examples that work just fine with the trial version.

In your case, you can check out this Spring Boot example.

First, try to run the tests from Maven. If it works in Maven, but it does not work in IntelliJ IDEA, then you know it's an IDE problem, in which case you could try a different IDEA version.

AlexanderNZ commented 2 years ago

Thanks, Vlad

Looks like it was a Gradle issue. I needed to add mavenLocal() to my build.gradle - for projects where you are pulling in your own libraries this is probably quite a common thing, but for me it was not :)

All fixed.

vladmihalcea commented 2 years ago

I'm glad you found the problem. Cheers!