GithubHelp home page GithubHelp logo

Comments (11)

s12f avatar s12f commented on May 24, 2024

@sc-aniagr Hi, it looks like a dependency problem, could you add your project's dependency tree?(if you uses gradle, your can run ./gradlew app:dependencies or gradle dependencies -b app/build.gradle)

from hstream.

sc-aniagr avatar sc-aniagr commented on May 24, 2024

hi @s12f

I am using mvn build for this:

Please find below dependencies used.

io.hstream hstreamdb-java 0.8.0

from hstream.

s12f avatar s12f commented on May 24, 2024

@sc-aniagr hstreamdb-java 0.8.0 can not work with HStreamDB 0.9.3, could you try to use hstreamdb-java 0.9.0?

from hstream.

sc-aniagr avatar sc-aniagr commented on May 24, 2024

Hi @s12f ,

I have tried with upgrading to 0.9.3 as well, could not connect and facing the same issue. Please suggest?

<dependencies>
    <dependency>
        <groupId>io.hstream</groupId>
        <artifactId>hstreamdb-java</artifactId>
        <version>0.9.0</version>
    </dependency>
</dependencies>

"C:\Program Files\Java\jdk-11.0.16\bin\java.exe" "-javaagent:C:\Program Files\JetBrains\IntelliJ IDEA 2022.1.4\lib\idea_rt.jar=53296:C:\Program Files\JetBrains\IntelliJ IDEA 2022.1.4\bin" -Dfile.encoding=UTF-8 -classpath C:\Users\anish_agrawal\IdeaProjects\JDK11\target\classes;C:\Users\anish_agrawal.m2\repository\io\hstream\hstreamdb-java\0.9.0\hstreamdb-java-0.9.0.jar;C:\Users\anish_agrawal.m2\repository\com\google\guava\guava\31.0.1-android\guava-31.0.1-android.jar;C:\Users\anish_agrawal.m2\repository\com\google\guava\failureaccess\1.0.1\failureaccess-1.0.1.jar;C:\Users\anish_agrawal.m2\repository\com\google\guava\listenablefuture\9999.0-empty-to-avoid-conflict-with-guava\listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar;C:\Users\anish_agrawal.m2\repository\com\google\code\findbugs\jsr305\3.0.2\jsr305-3.0.2.jar;C:\Users\anish_agrawal.m2\repository\org\checkerframework\checker-qual\3.12.0\checker-qual-3.12.0.jar;C:\Users\anish_agrawal.m2\repository\org\checkerframework\checker-compat-qual\2.5.5\checker-compat-qual-2.5.5.jar;C:\Users\anish_agrawal.m2\repository\com\google\errorprone\error_prone_annotations\2.7.1\error_prone_annotations-2.7.1.jar;C:\Users\anish_agrawal.m2\repository\com\google\j2objc\j2objc-annotations\1.3\j2objc-annotations-1.3.jar;C:\Users\anish_agrawal.m2\repository\org\jetbrains\kotlin\kotlin-stdlib-jdk8\1.6.10\kotlin-stdlib-jdk8-1.6.10.jar;C:\Users\anish_agrawal.m2\repository\org\jetbrains\kotlin\kotlin-stdlib\1.6.10\kotlin-stdlib-1.6.10.jar;C:\Users\anish_agrawal.m2\repository\org\jetbrains\annotations\13.0\annotations-13.0.jar;C:\Users\anish_agrawal.m2\repository\org\jetbrains\kotlin\kotlin-stdlib-jdk7\1.6.10\kotlin-stdlib-jdk7-1.6.10.jar;C:\Users\anish_agrawal.m2\repository\io\grpc\grpc-netty-shaded\1.45.0\grpc-netty-shaded-1.45.0.jar;C:\Users\anish_agrawal.m2\repository\io\perfmark\perfmark-api\0.23.0\perfmark-api-0.23.0.jar;C:\Users\anish_agrawal.m2\repository\io\grpc\grpc-core\1.45.0\grpc-core-1.45.0.jar;C:\Users\anish_agrawal.m2\repository\com\google\android\annotations\4.1.1.4\annotations-4.1.1.4.jar;C:\Users\anish_agrawal.m2\repository\org\codehaus\mojo\animal-sniffer-annotations\1.19\animal-sniffer-annotations-1.19.jar;C:\Users\anish_agrawal.m2\repository\io\grpc\grpc-protobuf\1.45.0\grpc-protobuf-1.45.0.jar;C:\Users\anish_agrawal.m2\repository\io\grpc\grpc-api\1.45.0\grpc-api-1.45.0.jar;C:\Users\anish_agrawal.m2\repository\io\grpc\grpc-context\1.45.0\grpc-context-1.45.0.jar;C:\Users\anish_agrawal.m2\repository\com\google\protobuf\protobuf-java\3.19.2\protobuf-java-3.19.2.jar;C:\Users\anish_agrawal.m2\repository\com\google\api\grpc\proto-google-common-protos\2.0.1\proto-google-common-protos-2.0.1.jar;C:\Users\anish_agrawal.m2\repository\io\grpc\grpc-protobuf-lite\1.45.0\grpc-protobuf-lite-1.45.0.jar;C:\Users\anish_agrawal.m2\repository\io\grpc\grpc-stub\1.45.0\grpc-stub-1.45.0.jar;C:\Users\anish_agrawal.m2\repository\com\google\protobuf\protobuf-java-util\3.17.3\protobuf-java-util-3.17.3.jar;C:\Users\anish_agrawal.m2\repository\com\google\code\gson\gson\2.8.6\gson-2.8.6.jar;C:\Users\anish_agrawal.m2\repository\org\apache\logging\log4j\log4j-slf4j-impl\2.17.1\log4j-slf4j-impl-2.17.1.jar;C:\Users\anish_agrawal.m2\repository\org\slf4j\slf4j-api\1.7.25\slf4j-api-1.7.25.jar;C:\Users\anish_agrawal.m2\repository\org\apache\logging\log4j\log4j-api\2.17.1\log4j-api-2.17.1.jar;C:\Users\anish_agrawal.m2\repository\org\apache\logging\log4j\log4j-core\2.17.1\log4j-core-2.17.1.jar;C:\Users\anish_agrawal.m2\repository\org\apache\commons\commons-lang3\3.12.0\commons-lang3-3.12.0.jar;C:\Users\anish_agrawal.m2\repository\io\grpc\grpc-kotlin-stub\1.2.0\grpc-kotlin-stub-1.2.0.jar;C:\Users\anish_agrawal.m2\repository\javax\annotation\javax.annotation-api\1.3.2\javax.annotation-api-1.3.2.jar;C:\Users\anish_agrawal.m2\repository\org\jetbrains\kotlinx\kotlinx-coroutines-core\1.3.3\kotlinx-coroutines-core-1.3.3.jar;C:\Users\anish_agrawal.m2\repository\com\google\protobuf\protobuf-kotlin\3.17.3\protobuf-kotlin-3.17.3.jar;C:\Users\anish_agrawal.m2\repository\org\jetbrains\kotlinx\kotlinx-coroutines-core-jvm\1.5.2\kotlinx-coroutines-core-jvm-1.5.2.jar;C:\Users\anish_agrawal.m2\repository\org\jetbrains\kotlin\kotlin-stdlib-common\1.5.30\kotlin-stdlib-common-1.5.30.jar;C:\Users\anish_agrawal.m2\repository\org\jetbrains\kotlinx\kotlinx-coroutines-jdk8\1.5.2\kotlinx-coroutines-jdk8-1.5.2.jar MainClass
13:38:17.073 [main] INFO io.hstream.impl.HStreamClientKtImpl - client init with bootstrapServerUrls [[127.0.0.1:6570]]
Exception in thread "main" java.lang.NoSuchMethodError: kotlinx.coroutines.AbstractCoroutine.(Lkotlin/coroutines/CoroutineContext;ZZ)V
at kotlinx.coroutines.future.CompletableFutureCoroutine.(Future.kt:51)
at kotlinx.coroutines.future.FutureKt.future(Future.kt:42)
at kotlinx.coroutines.future.FutureKt.future$default(Future.kt:34)
at io.hstream.impl.UtilsKt.futureForIO(Utils.kt:124)
at io.hstream.impl.UtilsKt.futureForIO$default(Utils.kt:123)
at io.hstream.impl.UtilsKt.unaryCallWithCurrentUrlsAsync(Utils.kt:115)
at io.hstream.impl.UtilsKt.unaryCallWithCurrentUrls(Utils.kt:119)
at io.hstream.impl.HStreamClientKtImpl.(HStreamClientKtImpl.kt:53)
at io.hstream.impl.HStreamClientBuilderImpl.build(HStreamClientBuilderImpl.java:74)
at MainClass.main(MainClass.java:6)

