我安装了ubuntu 14.04虚拟机并运行docker(1.11.2).我尝试建立样本图像(这里).
泊坞文件:
FROM java:8
# Install maven
RUN apt-get update
RUN apt-get install -y maven
....
Run Code Online (Sandbox Code Playgroud)
我收到以下错误:
Step 3: RUN apt-get update
--> Using cache
--->64345sdd332
Step 4: RUN apt-get install -y maven
---> Running in a6c1d5d54b7a
Reading package lists...
Reading dependency tree...
Reading state information...
E: Unable to locate package maven
INFO[0029] The command [/bin/sh -c apt-get install -y maven] returned a non-zero code:100
Run Code Online (Sandbox Code Playgroud)
我试过以下解决方案,但没有成功.
如何查看详细的错误消息?有什么方法可以解决这个问题吗?
我们正计划将我们现有的服务迁移到 grpc 服务。所以需要将服务转换为原型定义的消息类型。在响应中,我们以自定义对象为键进行映射。
例如回应:
//java
Map<key_object, Project>
//proto
map<key_object_not_supported, Project> projects = 3;
Run Code Online (Sandbox Code Playgroud)
在官方文档中,他们提到,
其中 key_type 可以是任何整数或字符串类型(因此,除了浮点类型和字节之外,任何标量类型)。value_type 可以是任何类型
是否有其他方法可以在 proto3 中实现自定义对象键映射?