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

Improve API documentation #271

Closed
jaguililla opened this issue Feb 15, 2020 · 50 comments
Closed

Improve API documentation #271

jaguililla opened this issue Feb 15, 2020 · 50 comments
Labels

Comments

@jaguililla
Copy link
Member

jaguililla commented Feb 15, 2020

This task is going to be open indefinitely.

If you find some public element (class, method, field, etc.) without proper API documentation, feel free to make the PR and reference this issue. However, the issue won't be closed as stated before.

ONLY public members require documentation.

Some hints to write the comments are:

  • Use the imperative form.
  • Capitalize descriptions (parameters, receivers, return types, etc.) and end sentences with a dot.
  • Complete all KDoc tags (I.e.: @param, @receiver, etc. for the methods that have them.
  • Focus on what they do, not how, neither what it is.
  • Not saying method or property (that is clear from the context).
  • Comments to ignore warnings (false positives) should include an explanation.
  • Explain corner cases, default values and allowed values/formats if it applies.
  • These are recommendations, feel free to make an exception if you think it is required to explain the use/structure of the code better.

This will make users learn how to use this tool much faster.

Thank you for making this library a bit better :)

@sumitkp18
Copy link
Contributor

sumitkp18 commented Oct 4, 2020

Hi @jaguililla ,
I am a first time contributor.
Can I take this task up?

@sumitkp18
Copy link
Contributor

I am unable to build the project.
Getting the following error:
e: /Users//StudioProjects/hexagon/build.gradle.kts:13:29: Unresolved reference: nullOutputStream

@jaguililla
Copy link
Member Author

Thanks for contributing! You need to set up a JDK11 (nullOutputStream is available for JDK11+). Check contributing.md for all details. And if you need to do anything else not listed there... don't miss the chance to update contributing.md itself :)

@sumitkp18
Copy link
Contributor

sumitkp18 commented Oct 4, 2020

Thanks @jaguililla .
Have setup the project with JDK11.
I have started documenting the project.
Completed JettyServerAdapter.
Could you please assign this issue to me?

How do you want the PRs for the documentation?
PR per module is fine?

Also, do we have any branching strategy or branch naming rules?
The merged PRs were from develop so couldn't get an idea.
I am planning to go with for documentation/<module_name> if that's fine.
Please let me know.

Thanks.

@jaguililla
Copy link
Member Author

I'll assign it to you, however, note that it is a long task and it doesn't matter if you finish it or not (it is a continuous background tasks until 2.0 release).

A PR per module is fine, but as some of them are big, you can also make PRs per package.

After proceeding with documenting, take a look to ongoing tasks to avoid conflicts with other PRs (btw, I'm working on the hexagon_core module now).

There is no branch naming standard, but the PRs should be done to develop (as master is reserved for releases).

Thanks for collaborating!

@sumitkp18
Copy link
Contributor

Thanks @jaguililla .
I will raise my PR for the http_server_jetty module. Please help me with your PR comments if any changes are required in my style of Java docs so that I can follow the same in other PRs too.

Thanks.

@sumitkp18
Copy link
Contributor

sumitkp18 commented Oct 6, 2020

@jaguililla
Can you please help me with my first PR.
I have forked the hexagon repo and while pushing I am getting a Build Error

Task :cleanDocker FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':cleanDocker'.
> A problem occurred starting process 'command 'docker''

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --    scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 3s
1 actionable task: 1 executed
error: failed to push some refs to 'https://github.com/sumitkp18/hexagon.git

@jaguililla
Copy link
Member Author

You'll need Docker installed... you can take a look at the contributing guide. And ask again if it doesn't solve your problem (in that case, I'll help you and update the guide). Thanks!

@sumitkp18
Copy link
Contributor

I have docker installed.
I now tried to run the following command given in contributing guide:
./gradlew setUp build buildSite publishToMavenLocal

and it gives me the following error:

Dependency verification is an incubating feature.

Task :setUp
Client: Docker Engine - Community
Cloud integration 0.1.18
Version: 19.03.13
API version: 1.40
Go version: go1.13.15
Git commit: 4484c46d9d
Built: Wed Sep 16 16:58:31 2020
OS/Arch: darwin/amd64
Experimental: false

Server: Docker Engine - Community
Engine:
Version: 19.03.13
API version: 1.40 (minimum version 1.12)
Go version: go1.13.15
Git commit: 4484c46d9d
Built: Wed Sep 16 17:07:04 2020
OS/Arch: linux/amd64
Experimental: false
containerd:
Version: v1.3.7
GitCommit: 8fba4e9a7d01810a393d5d25a3621dc101981175
runc:
Version: 1.0.0-rc10
GitCommit: dc9208a3303feef5b3839f4323d9beb36df0a9dd
docker-init:
Version: 0.18.0
GitCommit: fec3683
docker-compose version 1.27.4, build 40524192
docker-py version: 4.3.1
CPython version: 3.7.7
OpenSSL version: OpenSSL 1.1.1g 21 Apr 2020

Task :http_client_ahc:test

com.hexagonkt.http.client.ahc.AhcAdapterExampleTest > JSON requests works as expected() FAILED
java.lang.AssertionError at ClientTest.kt:96

11 tests completed, 1 failed

Task :http_client_ahc:test FAILED

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':http_client_ahc:test'.

There were failing tests. See the report at: file:///Users/sumit6975/StudioProjects/hexagon/http_client_ahc/build/reports/tests/test/index.html

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at https://help.gradle.org

BUILD FAILED in 27s
55 actionable tasks: 3 executed, 52 up-to-date

@sumitkp18
Copy link
Contributor

All tests of ClientTest class pass successfully if the test is run independently on the class.

@sumitkp18
Copy link
Contributor

sumitkp18 commented Oct 6, 2020

I was able to run the command successfully on removing the test annotation from the following method in ClientTest class:

fun JSON requests works as expected()

I also got a docker file generated after the build was successful, should it be put in .gitignore ?

@jaguililla
Copy link
Member Author

What file is being created?

@sumitkp18
Copy link
Contributor

sumitkp18 commented Oct 7, 2020

Sorry,
that file was my mistake.
I had tried to create a symlink of docker binary in the repo temporarily, as I was getting the error:

A problem occurred starting process 'command 'docker''

Could you please help me with the build error as well as the error on pushing the changes?

@sumitkp18
Copy link
Contributor

@jaguililla
I was using Sourcetree app to handle git, and perhaps it wasn't able to resolve docker binary.

I tried pushing it through terminal and it worked.
I have pushed the changes.
Will raise PR.

@sumitkp18
Copy link
Contributor

@jaguililla I have addressed the review comments and updated my PR. Could you please check.

@jaguililla
Copy link
Member Author

I made two minor comments and with those it will be done 🙂

@sumitkp18
Copy link
Contributor

Addressed the comments and pushed the changes.

jaguililla added a commit that referenced this issue Oct 12, 2020
(#271) Documentation added  for module: http_server_jetty
@jaguililla
Copy link
Member Author

Merged! Now you've warmed up... Wouldn't you like to pick another module ;)

@sumitkp18
Copy link
Contributor

Sure @jaguililla
Thanks a lot for guiding me.
This is my first Open Source contribution! Feeling awesome!

@sumitkp18
Copy link
Contributor

Starting with port_http_server module.
Sorry for the long break, had been busy with work.

@jaguililla
Copy link
Member Author

No worries, I understand (that was my situation some days ago) 🙂 Thank you for your contribution, don't press yourself, relax and enjoy!

@sumitkp18
Copy link
Contributor

sumitkp18 commented Oct 26, 2020

@jaguililla , can you please help with the RequestHandler class. I am not getting a clear idea on the different child class handlers.

@sumitkp18
Copy link
Contributor

I was able to get some understanding by observing test implementations. Have added the docs accordingly; will modify if required, after review.

@sumitkp18
Copy link
Contributor

@jaguililla
I have raised a PR for documentation of port_http_server module.
Please review.

@MohamedHarmoush
Copy link

MohamedHarmoush commented Oct 1, 2021

@jaguililla I solved the issue. It was related to java version jdk17 that gradle v7.2 (used in hexagon) not support jdk16 jdk17.
The solution is working with the java version below jdk16, I used jdk15 (If someone faced the same issue)
Check also> how to change between installed java versions in windows

@jaguililla
Copy link
Member Author

@MohamedHarmoush JDK17 is still fresh... Don't put to much effort supporting it ;)

The supported runtimes now are 8 (for running only, not compiling Hexagon) and 11 (to compile the project and also run their applications).

In my case (as I use different JVMs for different projects), I use https://www.jenv.be (you can also use https://sdkman.io if you prefer) for setting a fixed Java version to each project (the version used for Hexagon must be 11).

JDK17 will be supported, but after all dependencies are updated. For compiling the project, use the previous LTS (11). However, the binaries could be run on newer JDKs, but for compiling, it has to be 11 right now :)

@MohamedHarmoush
Copy link

@jaguililla thanks. Sometimes I get confused with the different versions of java and don't know what's the best java version fits in my project. I'll use JDK11.

@MohamedHarmoush
Copy link

Hey @jaguililla,
Sorry for being late.
I added documentation for logging package in hexagon_core module. I'd like you to check it and give me your feedback.

jaguililla added a commit that referenced this issue Oct 9, 2021
Add documentation for `logging` package in `hexagon_core` module (issue #271)
@MohamedHarmoush
Copy link

@jaguililla a quick question. Do I consider one of the contributors to the Hexagon project? 😅
I don't see myself on the contributor's page 😓

Sorry for being late, I have only free time on Friday most of the time.
I'll continue documenting the core package.

Another question:
Did you have any comments in the previous PR?

Thanks.

@jaguililla
Copy link
Member Author

Hello @MohamedHarmoush maybe you are not listed as a contributor because your commits are not merged to master yet (only in develop). You will probably listed on the next release 🙂

@jaguililla jaguililla moved this to In Progress in Hexagon Jan 3, 2022
@jaguililla jaguililla removed this from the 2.0.0 milestone Feb 24, 2022
@Younus-Saberi
Copy link

Hi @jaguililla ,
I am a first-time contributor.
Can I take this task up?

@jaguililla
Copy link
Member Author

Sure... be my guest :) Please, read the task's description to follow the project's documentation style ;)

I will assign this task to you, and of course, if you have any question, please ask!

Thank you for your help and interest in the project... Happy coding!

@Younus-Saberi
Copy link

I have docker installed and when i am building the project its giving me the

BUILD FAILED I have referd the https://github.com/hexagonkt/.github/blob/e9a982059a07bef8be4af66d786da829abd3a378/contributing.md while setting up project in my local system

image

@jaguililla
Copy link
Member Author

Can you share with me the output of ./gradlew -v? and also, the list of failed tests (listed when you open the index.html file).

@Younus-Saberi
Copy link

Okay
image
image

@jaguililla
Copy link
Member Author

Sorry for the bad explanation, I'll need you to open the index.html file with a browser and send me the list of failed tests.

@Younus-Saberi
Copy link

Sorry for the bad explanation, I'll need you to open the index.html file with a browser and send me the list of failed tests.

image
`

KeyStoresTest

all > com.hexagonkt.core.security > KeyStoresTest
1tests1failures0ignored0.112sduration 1tests 1failures 0ignored 0.112sduration 0%successful
1tests 1failures 0ignored 0.112sduration

Key stores are loaded correctly()

java.io.IOException: Integrity check failed: java.security.NoSuchAlgorithmException: Algorithm HmacPBESHA256 not available
	at java.base/sun.security.pkcs12.PKCS12KeyStore.engineLoad(PKCS12KeyStore.java:2167)
	at java.base/sun.security.util.KeyStoreDelegator.engineLoad(KeyStoreDelegator.java:222)
	at java.base/java.security.KeyStore.load(KeyStore.java:1479)
	at com.hexagonkt.core.security.KeyStoresKt.loadKeyStore(KeyStores.kt:11)
	at com.hexagonkt.core.security.KeyStoresTest.Key stores are loaded correctly(KeyStoresTest.kt:17)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.junit.platform.commons.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:727)
	at org.junit.jupiter.engine.execution.MethodInvocation.proceed(MethodInvocation.java:60)
	at org.junit.jupiter.engine.execution.InvocationInterceptorChain$ValidatingInvocation.proceed(InvocationInterceptorChain.java:131)
	at org.junit.jupiter.engine.extension.TimeoutExtension.intercept(TimeoutExtension.java:156)
	at org.junit.jupiter.engine.extension.TimeoutExtension.interceptTestableMethod(TimeoutExtension.java:147)
	at org.junit.jupiter.engine.extension.TimeoutExtension.interceptTestMethod(TimeoutExtension.java:86)
	at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker$ReflectiveInterceptorCall.lambda$ofVoidMethod$0(InterceptingExecutableInvoker.java:103)
	at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker.lambda$invoke$0(InterceptingExecutableInvoker.java:93)
	at org.junit.jupiter.engine.execution.InvocationInterceptorChain$InterceptedInvocation.proceed(InvocationInterceptorChain.java:106)
	at org.junit.jupiter.engine.execution.InvocationInterceptorChain.proceed(InvocationInterceptorChain.java:64)
	at org.junit.jupiter.engine.execution.InvocationInterceptorChain.chainAndInvoke(InvocationInterceptorChain.java:45)
	at org.junit.jupiter.engine.execution.InvocationInterceptorChain.invoke(InvocationInterceptorChain.java:37)
	at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker.invoke(InterceptingExecutableInvoker.java:92)
	at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker.invoke(InterceptingExecutableInvoker.java:86)
	at org.junit.jupiter.engine.descriptor.TestMethodTestDescriptor.lambda$invokeTestMethod$7(TestMethodTestDescriptor.java:217)
	at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
	at org.junit.jupiter.engine.descriptor.TestMethodTestDescriptor.invokeTestMethod(TestMethodTestDescriptor.java:213)
	at org.junit.jupiter.engine.descriptor.TestMethodTestDescriptor.execute(TestMethodTestDescriptor.java:138)
	at org.junit.jupiter.engine.descriptor.TestMethodTestDescriptor.execute(TestMethodTestDescriptor.java:68)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:151)
	at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:141)
	at org.junit.platform.engine.support.hierarchical.Node.around(Node.java:137)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$9(NodeTestTask.java:139)
	at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:138)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:95)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1541)
	at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.invokeAll(SameThreadHierarchicalTestExecutorService.java:41)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:155)
	at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:141)
	at org.junit.platform.engine.support.hierarchical.Node.around(Node.java:137)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$9(NodeTestTask.java:139)
	at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:138)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:95)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1541)
	at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.invokeAll(SameThreadHierarchicalTestExecutorService.java:41)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:155)
	at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:141)
	at org.junit.platform.engine.support.hierarchical.Node.around(Node.java:137)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$9(NodeTestTask.java:139)
	at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:138)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:95)
	at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.submit(SameThreadHierarchicalTestExecutorService.java:35)
	at org.junit.platform.engine.support.hierarchical.HierarchicalTestExecutor.execute(HierarchicalTestExecutor.java:57)
	at org.junit.platform.engine.support.hierarchical.HierarchicalTestEngine.execute(HierarchicalTestEngine.java:54)
	at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:107)
	at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:88)
	at org.junit.platform.launcher.core.EngineExecutionOrchestrator.lambda$execute$0(EngineExecutionOrchestrator.java:54)
	at org.junit.platform.launcher.core.EngineExecutionOrchestrator.withInterceptedStreams(EngineExecutionOrchestrator.java:67)
	at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:52)
	at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:114)
	at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:86)
	at org.junit.platform.launcher.core.DefaultLauncherSession$DelegatingLauncher.execute(DefaultLauncherSession.java:86)
	at org.junit.platform.launcher.core.SessionPerRequestLauncher.execute(SessionPerRequestLauncher.java:53)
	at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor$CollectAllTestClassesExecutor.processAllTestClasses(JUnitPlatformTestClassProcessor.java:99)
	at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor$CollectAllTestClassesExecutor.access$000(JUnitPlatformTestClassProcessor.java:79)
	at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor.stop(JUnitPlatformTestClassProcessor.java:75)
	at org.gradle.api.internal.tasks.testing.SuiteTestClassProcessor.stop(SuiteTestClassProcessor.java:61)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:36)
	at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)
	at org.gradle.internal.dispatch.ContextClassLoaderDispatch.dispatch(ContextClassLoaderDispatch.java:33)
	at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:94)
	at com.sun.proxy.$Proxy5.stop(Unknown Source)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker$3.run(TestWorker.java:193)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker.executeAndMaintainThreadName(TestWorker.java:129)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:100)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:60)
	at org.gradle.process.internal.worker.child.ActionExecutionWorker.execute(ActionExecutionWorker.java:56)
	at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:133)
	at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:71)
	at worker.org.gradle.process.internal.worker.GradleWorkerMain.run(GradleWorkerMain.java:69)
	at worker.org.gradle.process.internal.worker.GradleWorkerMain.main(GradleWorkerMain.java:74)
Caused by: java.security.NoSuchAlgorithmException: Algorithm HmacPBESHA256 not available
	at java.base/javax.crypto.Mac.getInstance(Mac.java:191)
	at java.base/sun.security.pkcs12.PKCS12KeyStore.engineLoad(PKCS12KeyStore.java:2145)
	... 89 more
KeyStoresTest [all](https://github.com/hexagonkt/hexagon/index.html) > [com.hexagonkt.core.security](https://github.com/hexagonkt/hexagon/packages/com.hexagonkt.core.security.html) > KeyStoresTest 1 tests

1
failures

0
ignored

0.112s
duration

0%
successful

Failed tests
Tests
Key stores are loaded correctly()
java.io.IOException: Integrity check failed: java.security.NoSuchAlgorithmException: Algorithm HmacPBESHA256 not available
at java.base/sun.security.pkcs12.PKCS12KeyStore.engineLoad(PKCS12KeyStore.java:2167)
at java.base/sun.security.util.KeyStoreDelegator.engineLoad(KeyStoreDelegator.java:222)
at java.base/java.security.KeyStore.load(KeyStore.java:1479)
at com.hexagonkt.core.security.KeyStoresKt.loadKeyStore(KeyStores.kt:11)
at com.hexagonkt.core.security.KeyStoresTest.Key stores are loaded correctly(KeyStoresTest.kt:17)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.junit.platform.commons.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:727)
at org.junit.jupiter.engine.execution.MethodInvocation.proceed(MethodInvocation.java:60)
at org.junit.jupiter.engine.execution.InvocationInterceptorChain$ValidatingInvocation.proceed(InvocationInterceptorChain.java:131)
at org.junit.jupiter.engine.extension.TimeoutExtension.intercept(TimeoutExtension.java:156)
at org.junit.jupiter.engine.extension.TimeoutExtension.interceptTestableMethod(TimeoutExtension.java:147)
at org.junit.jupiter.engine.extension.TimeoutExtension.interceptTestMethod(TimeoutExtension.java:86)
at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker$ReflectiveInterceptorCall.lambda$ofVoidMethod$0(InterceptingExecutableInvoker.java:103)
at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker.lambda$invoke$0(InterceptingExecutableInvoker.java:93)
at org.junit.jupiter.engine.execution.InvocationInterceptorChain$InterceptedInvocation.proceed(InvocationInterceptorChain.java:106)
at org.junit.jupiter.engine.execution.InvocationInterceptorChain.proceed(InvocationInterceptorChain.java:64)
at org.junit.jupiter.engine.execution.InvocationInterceptorChain.chainAndInvoke(InvocationInterceptorChain.java:45)
at org.junit.jupiter.engine.execution.InvocationInterceptorChain.invoke(InvocationInterceptorChain.java:37)
at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker.invoke(InterceptingExecutableInvoker.java:92)
at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker.invoke(InterceptingExecutableInvoker.java:86)
at org.junit.jupiter.engine.descriptor.TestMethodTestDescriptor.lambda$invokeTestMethod$7(TestMethodTestDescriptor.java:217)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.jupiter.engine.descriptor.TestMethodTestDescriptor.invokeTestMethod(TestMethodTestDescriptor.java:213)
at org.junit.jupiter.engine.descriptor.TestMethodTestDescriptor.execute(TestMethodTestDescriptor.java:138)
at org.junit.jupiter.engine.descriptor.TestMethodTestDescriptor.execute(TestMethodTestDescriptor.java:68)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:151)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:141)
at org.junit.platform.engine.support.hierarchical.Node.around(Node.java:137)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$9(NodeTestTask.java:139)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:138)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:95)
at java.base/java.util.ArrayList.forEach(ArrayList.java:1541)
at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.invokeAll(SameThreadHierarchicalTestExecutorService.java:41)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:155)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:141)
at org.junit.platform.engine.support.hierarchical.Node.around(Node.java:137)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$9(NodeTestTask.java:139)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:138)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:95)
at java.base/java.util.ArrayList.forEach(ArrayList.java:1541)
at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.invokeAll(SameThreadHierarchicalTestExecutorService.java:41)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:155)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:141)
at org.junit.platform.engine.support.hierarchical.Node.around(Node.java:137)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$9(NodeTestTask.java:139)
at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:138)
at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:95)
at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.submit(SameThreadHierarchicalTestExecutorService.java:35)
at org.junit.platform.engine.support.hierarchical.HierarchicalTestExecutor.execute(HierarchicalTestExecutor.java:57)
at org.junit.platform.engine.support.hierarchical.HierarchicalTestEngine.execute(HierarchicalTestEngine.java:54)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:107)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:88)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.lambda$execute$0(EngineExecutionOrchestrator.java:54)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.withInterceptedStreams(EngineExecutionOrchestrator.java:67)
at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:52)
at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:114)
at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:86)
at org.junit.platform.launcher.core.DefaultLauncherSession$DelegatingLauncher.execute(DefaultLauncherSession.java:86)
at org.junit.platform.launcher.core.SessionPerRequestLauncher.execute(SessionPerRequestLauncher.java:53)
at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor$CollectAllTestClassesExecutor.processAllTestClasses(JUnitPlatformTestClassProcessor.java:99)
at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor$CollectAllTestClassesExecutor.access$000(JUnitPlatformTestClassProcessor.java:79)
at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor.stop(JUnitPlatformTestClassProcessor.java:75)
at org.gradle.api.internal.tasks.testing.SuiteTestClassProcessor.stop(SuiteTestClassProcessor.java:61)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:36)
at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)
at org.gradle.internal.dispatch.ContextClassLoaderDispatch.dispatch(ContextClassLoaderDispatch.java:33)
at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:94)
at com.sun.proxy.$Proxy5.stop(Unknown Source)
at org.gradle.api.internal.tasks.testing.worker.TestWorker$3.run(TestWorker.java:193)
at org.gradle.api.internal.tasks.testing.worker.TestWorker.executeAndMaintainThreadName(TestWorker.java:129)
at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:100)
at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:60)
at org.gradle.process.internal.worker.child.ActionExecutionWorker.execute(ActionExecutionWorker.java:56)
at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:133)
at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:71)
at worker.org.gradle.process.internal.worker.GradleWorkerMain.run(GradleWorkerMain.java:69)
at worker.org.gradle.process.internal.worker.GradleWorkerMain.main(GradleWorkerMain.java:74)
Caused by: java.security.NoSuchAlgorithmException: Algorithm HmacPBESHA256 not available
at java.base/javax.crypto.Mac.getInstance(Mac.java:191)
at java.base/sun.security.pkcs12.PKCS12KeyStore.engineLoad(PKCS12KeyStore.java:2145)
... 89 more`

@jaguililla
Copy link
Member Author

Ok, it seems that the signing algorithm used in the test keystore is not supported in your system. I will find out and change it by a more widely used algorithm.

In the meantime, replace the failing test with this line:

@Test @Disabled fun `Key stores are loaded correctly`()

But remember to not commit that change ;)

@Younus-Saberi
Copy link

Younus-Saberi commented Sep 6, 2022

Sure ;)👍

@jaguililla jaguililla pinned this issue Dec 19, 2022
@github-project-automation github-project-automation bot moved this from In Progress to Done in Hexagon Oct 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
Development

No branches or pull requests

5 participants