Process finished with exit code 1

from hstream.

daleiz avatar daleiz commented on May 24, 2024

@sc-aniagr I have fixed this in hstreamdb-java v0.10.0-SNAPSHOT, and you can try with it using maven. You can also use hstreamdb-java v0.9.0 with gradle, and it just works.

from hstream.

s12f avatar s12f commented on May 24, 2024

@sc-aniagr we recommend you to use hstreamdb-java 0.9.0 with gradle, because 0.10.0-SNAPSHOT is not a stable version and it is incompatible with hstream 0.9.3.

If you want to use maven still, please use latest hstream image(update your docker-compose file) with hstreamdb-java 0.10.0-SNAPSHOT.

from hstream.

sc-aniagr avatar sc-aniagr commented on May 24, 2024

Hi Mates @s12f and @daleiz

I am actually looking to integrate this into an existing maven project, thus taking a dig at gradle version doesn't seem suitable to me. How do you suggest moving ahead with 0.10.0-SNAPSHOT

from hstream.

sc-aniagr avatar sc-aniagr commented on May 24, 2024

Also, I am unable to pull docker image of new snapshot pull

[+] Running 0/4

  • hserver-init Error 6.9s
  • hserver1 Error 6.9s
  • hserver0 Error 6.9s
  • hstore Error 6.9s
    Error response from daemon: manifest for hstreamdb/hstream:v0.10.0-SNAPSHOT not found: manifest unknown: manifest unknown

Please suggest?

from hstream.

sc-aniagr avatar sc-aniagr commented on May 24, 2024

version: "3.5"

services:
hserver0:
image: hstreamdb/hstream:v0.10.0-SNAPSHOT
depends_on:
- zookeeper
- hstore
ports:
- "127.0.0.1:6570:6570"
expose:
- 6570
networks:
- hstream-quickstart
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /tmp:/tmp
- data_store:/data/store
command:
- bash
- "-c"
- |
set -e
/usr/local/script/wait-for-storage.sh hstore 6440 zookeeper 2181 600
/usr/local/bin/hstream-server
--host 0.0.0.0 --port 6570
--internal-port 6571
--server-id 100
--seed-nodes "$$(hostname -I | awk '{print $$1}'):6571,hserver1:6573"
--address $$(hostname -I | awk '{print $$1}')
--zkuri zookeeper:2181
--store-config /data/store/logdevice.conf
--store-admin-host hstore --store-admin-port 6440
--io-tasks-path /tmp/io/tasks
--io-tasks-network hstream-quickstart

hserver1:
image: hstreamdb/hstream:v0.10.0-SNAPSHOT
depends_on:
- zookeeper
- hstore
ports:
- "127.0.0.1:6572:6572"
expose:
- 6572
networks:
- hstream-quickstart
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /tmp:/tmp
- data_store:/data/store
command:
- bash
- "-c"
- |
set -e
/usr/local/script/wait-for-storage.sh hstore 6440 zookeeper 2181 600
/usr/local/bin/hstream-server
--host 0.0.0.0 --port 6572
--internal-port 6573
--server-id 101
--seed-nodes "hserver0:6571,$$(hostname -I | awk '{print $$1}'):6573"
--address $$(hostname -I | awk '{print $$1}')
--zkuri zookeeper:2181
--store-config /data/store/logdevice.conf
--store-admin-host hstore --store-admin-port 6440
--io-tasks-path /tmp/io/tasks
--io-tasks-network hstream-quickstart

hserver-init:
image: hstreamdb/hstream:0.10.0-SNAPSHOT
depends_on:
- hserver0
- hserver1
networks:
- hstream-quickstart
command:
- bash
- "-c"
- |
timeout=60
until (
/usr/local/bin/hadmin server --host hserver0 --port 6570 status &&
/usr/local/bin/hadmin server --host hserver1 --port 6572 status
) >/dev/null 2>&1; do
>&2 echo 'Waiting for servers ...'
sleep 1
timeout=$$((timeout - 1))
[ $$timeout -le 0 ] && echo 'Timeout!' && exit 1;
done;
/usr/local/bin/hadmin server --host hserver0 init

hstore:
image: hstreamdb/hstream:v0.10.0-SNAPSHOT
networks:
- hstream-quickstart
volumes:
- data_store:/data/store
command:
- bash
- "-c"
- |
set -ex
/usr/local/bin/ld-dev-cluster --root /data/store
--use-tcp --tcp-host $$(hostname -I | awk '{print $$1}')
--user-admin-port 6440
--no-interactive

zookeeper:
image: zookeeper
expose:
- 2181
networks:
- hstream-quickstart
volumes:
- data_zk_data:/data
- data_zk_datalog:/datalog

networks:
hstream-quickstart:
name: hstream-quickstart

