Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Alexis Hernandez
    @AlexITC
    No, but I found the solution, the reason it failed was that the app was stopping before the actual request completed (it was async code), blocking until the call worked solved the issued on the PoC I was working on, thanks
    Pavan Kumar
    @pavankumar526
    @ejona86 Thanks for the reply. Where should I set this service config? I am confused and not able to find related documentation. Can you provide me an example?
    Eric Anderson
    @ejona86
    @pavankumar526, that is a method on ManagedChannelBuilder. The hedging example sets a service config.
    Colton Wyman
    @Coltux
    I am trying to implement an asynchronous distributed algorithm (GHS) for a class of mine and I have to use grpc and docker compose. I am running into an issue however. The algorithm requires a message queue to place back received messages to be processed later if they cant be processed at the moment. So the issue I am having is that when I create a dequeue (using python here btw) to store received messages, and message that gets placed back on the end of the queue reaches a point where it is the only message on the queue and end up just placing itself back and causing a loop of processing the message, seeing that it can't be dealt with currently, and then reading it again. Now this is blocking any new messages from coming in and causing problems as the node (server) is constantly busy going over the same message but I also can't just ignore the message or it wont work. Any insight on how to deal with that would be greatly appreciated
    Pavan Kumar
    @pavankumar526
    @ejona86 Thanks again for the info. But still not able to successfully use client-side health checking. What all things a user should need to do to enable health checks end to end? Please ping me when you are online. I will come online immediately to further discuss this. Thanks a lot for helping me out.
    ubu
    @uburoiubu
    Hi there. Could anybody help with the following issue:
    protocolbuffers/protobuf#6987
    Eric Anderson
    @ejona86
    @uburoiubu, I think protobuf needs to weigh in on it. I know it has handling for some of those situations, but maybe not in your case.
    TomislavTbtl
    @TomislavTbtl
    @AlexITC Thanks for the reply. I had another problem that had the same consequence. I forgot to add the alpn protocols.
    ubu
    @uburoiubu
    @ejona86 thanks, i'll be waiting.
    Colton Wyman
    @Coltux
    Is anyone available for some help?
    I am having an issue sending a shutdown message
    Thib
    @Horneth

    Hi, could anyone help clarify this comment ? https://github.com/grpc/grpc-java/blob/master/examples/src/main/java/io/grpc/examples/manualflowcontrol/ManualFlowControlClient.java#L76 In this case does "gRPC thread" refers to the "underlying IO gRPC thread pool" (named something like grpc-nio-worker... in case of Netty at least), or the application executor thread pool (which is what appears to be the case) ?
    Follow up question is if I'm understanding correctly in this example, the client will send messages to the server as long as the server says it's ready, and then only start processing incoming messages, is that right ?
    So the actual flow looks something like

    Outgoing:
    ================> (isReady = false)         (isReady = true) =========================>
    Incoming:
                        <==============================

    At least from my testing it doesn't look like the onReadyHandler runs concurrently with the incoming stream observer. This https://github.com/grpc/grpc-java/blob/master/examples/src/main/java/io/grpc/examples/manualflowcontrol/ManualFlowControlClient.java#L66 says they're serialized on the same thread pool but not on the same thread, or do I read this wrong ?

    Thib
    @Horneth
    Nvm I think I answered my own question, I misunderstood what "serialized on the same thread pool" means.
    ColdMeekly
    @ColdMeekly

    Would anyone know the best way to solve the following issue?

    server/main.cc:2:10: fatal error: login.pb.h: No such file or directory
     #include "login.pb.h"
              ^~~~~~~~~~~~

    I'm following all of the tutorials out there to build with bazel and none of the examples are working

    This is my BUILD file:

    load("@rules_cc//cc:defs.bzl", "cc_binary", "cc_proto_library")
    load("@rules_proto//proto:defs.bzl", "proto_library")
    
    filegroup(
        name = "srcs",
        srcs = glob(["**"]),
        visibility = ["//visibility:public"],
    )
    
    proto_library(
            name = "login_proto",
            srcs = ["login.proto"],
    )
    
    cc_proto_library(
            name = "login_cc_proto",
            deps = [":login_proto"],
    )
    
    cc_binary(
            name = "server",
            srcs = ["main.cc"],
            deps = [":login_cc_proto"],
    )

    Pretty much carbon copy from the https://github.com/bazelbuild/bazel/tree/master/third_party/protobuf/3.6.1/examples page as far as I can see

    ColdMeekly
    @ColdMeekly
    I've only found one related stackoverflow question being raised, his problem was forgetting to add dependency to the proto_library in cc_proto_library. Am I the only person who is experiencing this issue?! Surely not
    Eric Anderson
    @ejona86
    @ColdMeekly, you need to fully qualify the include. It needs all folders that exist between your WORKSPACE and the BUILD file.
    ColdMeekly
    @ColdMeekly
    @ejona86 Would that work correctly? The login.pb.h file is generated to the build directory by the protoc compiler in bazel. I don't know if I'll be able to access that directory from within the project
    Gursimran Singh
    @gnarmis
    hi, I'm curious if all grpc-core's log messages flow through the logging setup I can access in my python grpc services? I'm trying to use python logging formatters and filters but can't seem to control core's log message except very minimally via GRPC_VERBOSITY
    Eric Anderson
    @ejona86
    The directory is virtualized by Bazel
    @gnarmis, I wouldn't expect the logging to go through python's logging apis.
    Gursimran Singh
    @gnarmis
    @ejona86 gotcha that confirms my hunch after some fiddling. Are there any other ways other than the env vars to get control over them?
    Eric Anderson
    @ejona86
    I don't think so.
    ColdMeekly
    @ColdMeekly

    Alright, so in my situation this is the directory structure:

    ├── WORKSPACE
    ├── WORKSPACE~
    ├── bazel-JaCa -> /home/coldmeekly/.cache/bazel/_bazel_coldmeekly/65500f9eed0925e4b4e450cd85988252/execroot/__main__
    ├── bazel-bin -> /home/coldmeekly/.cache/bazel/_bazel_coldmeekly/65500f9eed0925e4b4e450cd85988252/execroot/__main__/bazel-out/k8-fastbuild/bin
    ├── bazel-out -> /home/coldmeekly/.cache/bazel/_bazel_coldmeekly/65500f9eed0925e4b4e450cd85988252/execroot/__main__/bazel-out
    ├── bazel-testlogs -> /home/coldmeekly/.cache/bazel/_bazel_coldmeekly/65500f9eed0925e4b4e450cd85988252/execroot/__main__/bazel-out/k8-fastbuild/testlogs
    └── server
        ├── BUILD
        ├── BUILD~
        ├── login.proto
        ├── main.cc
        └── main.cc~

    I'm going to try and include #include "server/login.pb.h" and see if that is what you meant by virtualised

    Unless you are suggesting to include the bazel-bin directory
    Eric Anderson
    @ejona86
    @ColdMeekly, yeah, try that path.
    No, not bazel-bin
    ColdMeekly
    @ColdMeekly
    Eric
    I love you
    Eric Anderson
    @ejona86
    @ColdMeekly, I assume that means it worked :-P
    ColdMeekly
    @ColdMeekly
    Yup! I'm surprised none of the tutorials mentioned this fact
    I guess it's because it's all in the same folder as the workspace
    Anyway, if you want a coffee on me lmk ;)
    Eric Anderson
    @ejona86
    The examples in general don't go into Bazel too much. Although I would expect C++ to go into it a bit more than most other languages. I do see some hints in the example for c++. But you sort of have to reverse-engineer why that string was used.
    I'll make one other note: the location of the proto_library is the thing that matters. Not the location of cc_proto_library.
    (Although the location of cc_grpc_library may matter)
    ColdMeekly
    @ColdMeekly
    Oh, thanks. That's something I had assumed since it loads proto_library into bazel, and cc_proto_library is just working with the data already loaded
    ColdMeekly
    @ColdMeekly
    @ejona86 Would you happen to know the reason behind relying on HTTP/2 ? It'd be interesting to find out why so many libraries are using it
    xin-au
    @xin-au
    Hi All, wondering how grpc java client behaviors if there is no keepalive and the client gets goaway ? Do we need to recreate a connection or this gets handled by grpc-java client?
    Eric Anderson
    @ejona86
    @xin-au, the client will naturally create a new connection. Lack of keepalive just means the old (and new) connection may die without the client becoming aware.
    (Which mostly affects old RPCs. New RPCs are generally fine.)
    xin-au
    @xin-au
    @ejona86 , Thank you so much!
    New RPCs means new version grpc java client?
    So, seems it is an exception for the goawayin client side, wondering what should I do for goaway exception?
    Eric Anderson
    @ejona86
    @xin-au, not a new version of the grpc java client. I mean, let's say you do 50 RPCs. After the first 25 grpc receives a GOAWAY. Then grpc will use a new connection for the next 25.
    GOAWAY is generally handled without being exposed to the application. But sometimes it may show up with an UNAVAILABLE status.
    xin-au
    @xin-au
    @ejona86 , got it. Thank you so much!
    Jinto Thomas
    @jinto-thomas
    I am new to gRPC, is there any health check java examples I could refer to? My understanding is once the client is connected to a stream server, it should keep on receiving status messages. Is it a wrong assumption?
    Eric Anderson
    @ejona86
    @jinto-thomas, what sort of health check do you want? I'm not sure what you mena by "status messages"
    Jinto Thomas
    @jinto-thomas
    @ejona86 apologies for not being specific.I saw in grpc java repo status like - serving ok, not serving .
    I have a simple stream server in which I'm sending n number of responses. My client exit after receiving this n number of responses. Can I use a while loop in my server so that the client never exit?