Spec

Version Change Specification

Legacy version annotations from version.proto, kept for compatibility audits and older projects.

apihug/protobuf/extend/version.proto still exists in the current source, but the file is marked deprecated. New projects should prefer milestone and changelog documentation for human release notes, but older proto contracts may still carry these annotations.

  • Extension Package: apihug/protobuf/extend/version.proto
  • Scope: File / Service / Method / Message / Enum / Field
  • Status: Deprecated compatibility layer

1. Import and Registration

Proto
import "apihug/protobuf/extend/version.proto";

Registered extension points:

DescriptorExtension pointField numberValue type
FileOptions(hope.version.file)31142repeated Version
MethodOptions(hope.version.method)31142repeated Version
MessageOptions(hope.version.msg)31143repeated Version
ServiceOptions(hope.version.svc)31143repeated Version
EnumOptions(hope.version.enm)31143repeated Version
FieldOptions(hope.version.field)31143repeated Version

31142 is reused for file and method descriptors, and 31143 is reused for message, service, enum, and field descriptors. That is valid because each registration targets a different protobuf descriptor type.


2. VersionTypeEnum

Proto
enum VersionTypeEnum {
  NA = 0;
  ADD = 1;
  MODIFY = 2;
  REMOVE = 3;
}
Enum ValueMeaning
NANo explicit change type
ADDAdded in this version
MODIFYChanged in this version
REMOVERemoved in this version

3. Version Message

Proto
message Version {
  string version = 1;
  string timestamp = 2;
  VersionTypeEnum type = 10;
  string message = 11;
  string track = 12;
  string updated_by = 20;
}
FieldTypeDescription
versionstringVersion identifier such as 2.0.0-RELEASE
timestampstringChange timestamp
typeVersionTypeEnumAdd / modify / remove marker
messagestringHuman-readable change note
trackstringExternal ticket or issue id
updated_bystringMaintainer name

4. Example

Proto
import "apihug/protobuf/extend/version.proto";

service UserApi {
  option (hope.version.svc) = [{
    version: "2.0.0-RELEASE";
    timestamp: "2025-05-15";
    type: MODIFY;
    message: "Merged legacy proto/app split into unified app module";
    track: "MILESTONE-2.0.0";
    updated_by: "Aaron";
  }];
}

5. Practical Guidance

  • Keep reading these annotations when auditing old proto files.
  • Do not introduce new hope.version.* usage unless you are maintaining backward compatibility with an existing contract.
  • Prefer Milestone and Changelog pages for current release history.
Copyright © 2026 ApiHug·AI-native Enterprise Architecture Factory