Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Help Request #25

Open
cwatsonc opened this issue Aug 27, 2022 · 4 comments
Open

Help Request #25

cwatsonc opened this issue Aug 27, 2022 · 4 comments

Comments

@cwatsonc
Copy link

Just discovered this code which appears to mirror the coursework for Ali Gelenler's course on Spring Boot microservices -- are there instructions that allow me to follow the coursework? I've tried compiling the project (first at project root, then at the Section 3 service description in twitter-to-kafka-service project root -- both failed at some peer dependency FFI not being available. Any help is appreciated -- let me know if I can help somehow. -CW cwatsonc

MacOS Monterey 12.5
Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)
Maven home: /usr/local/Cellar/maven/3.6.3_1/libexec
Java version: 17.0.4, vendor: Eclipse Adoptium, runtime: /Library/Java/JavaVirtualMachines/temurin-17.jdk/Contents/Home
Default locale: en_US, platform encoding: UTF-8
OS name: "mac os x", version: "12.5", arch: "aarch64", family: "mac"
mvn_out.txt

@artshishkin
Copy link
Owner

As I see in your log file the error happens during work of docker-maven-plugin (docker:build goal).

could not get native definition for type `POINTER`, original error message follows: java.lang.UnsatisfiedLinkError: Unable to execute or load jffi binary stub from `/var/folders/kr/sl9d0kfd6xz8925bzxc99ygw0000gn/T/`. Set `TMPDIR` or Java property `java.io.tmpdir` to a read/write path that is not mounted "noexec".

Unfortunatly I can not test any solutions (because I have no Mac).
As a workaround you can follow the steps from this article Maven + Mac M1 (aarch64) + Fabric8 docker-maven-plugin
This issue of plugin could be fixed in the newer versions. First of all let's update plugin docker-maven-plugin

@artshishkin
Copy link
Owner

After updating plugin version:

  • First of all run build without testing from the root of the project:
  • mvn clean install -DskipTests
  • This will build all the modules, install artifacts into local maven repository, and finally build docker images
  • After that you can verify that everything works fine by unit and integration tests:
  • mvn verify

@artshishkin
Copy link
Owner

are there instructions that allow me to follow the coursework?
I have no such instructions. But I followed the course and commited every step. For every Section I made an Issue to myself.
So my commits are grouped by Issues. And you can follow my commits and my closed issues.

@cwatsonc
Copy link
Author

After updating plugin version:

  • First of all run build without testing from the root of the project:
  • mvn clean install -DskipTests
  • This will build all the modules, install artifacts into local maven repository, and finally build docker images
  • After that you can verify that everything works fine by unit and integration tests:
  • mvn verify

updating docker-maven-plugin to 0.39.1 seemed to do the trick -- the docker images seemed to be generated 'correctly' but the verification fails on jacoco validation steps due to mismatch in the supported idk -- I'm researching the error and it's well known -- I'll have to figure out the configuration as they recommended constraining the coverage to the application classes and excluding the java.* package spaces. jacoco issue 997

now the verification fails in a number of (perhaps) configuration issues. I'll need to loop back to the course content and begin absorbing the proper configurations.

@artshishkin Suggest a short DIFFERENCES.md describing how this project varied from the original course -- grateful to have some working builds to start from. I recently completed an online course that used branches to describe content progress 01_04b (chapter 1 section 4, beginning state) 01_04e (end state). I might start a fork and propose pulls in this format -- don't want to bother you if you feel this isn't worthwhile.

Thanks for your assistance cwatsonc

artshishkin added a commit that referenced this issue Aug 28, 2022
* Test building on Java 17 config

* Test jacoco-maven-plugin old version 0.8.5 on Java 17

* Back to 0.8.8 version

* Run on Mac with java 17

* Splitting Maven build configuration

* Badges for GitHub actions

* Check Docker version in GitHub Actions Mac Image

* Check Docker version in GitHub Actions Images

* Install Docker into Mac runner

* Install Docker into Mac runner 2

* using docker-practice/actions-setup-docker@master

* pull docker images before maven verify

* adding cache for maven repository

* fixed Elasticsearch docker image version

* no need to cache maven dependencies explicitly

* renamed jobs and badges

* enlarged startup timeout for Elasticsearch container
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants