akullpp /
awesome-java
A curated list of awesome frameworks, libraries and software for the Java programming language.
84/100 healthLoading repository data…
joedevivo / repository
A library for Erlang/Java Interoperability via Erlang's rpc module
A transparent discovery signal based on current public GitHub metadata.
This score does not audit code, security, maintainers, documentation quality, or suitability. Verify the repository and its current documentation before adoption.
This project generates two artifacts:
rpc:call/4 functiongen_java server that you can implement via parse transform.Here's what you need to know on the java side of things
If you want to expose a java method to erlang, it needs to be public, static and have argument and return types from the OTP JInterface library.
For reference, the JInterface package reference can be found here
You should be able to pull from Maven Central pretty soon with this:
<dependency>
<groupId>com.devivo</groupId>
<artifactId>gen_java</artifactId>
<version>0.1.0</version>
</dependency>
{gen_java, [
{modules, [
{my_module, [
{jar, "/path/to/jar/file.jar"},
%% Default thread count is 10.
%% this is how big the java thread pool is
{thread_count, 10}
]}
]}
]}
my_module-module(my_module).
-compile({parse_transform, gen_java_parse_transform}).
Start gen_java with my_module:start_link() or my_module:start(). Those functions are free with the parse transform, so don't worry about it.
{my_module,
{my_module, start_link, []},
permanent, 5000, worker, [my_module]},
Don't call it a callback, 'cause it's not a behaviour. You can add an
init/1 hollaback to your module to do some initialization of your
JVM node. The only trick is that you have to use rpc:call/4 since
the gen_server isn't started yet.
-spec init(atom()) -> ok.
init(Nodename) ->
rpc:call(Nodename, 'com.yourcompany.package', 'init', [<<SomeState>>]).
my_module:call('com.whatever.package.Class', 'methodName', ['arg', <<"other arg">>]) will return the value you want!
Worried about waiting forever? There's a call/4 that allows you to specify a timeout.
-spec method_name(atom(), binary()) -> my_return_type() | gen_java:badrpc().
method_name(Atom, Binary) ->
call('com.whatever.package.Class', 'methodName', [Atom, Binary]).
my_module:call/3 will have the same dialyzer return type as rpc:call/4
For fun, We provide gen_java:badrpc() for you to use in addition to
your expected return type. This will let you just append | gen_java:badrpc() to your spec and then fuggedaboudit.
easy peasy
%% @doc java.lang.System.getProperties()
-spec system_properties() -> [{atom(), binary()}].
java:system_properties/0
%% @doc java.lang.System.getenv()
-spec system_env() -> [{binary(), binary()}].
java:system_env/0
%% @doc command line $JAVA_OPTS. (e.g. -Xmx512m)
-spec input_arguments() -> binary().
java:input_arguments/0
Selected from shared topics, language and repository description—not editorial ratings.
akullpp /
A curated list of awesome frameworks, libraries and software for the Java programming language.
84/100 healthReactiveX /
RxJava – Reactive Extensions for the JVM – a library for composing asynchronous and event-based programs using observable sequences for the Java VM.
98/100 healthsquare /
A memory leak detection library for Android.
ben-manes /
A high performance caching library for Java
89/100 healthdeeplearning4j /
Suite of tools for deploying and training deep learning models using the JVM. Highlights include model import for keras, tensorflow, and onnx/pytorch, a modular and tiny c++ library for running math code and a java based math library on top of the core c++ library. Also includes samediff: a pytorch/tensorflow like library for running deep learn...
96/100 healthlangchain4j /
LangChain4j is an idiomatic, open-source Java library for building LLM-powered applications on the JVM. It offers a unified API over popular LLM providers and vector stores, and makes implementing tool calling (including MCP support), agents and RAG easy. It integrates seamlessly with enterprise Java frameworks like Quarkus and Spring Boot.
89/100 health