0

My .proto file:

package com.xxxxx.cloud.module.proxy.protobuf;

option java_package = "com.xxxxx.cloud.module.proxy.protobuf";
option java_outer_classname = "ProxyHttpProtocol";

message Request{
    required string domain = 1;
    required string url = 2;
    required string body = 3;
    required int32 port = 4;
    required string method = 5;
}

some errors in java source code:

1、throw e.setUnfinishedMessage(this);//Could not find symbol
2、makeExtensionsImmutable(); //cloud not find symbol
3、ensureFieldAccessorsInitialized //cloud not find symbol
....more

I can't find any documentation to explain the reasons for these errors.

1 Answer 1

1

This sounds like you're missing the protobuf-java jar-file in your buildpath. You can either create it yourself by downloading the protobuf sources and running mvn package in the java directory of the download, or directly download the jar-file from the maven central repository.

Once you have the jar file, just add it to your project (either as maven dependency, or directly including it in your build path, depending on your setup).

Sign up to request clarification or add additional context in comments.

1 Comment

Thank you for your answer, You said I was ready, I checked the source code for protobuf-java, there is really no found

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.