From bd9336441c91a2aa7c4ca23690c86c38afa3f8d0 Mon Sep 17 00:00:00 2001 From: tarumi Date: Thu, 2 Nov 2023 22:04:34 +0100 Subject: [PATCH] rm isRegistrable query --- docs/static/openapi.yml | 50 -- proto/mycel/registry/query.proto | 17 - x/registry/client/cli/query.go | 3 - .../client/cli/query_is_registrable_domain.go | 48 -- .../keeper/query_is_registrable_domain.go | 36 -- x/registry/types/query.pb.go | 604 ++---------------- x/registry/types/query.pb.gw.go | 123 ---- 7 files changed, 65 insertions(+), 816 deletions(-) delete mode 100644 x/registry/client/cli/query_is_registrable_domain.go delete mode 100644 x/registry/keeper/query_is_registrable_domain.go diff --git a/docs/static/openapi.yml b/docs/static/openapi.yml index fba529f6..19bb2779 100644 --- a/docs/static/openapi.yml +++ b/docs/static/openapi.yml @@ -50261,49 +50261,6 @@ paths: format: uint64 tags: - Query - /mycel-domain/mycel/registry/is_registrable_domain/{name}/{parent}: - get: - summary: Queries a list of IsRegistrableDomain items. - operationId: MycelRegistryIsRegistrableDomain - responses: - '200': - description: A successful response. - schema: - type: object - properties: - isRegstrable: - type: boolean - errorMessage: - type: string - default: - description: An unexpected error response. - schema: - type: object - properties: - code: - type: integer - format: int32 - message: - type: string - details: - type: array - items: - type: object - properties: - '@type': - type: string - additionalProperties: {} - parameters: - - name: name - in: path - required: true - type: string - - name: parent - in: path - required: true - type: string - tags: - - Query /mycel-domain/mycel/registry/top_level_domain: get: operationId: MycelRegistryTopLevelDomainAll @@ -81973,13 +81930,6 @@ definitions: method signatures required by gogoproto. - mycel.registry.QueryIsRegistrableDomainResponse: - type: object - properties: - isRegstrable: - type: boolean - errorMessage: - type: string mycel.registry.QueryParamsResponse: type: object properties: diff --git a/proto/mycel/registry/query.proto b/proto/mycel/registry/query.proto index b7ed0f0c..3234346d 100644 --- a/proto/mycel/registry/query.proto +++ b/proto/mycel/registry/query.proto @@ -57,12 +57,6 @@ service Query { option (google.api.http).get = "/mycel-domain/mycel/registry/domain_registration_fee/{name}/{parent}"; } - - // Queries a list of IsRegistrableDomain items. - rpc IsRegistrableDomain (QueryIsRegistrableDomainRequest) returns (QueryIsRegistrableDomainResponse) { - option (google.api.http).get = "/mycel-domain/mycel/registry/is_registrable_domain/{name}/{parent}"; - - } } // QueryParamsRequest is request type for the Query/Params RPC method. message QueryParamsRequest {} @@ -148,14 +142,3 @@ message QueryDomainRegistrationFeeResponse { uint64 maxSubDomainRegistrations = 4; string errorMessage = 5; } - -message QueryIsRegistrableDomainRequest { - string name = 1; - string parent = 2; -} - -message QueryIsRegistrableDomainResponse { - bool isRegstrable = 1; - string errorMessage = 2; -} - diff --git a/x/registry/client/cli/query.go b/x/registry/client/cli/query.go index 9c3676c1..bdc753d2 100644 --- a/x/registry/client/cli/query.go +++ b/x/registry/client/cli/query.go @@ -32,9 +32,6 @@ func GetQueryCmd(queryRoute string) *cobra.Command { cmd.AddCommand(CmdListDomainOwnership()) cmd.AddCommand(CmdShowDomainOwnership()) cmd.AddCommand(CmdDomainRegistrationFee()) - - cmd.AddCommand(CmdIsRegistrableDomain()) - cmd.AddCommand(CmdListTopLevelDomain()) cmd.AddCommand(CmdShowTopLevelDomain()) // this line is used by starport scaffolding # 1 diff --git a/x/registry/client/cli/query_is_registrable_domain.go b/x/registry/client/cli/query_is_registrable_domain.go deleted file mode 100644 index 64688205..00000000 --- a/x/registry/client/cli/query_is_registrable_domain.go +++ /dev/null @@ -1,48 +0,0 @@ -package cli - -import ( - "strconv" - - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/mycel-domain/mycel/x/registry/types" - "github.com/spf13/cobra" -) - -var _ = strconv.Itoa(0) - -func CmdIsRegistrableDomain() *cobra.Command { - cmd := &cobra.Command{ - Use: "is-registrable-domain [name] [parent]", - Short: "query a domain is registrable", - Args: cobra.ExactArgs(2), - RunE: func(cmd *cobra.Command, args []string) (err error) { - reqName := args[0] - reqParent := args[1] - - clientCtx, err := client.GetClientQueryContext(cmd) - if err != nil { - return err - } - - queryClient := types.NewQueryClient(clientCtx) - - params := &types.QueryIsRegistrableDomainRequest{ - - Name: reqName, - Parent: reqParent, - } - - res, err := queryClient.IsRegistrableDomain(cmd.Context(), params) - if err != nil { - return err - } - - return clientCtx.PrintProto(res) - }, - } - - flags.AddQueryFlagsToCmd(cmd) - - return cmd -} diff --git a/x/registry/keeper/query_is_registrable_domain.go b/x/registry/keeper/query_is_registrable_domain.go deleted file mode 100644 index db8db978..00000000 --- a/x/registry/keeper/query_is_registrable_domain.go +++ /dev/null @@ -1,36 +0,0 @@ -package keeper - -import ( - "context" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/mycel-domain/mycel/x/registry/types" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" -) - -func (k Keeper) IsRegistrableDomain(goCtx context.Context, req *types.QueryIsRegistrableDomainRequest) (*types.QueryIsRegistrableDomainResponse, error) { - if req == nil { - return nil, status.Error(codes.InvalidArgument, "invalid request") - } - ctx := sdk.UnwrapSDKContext(goCtx) - - if req.Parent == "" { - // Top level domain - domain := types.TopLevelDomain{Name: req.Name} - err := k.ValidateTopLevelDomainIsRegistrable(ctx, domain) - if err != nil { - return &types.QueryIsRegistrableDomainResponse{IsRegstrable: false, ErrorMessage: err.Error()}, nil - } - - } else { - // Second level domain - domain := types.SecondLevelDomain{Name: req.Name, Parent: req.Parent} - err := k.ValidateSecondLevelDomainIsRegistrable(ctx, domain) - if err != nil { - return &types.QueryIsRegistrableDomainResponse{IsRegstrable: false, ErrorMessage: err.Error()}, nil - } - } - - return &types.QueryIsRegistrableDomainResponse{IsRegstrable: true, ErrorMessage: ""}, nil -} diff --git a/x/registry/types/query.pb.go b/x/registry/types/query.pb.go index ff9c6653..c145e1b2 100644 --- a/x/registry/types/query.pb.go +++ b/x/registry/types/query.pb.go @@ -871,110 +871,6 @@ func (m *QueryDomainRegistrationFeeResponse) GetErrorMessage() string { return "" } -type QueryIsRegistrableDomainRequest struct { - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - Parent string `protobuf:"bytes,2,opt,name=parent,proto3" json:"parent,omitempty"` -} - -func (m *QueryIsRegistrableDomainRequest) Reset() { *m = QueryIsRegistrableDomainRequest{} } -func (m *QueryIsRegistrableDomainRequest) String() string { return proto.CompactTextString(m) } -func (*QueryIsRegistrableDomainRequest) ProtoMessage() {} -func (*QueryIsRegistrableDomainRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_0f2c8f2d33ba1956, []int{17} -} -func (m *QueryIsRegistrableDomainRequest) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *QueryIsRegistrableDomainRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_QueryIsRegistrableDomainRequest.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *QueryIsRegistrableDomainRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_QueryIsRegistrableDomainRequest.Merge(m, src) -} -func (m *QueryIsRegistrableDomainRequest) XXX_Size() int { - return m.Size() -} -func (m *QueryIsRegistrableDomainRequest) XXX_DiscardUnknown() { - xxx_messageInfo_QueryIsRegistrableDomainRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_QueryIsRegistrableDomainRequest proto.InternalMessageInfo - -func (m *QueryIsRegistrableDomainRequest) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *QueryIsRegistrableDomainRequest) GetParent() string { - if m != nil { - return m.Parent - } - return "" -} - -type QueryIsRegistrableDomainResponse struct { - IsRegstrable bool `protobuf:"varint,1,opt,name=isRegstrable,proto3" json:"isRegstrable,omitempty"` - ErrorMessage string `protobuf:"bytes,2,opt,name=errorMessage,proto3" json:"errorMessage,omitempty"` -} - -func (m *QueryIsRegistrableDomainResponse) Reset() { *m = QueryIsRegistrableDomainResponse{} } -func (m *QueryIsRegistrableDomainResponse) String() string { return proto.CompactTextString(m) } -func (*QueryIsRegistrableDomainResponse) ProtoMessage() {} -func (*QueryIsRegistrableDomainResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0f2c8f2d33ba1956, []int{18} -} -func (m *QueryIsRegistrableDomainResponse) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *QueryIsRegistrableDomainResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_QueryIsRegistrableDomainResponse.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *QueryIsRegistrableDomainResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_QueryIsRegistrableDomainResponse.Merge(m, src) -} -func (m *QueryIsRegistrableDomainResponse) XXX_Size() int { - return m.Size() -} -func (m *QueryIsRegistrableDomainResponse) XXX_DiscardUnknown() { - xxx_messageInfo_QueryIsRegistrableDomainResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_QueryIsRegistrableDomainResponse proto.InternalMessageInfo - -func (m *QueryIsRegistrableDomainResponse) GetIsRegstrable() bool { - if m != nil { - return m.IsRegstrable - } - return false -} - -func (m *QueryIsRegistrableDomainResponse) GetErrorMessage() string { - if m != nil { - return m.ErrorMessage - } - return "" -} - func init() { proto.RegisterType((*QueryParamsRequest)(nil), "mycel.registry.QueryParamsRequest") proto.RegisterType((*QueryParamsResponse)(nil), "mycel.registry.QueryParamsResponse") @@ -993,82 +889,76 @@ func init() { proto.RegisterType((*QueryAllDomainOwnershipResponse)(nil), "mycel.registry.QueryAllDomainOwnershipResponse") proto.RegisterType((*QueryDomainRegistrationFeeRequest)(nil), "mycel.registry.QueryDomainRegistrationFeeRequest") proto.RegisterType((*QueryDomainRegistrationFeeResponse)(nil), "mycel.registry.QueryDomainRegistrationFeeResponse") - proto.RegisterType((*QueryIsRegistrableDomainRequest)(nil), "mycel.registry.QueryIsRegistrableDomainRequest") - proto.RegisterType((*QueryIsRegistrableDomainResponse)(nil), "mycel.registry.QueryIsRegistrableDomainResponse") } func init() { proto.RegisterFile("mycel/registry/query.proto", fileDescriptor_0f2c8f2d33ba1956) } var fileDescriptor_0f2c8f2d33ba1956 = []byte{ - // 1083 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x97, 0xcf, 0x6f, 0xdc, 0x44, - 0x14, 0xc7, 0xe3, 0x6c, 0x12, 0xd1, 0xa1, 0x4a, 0x95, 0x69, 0x88, 0x36, 0x06, 0x9c, 0x30, 0x55, - 0x4b, 0x00, 0xc5, 0x93, 0x1f, 0x4d, 0x91, 0xa0, 0x1c, 0x12, 0xa2, 0x94, 0x42, 0x4a, 0x83, 0xcb, - 0x05, 0xa4, 0x2a, 0xf2, 0xee, 0xbe, 0x3a, 0x06, 0xaf, 0xc7, 0xf1, 0x38, 0x25, 0x51, 0x94, 0x4b, - 0xaf, 0x5c, 0x90, 0xf8, 0x27, 0x00, 0xc1, 0x01, 0x24, 0xc4, 0x81, 0x2b, 0x48, 0x95, 0xe0, 0x50, - 0x89, 0x0b, 0x27, 0x40, 0x09, 0x7f, 0x08, 0xf2, 0x78, 0x4c, 0xd6, 0xb3, 0x1e, 0x67, 0x37, 0xdd, - 0x53, 0x1c, 0xbf, 0x1f, 0xf3, 0x79, 0xdf, 0x79, 0x9e, 0x37, 0x8b, 0xcc, 0xf6, 0x41, 0x13, 0x02, - 0x1a, 0x83, 0xe7, 0xf3, 0x24, 0x3e, 0xa0, 0xbb, 0x7b, 0x10, 0x1f, 0xd8, 0x51, 0xcc, 0x12, 0x86, - 0xc7, 0x85, 0xcd, 0xce, 0x6d, 0xe6, 0xa4, 0xc7, 0x3c, 0x26, 0x4c, 0x34, 0x7d, 0xca, 0xbc, 0xcc, - 0x17, 0x3c, 0xc6, 0xbc, 0x00, 0xa8, 0x1b, 0xf9, 0xd4, 0x0d, 0x43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 0x11, 0xdf, 0x18, 0x13, 0xbf, 0xca, 0x97, 0xff, 0x0b, 0x00, - 0x00, 0xff, 0xff, 0xff, 0x0a, 0xf1, 0x20, 0xd8, 0x10, 0x00, 0x00, + // 1024 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x97, 0xcf, 0x4f, 0x24, 0x45, + 0x14, 0xc7, 0x69, 0x06, 0x88, 0xfb, 0x34, 0x6c, 0x28, 0x91, 0x0c, 0xa3, 0x36, 0x58, 0x9b, 0x5d, + 0x51, 0x43, 0x17, 0x3f, 0x96, 0x35, 0xd1, 0xf5, 0x00, 0x12, 0x56, 0x23, 0xba, 0xd8, 0xeb, 0x45, + 0x93, 0x0d, 0xe9, 0x99, 0xa9, 0x6d, 0x5a, 0x7b, 0xba, 0x9a, 0xae, 0x66, 0x85, 0x10, 0x2e, 0x7b, + 0xf5, 0x62, 0xe2, 0x3f, 0xa1, 0x46, 0x0f, 0x1e, 0x8c, 0x07, 0xcf, 0x26, 0x9b, 0xe8, 0x61, 0x13, + 0x2f, 0x9e, 0xd4, 0x80, 0x37, 0xff, 0x09, 0xd3, 0x55, 0xd5, 0x61, 0xba, 0xa6, 0xab, 0x99, 0xc1, + 0x39, 0xd1, 0xf4, 0xfb, 0x51, 0x9f, 0xf7, 0xad, 0xd7, 0xf5, 0x6a, 0xa0, 0xd1, 0x39, 0x6a, 0xd1, + 0x90, 0x24, 0xd4, 0x0f, 0x78, 0x9a, 0x1c, 0x91, 0xfd, 0x03, 0x9a, 0x1c, 0x39, 0x71, 0xc2, 0x52, + 0x86, 0x26, 0x85, 0xcd, 0xc9, 0x6d, 0x8d, 0x69, 0x9f, 0xf9, 0x4c, 0x98, 0x48, 0xf6, 0x24, 0xbd, + 0x1a, 0x2f, 0xf8, 0x8c, 0xf9, 0x21, 0x25, 0x5e, 0x1c, 0x10, 0x2f, 0x8a, 0x58, 0xea, 0xa5, 0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x6c, 0xc8, 0xf2, 0xd9, 0xd2, 0x20, 0x7d, 0xfb, 0x2b, + 0xc2, 0xb7, 0x04, 0xe1, 0xeb, 0x68, 0xad, 0xb2, 0x1d, 0xf4, 0x9f, 0x18, 0xe4, 0x58, 0x3c, 0x9e, + 0xa0, 0xef, 0x2c, 0x40, 0x5a, 0xea, 0x4c, 0x5c, 0x63, 0x53, 0x0e, 0x84, 0x6d, 0x9e, 0x6b, 0x7d, + 0x76, 0xb1, 0x8e, 0x8d, 0x7e, 0xb3, 0xe0, 0xb9, 0xd2, 0x13, 0x1e, 0x95, 0x6f, 0x6e, 0xd5, 0x6c, + 0x6a, 0xac, 0x0c, 0x12, 0xa2, 0xb8, 0xb7, 0x05, 0xf7, 0x16, 0xda, 0xec, 0x87, 0xbb, 0xfb, 0x1c, + 0xdf, 0x7d, 0x40, 0xa9, 0xde, 0xdc, 0x1b, 0xef, 0x3c, 0x3e, 0xb5, 0xad, 0x27, 0xa7, 0xb6, 0xf5, + 0xf7, 0xa9, 0x6d, 0x7d, 0x79, 0x66, 0x8f, 0x3c, 0x39, 0xb3, 0x47, 0xfe, 0x38, 0xb3, 0x47, 0x3e, + 0x71, 0xba, 0x86, 0x4a, 0xc9, 0x4a, 0x87, 0x5d, 0x5f, 0x7a, 0x36, 0x60, 0x9a, 0x13, 0xe2, 0x37, + 0xe1, 0xea, 0x7f, 0x01, 0x00, 0x00, 0xff, 0xff, 0xf2, 0x8c, 0x18, 0xa1, 0x56, 0x0f, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1096,8 +986,6 @@ type QueryClient interface { DomainOwnershipAll(ctx context.Context, in *QueryAllDomainOwnershipRequest, opts ...grpc.CallOption) (*QueryAllDomainOwnershipResponse, error) // Queries a list of DomainRegistrationFee items. DomainRegistrationFee(ctx context.Context, in *QueryDomainRegistrationFeeRequest, opts ...grpc.CallOption) (*QueryDomainRegistrationFeeResponse, error) - // Queries a list of IsRegistrableDomain items. - IsRegistrableDomain(ctx context.Context, in *QueryIsRegistrableDomainRequest, opts ...grpc.CallOption) (*QueryIsRegistrableDomainResponse, error) } type queryClient struct { @@ -1180,15 +1068,6 @@ func (c *queryClient) DomainRegistrationFee(ctx context.Context, in *QueryDomain return out, nil } -func (c *queryClient) IsRegistrableDomain(ctx context.Context, in *QueryIsRegistrableDomainRequest, opts ...grpc.CallOption) (*QueryIsRegistrableDomainResponse, error) { - out := new(QueryIsRegistrableDomainResponse) - err := c.cc.Invoke(ctx, "/mycel.registry.Query/IsRegistrableDomain", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - // QueryServer is the server API for Query service. type QueryServer interface { // Parameters queries the parameters of the module. @@ -1204,8 +1083,6 @@ type QueryServer interface { DomainOwnershipAll(context.Context, *QueryAllDomainOwnershipRequest) (*QueryAllDomainOwnershipResponse, error) // Queries a list of DomainRegistrationFee items. DomainRegistrationFee(context.Context, *QueryDomainRegistrationFeeRequest) (*QueryDomainRegistrationFeeResponse, error) - // Queries a list of IsRegistrableDomain items. - IsRegistrableDomain(context.Context, *QueryIsRegistrableDomainRequest) (*QueryIsRegistrableDomainResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. @@ -1236,9 +1113,6 @@ func (*UnimplementedQueryServer) DomainOwnershipAll(ctx context.Context, req *Qu func (*UnimplementedQueryServer) DomainRegistrationFee(ctx context.Context, req *QueryDomainRegistrationFeeRequest) (*QueryDomainRegistrationFeeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DomainRegistrationFee not implemented") } -func (*UnimplementedQueryServer) IsRegistrableDomain(ctx context.Context, req *QueryIsRegistrableDomainRequest) (*QueryIsRegistrableDomainResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method IsRegistrableDomain not implemented") -} func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) @@ -1388,24 +1262,6 @@ func _Query_DomainRegistrationFee_Handler(srv interface{}, ctx context.Context, return interceptor(ctx, in, info, handler) } -func _Query_IsRegistrableDomain_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(QueryIsRegistrableDomainRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(QueryServer).IsRegistrableDomain(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/mycel.registry.Query/IsRegistrableDomain", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(QueryServer).IsRegistrableDomain(ctx, req.(*QueryIsRegistrableDomainRequest)) - } - return interceptor(ctx, in, info, handler) -} - var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "mycel.registry.Query", HandlerType: (*QueryServer)(nil), @@ -1442,10 +1298,6 @@ var _Query_serviceDesc = grpc.ServiceDesc{ MethodName: "DomainRegistrationFee", Handler: _Query_DomainRegistrationFee_Handler, }, - { - MethodName: "IsRegistrableDomain", - Handler: _Query_IsRegistrableDomain_Handler, - }, }, Streams: []grpc.StreamDesc{}, Metadata: "mycel/registry/query.proto", @@ -2103,83 +1955,6 @@ func (m *QueryDomainRegistrationFeeResponse) MarshalToSizedBuffer(dAtA []byte) ( return len(dAtA) - i, nil } -func (m *QueryIsRegistrableDomainRequest) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *QueryIsRegistrableDomainRequest) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *QueryIsRegistrableDomainRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.Parent) > 0 { - i -= len(m.Parent) - copy(dAtA[i:], m.Parent) - i = encodeVarintQuery(dAtA, i, uint64(len(m.Parent))) - i-- - dAtA[i] = 0x12 - } - if len(m.Name) > 0 { - i -= len(m.Name) - copy(dAtA[i:], m.Name) - i = encodeVarintQuery(dAtA, i, uint64(len(m.Name))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *QueryIsRegistrableDomainResponse) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *QueryIsRegistrableDomainResponse) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *QueryIsRegistrableDomainResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.ErrorMessage) > 0 { - i -= len(m.ErrorMessage) - copy(dAtA[i:], m.ErrorMessage) - i = encodeVarintQuery(dAtA, i, uint64(len(m.ErrorMessage))) - i-- - dAtA[i] = 0x12 - } - if m.IsRegstrable { - i-- - if m.IsRegstrable { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x8 - } - return len(dAtA) - i, nil -} - func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset @@ -2451,39 +2226,6 @@ func (m *QueryDomainRegistrationFeeResponse) Size() (n int) { return n } -func (m *QueryIsRegistrableDomainRequest) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Name) - if l > 0 { - n += 1 + l + sovQuery(uint64(l)) - } - l = len(m.Parent) - if l > 0 { - n += 1 + l + sovQuery(uint64(l)) - } - return n -} - -func (m *QueryIsRegistrableDomainResponse) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - if m.IsRegstrable { - n += 2 - } - l = len(m.ErrorMessage) - if l > 0 { - n += 1 + l + sovQuery(uint64(l)) - } - return n -} - func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } @@ -4208,222 +3950,6 @@ func (m *QueryDomainRegistrationFeeResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *QueryIsRegistrableDomainRequest) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowQuery - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: QueryIsRegistrableDomainRequest: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: QueryIsRegistrableDomainRequest: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowQuery - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthQuery - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthQuery - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Name = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Parent", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowQuery - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthQuery - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthQuery - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Parent = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipQuery(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthQuery - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *QueryIsRegistrableDomainResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowQuery - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: QueryIsRegistrableDomainResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: QueryIsRegistrableDomainResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field IsRegstrable", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowQuery - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.IsRegstrable = bool(v != 0) - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ErrorMessage", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowQuery - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthQuery - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthQuery - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ErrorMessage = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipQuery(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthQuery - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 diff --git a/x/registry/types/query.pb.gw.go b/x/registry/types/query.pb.gw.go index acec3d52..5419ce78 100644 --- a/x/registry/types/query.pb.gw.go +++ b/x/registry/types/query.pb.gw.go @@ -437,82 +437,6 @@ func local_request_Query_DomainRegistrationFee_0(ctx context.Context, marshaler } -func request_Query_IsRegistrableDomain_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq QueryIsRegistrableDomainRequest - var metadata runtime.ServerMetadata - - var ( - val string - ok bool - err error - _ = err - ) - - val, ok = pathParams["name"] - if !ok { - return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "name") - } - - protoReq.Name, err = runtime.String(val) - - if err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "name", err) - } - - val, ok = pathParams["parent"] - if !ok { - return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "parent") - } - - protoReq.Parent, err = runtime.String(val) - - if err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "parent", err) - } - - msg, err := client.IsRegistrableDomain(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err - -} - -func local_request_Query_IsRegistrableDomain_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq QueryIsRegistrableDomainRequest - var metadata runtime.ServerMetadata - - var ( - val string - ok bool - err error - _ = err - ) - - val, ok = pathParams["name"] - if !ok { - return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "name") - } - - protoReq.Name, err = runtime.String(val) - - if err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "name", err) - } - - val, ok = pathParams["parent"] - if !ok { - return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "parent") - } - - protoReq.Parent, err = runtime.String(val) - - if err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "parent", err) - } - - msg, err := server.IsRegistrableDomain(ctx, &protoReq) - return msg, metadata, err - -} - // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -703,29 +627,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv }) - mux.Handle("GET", pattern_Query_IsRegistrableDomain_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { - ctx, cancel := context.WithCancel(req.Context()) - defer cancel() - var stream runtime.ServerTransportStream - ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) - inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) - if err != nil { - runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) - return - } - resp, md, err := local_request_Query_IsRegistrableDomain_0(rctx, inboundMarshaler, server, req, pathParams) - md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) - ctx = runtime.NewServerMetadataContext(ctx, md) - if err != nil { - runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) - return - } - - forward_Query_IsRegistrableDomain_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - - }) - return nil } @@ -927,26 +828,6 @@ func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, clie }) - mux.Handle("GET", pattern_Query_IsRegistrableDomain_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { - ctx, cancel := context.WithCancel(req.Context()) - defer cancel() - inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req) - if err != nil { - runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) - return - } - resp, md, err := request_Query_IsRegistrableDomain_0(rctx, inboundMarshaler, client, req, pathParams) - ctx = runtime.NewServerMetadataContext(ctx, md) - if err != nil { - runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) - return - } - - forward_Query_IsRegistrableDomain_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - - }) - return nil } @@ -966,8 +847,6 @@ var ( pattern_Query_DomainOwnershipAll_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"mycel-domain", "mycel", "registry", "domain_ownership"}, "", runtime.AssumeColonVerbOpt(true))) pattern_Query_DomainRegistrationFee_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 1, 0, 4, 1, 5, 5}, []string{"mycel-domain", "mycel", "registry", "domain_registration_fee", "name", "parent"}, "", runtime.AssumeColonVerbOpt(true))) - - pattern_Query_IsRegistrableDomain_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 1, 0, 4, 1, 5, 5}, []string{"mycel-domain", "mycel", "registry", "is_registrable_domain", "name", "parent"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( @@ -986,6 +865,4 @@ var ( forward_Query_DomainOwnershipAll_0 = runtime.ForwardResponseMessage forward_Query_DomainRegistrationFee_0 = runtime.ForwardResponseMessage - - forward_Query_IsRegistrableDomain_0 = runtime.ForwardResponseMessage )