volumes:
data_store:
name: quickstart_data_store
data_zk_data:
name: quickstart_data_zk_data
data_zk_datalog:
name: quickstart_data_zk_datalog

from hstream.

s12f avatar s12f commented on May 24, 2024

@sc-aniagr hstream is server, and hstreamdb-java is java client to connect the server.

Please use this docker-compose file to setup hstream servers:

version: "3.5"

services:
  hserver0:
    image: hstreamdb/hstream
    depends_on:
      - zookeeper
      - hstore
    ports:
      - "127.0.0.1:6570:6570"
    expose:
      - 6570
    networks:
      - hstream-quickstart
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
      - /tmp:/tmp
      - data_store:/data/store
    command:
      - bash
      - "-c"
      - |
        set -e
        /usr/local/script/wait-for-storage.sh hstore 6440 zookeeper 2181 600 \
        /usr/local/bin/hstream-server \
        --host 0.0.0.0 --port 6570 \
        --internal-port 6571 \
        --server-id 100 \
        --seed-nodes "hserver0:6571,hserver1:6573" \
        --address $$(hostname -I | awk '{print $$1}') \
        --meta-store zk://zookeeper:2181 \
        --store-config /data/store/logdevice.conf \
        --store-admin-host hstore --store-admin-port 6440 \
        --io-tasks-path /tmp/io/tasks \
        --io-tasks-network hstream-quickstart

  hserver1:
    image: hstreamdb/hstream
    depends_on:
      - zookeeper
      - hstore
    ports:
      - "127.0.0.1:6572:6572"
    expose:
      - 6572
    networks:
      - hstream-quickstart
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
      - /tmp:/tmp
      - data_store:/data/store
    command:
      - bash
      - "-c"
      - |
        set -e
        /usr/local/script/wait-for-storage.sh hstore 6440 zookeeper 2181 600 \
        /usr/local/bin/hstream-server \
        --host 0.0.0.0 --port 6572 \
        --internal-port 6573 \
        --server-id 101 \
        --seed-nodes "hserver0:6571,hserver1:6573" \
        --address $$(hostname -I | awk '{print $$1}') \
        --meta-store zk://zookeeper:2181 \
        --store-config /data/store/logdevice.conf \
        --store-admin-host hstore --store-admin-port 6440 \
        --io-tasks-path /tmp/io/tasks \
        --io-tasks-network hstream-quickstart

  hserver-init:
    image: hstreamdb/hstream
    depends_on:
      - hserver0
      - hserver1
    networks:
      - hstream-quickstart
    command:
      - bash
      - "-c"
      - |
        timeout=60
        until ( \
            /usr/local/bin/hadmin server --host hserver0 --port 6570 status && \
            /usr/local/bin/hadmin server --host hserver1 --port 6572 status \
        ) >/dev/null 2>&1; do
            >&2 echo 'Waiting for servers ...'
            sleep 1
            timeout=$$((timeout - 1))
            [ $$timeout -le 0 ] && echo 'Timeout!' && exit 1;
        done; \
        /usr/local/bin/hadmin server --host hserver0 init

  hstore:
    image: hstreamdb/hstream
    networks:
      - hstream-quickstart
    volumes:
      - data_store:/data/store
    command:
      - bash
      - "-c"
      - |
        set -ex
        /usr/local/bin/ld-dev-cluster --root /data/store \
        --use-tcp --tcp-host $$(hostname -I | awk '{print $$1}') \
        --user-admin-port 6440 \
        --no-interactive

  zookeeper:
    image: zookeeper
    expose:
      - 2181
    networks:
      - hstream-quickstart
    volumes:
      - data_zk_data:/data
      - data_zk_datalog:/datalog

networks:
  hstream-quickstart:
    name: hstream-quickstart

volumes:
  data_store:
    name: quickstart_data_store
  data_zk_data:
    name: quickstart_data_zk_data
  data_zk_datalog:
    name: quickstart_data_zk_datalog

and update your hstreamdb-java dependency in maven config file(pom.xml) to 0.10.0-SNAPSHOT version, e.g.:

    <repositories>
        <repository>
            <id>sonatypeSnapshots</id>
            <name>Sonatype Snapshots</name>
            <releases>
                <enabled>false</enabled>
            </releases>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
            <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
        </repository>
    </repositories>

    <dependencies>
        <dependency>
            <groupId>io.hstream</groupId>
            <artifactId>hstreamdb-java</artifactId>
            <version>0.10.0-SNAPSHOT</version>
        </dependency>
    </dependencies

from hstream.

4eUeP avatar 4eUeP commented on May 24, 2024

Close since the new java client had already been published.

from hstream.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.