Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix gRPC error handling for mirror-gateway handler #2665

Merged
merged 15 commits into from
Oct 8, 2024

Conversation

hlts2
Copy link
Collaborator

@hlts2 hlts2 commented Oct 1, 2024

Description

Related Issue

Versions

  • Vald Version: v1.7.13
  • Go Version: v1.23.1
  • Rust Version: v1.81.0
  • Docker Version: v27.3.1
  • Kubernetes Version: v1.31.1
  • Helm Version: v3.16.1
  • NGT Version: v2.2.4
  • Faiss Version: v1.8.0

Checklist

Special notes for your reviewer

Summary by CodeRabbit

  • New Features

    • Enhanced error handling across multiple gRPC methods for clearer and more consistent error reporting.
    • Streamlined error parsing to simplify error handling processes.
  • Bug Fixes

    • Improved logging for better context and clarity in error messages.
    • Adjusted handling of unimplemented errors to ensure proper disconnection.
  • Refactor

    • Adjusted method logic for handling proxied requests to maintain consistency with new error handling patterns.
    • Updated error handling within the registers, Connect, and Disconnect methods for improved robustness.

Copy link
Contributor

coderabbitai bot commented Oct 1, 2024

📝 Walkthrough
📝 Walkthrough
📝 Walkthrough
📝 Walkthrough

Walkthrough

The changes enhance error handling and standardize the structure of gRPC method implementations in the pkg/gateway/mirror/handler/grpc/handler.go file, along with refining error handling within the mirror.go file. Key updates include refined error handling logic, streamlined error parsing, clarified method logic for proxied requests, consistent logging practices, and minor adjustments to method signatures.

Changes

Files Change Summary
pkg/gateway/mirror/handler/grpc/handler.go, pkg/gateway/mirror/service/mirror.go - Enhanced error handling across multiple methods using standardized error wrappers.
- Updated error parsing logic to simplify error handling.
- Clarified logic for handling proxied requests.
- Adjusted logging for consistency.
- Minor adjustments to method signatures.

Sequence Diagram(s)

Possibly related PRs

Suggested labels

type/bug, priority/medium


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@vdaas-ci
Copy link
Collaborator

vdaas-ci commented Oct 1, 2024

[CHATOPS:HELP] ChatOps commands.

  • 🙆‍♀️ /approve - approve
  • 🍱 /format - format codes and add licenses
  • /gen-test - generate test codes
  • 🏷️ /label - add labels
  • 🔚 2️⃣ 🔚 /label actions/e2e-deploy - run E2E deploy & integration test

Copy link

codecov bot commented Oct 1, 2024

Codecov Report

Attention: Patch coverage is 3.43137% with 197 lines in your changes missing coverage. Please review.

Project coverage is 23.85%. Comparing base (4129b0a) to head (794d70c).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
pkg/gateway/mirror/handler/grpc/handler.go 3.68% 176 Missing and 7 partials ⚠️
pkg/gateway/mirror/service/mirror.go 0.00% 14 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2665      +/-   ##
==========================================
- Coverage   24.02%   23.85%   -0.17%     
==========================================
  Files         539      539              
  Lines       47117    47071      -46     
==========================================
- Hits        11320    11231      -89     
- Misses      35027    35064      +37     
- Partials      770      776       +6     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

🧹 Outside diff range and nitpick comments (2)
pkg/gateway/mirror/handler/grpc/handler.go (2)

393-398: Typographical Error in Log Message

There's a minor typo in the log message at line 396:

log.Errorf("gRPC call returned not a gRPC status error: %v", err)

Consider rephrasing for clarity.

Update the log message:

-log.Errorf("gRPC call returned not a gRPC status error: %v", err)
+log.Errorf("gRPC call did not return a gRPC status error: %v", err)

2730-2738: Typo in Error Message: "canceld"

At line 2733, there's a typo in the error message:

err = status.WrapWithCanceled(vald.RemoveRPCName+" API canceld", err, reqInfo, resInfo)

Correct the spelling of "canceled".

-err = status.WrapWithCanceled(vald.RemoveRPCName+" API canceld", err, reqInfo, resInfo)
+err = status.WrapWithCanceled(vald.RemoveRPCName+" API canceled", err, reqInfo, resInfo)
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Files that changed from the base of the PR and between d6b6c8c and 51f4a0e.

📒 Files selected for processing (1)
  • pkg/gateway/mirror/handler/grpc/handler.go (27 hunks)
🔇 Additional comments (6)
pkg/gateway/mirror/handler/grpc/handler.go (6)

120-131: Correct Error Wrapping with status.WrapWithInternal

The error wrapping at lines 120-131 correctly standardizes the use of status.WrapWithInternal, enhancing consistency in error reporting. This aligns with the PR objective to improve error handling in gRPC implementations.


1997-1997: Consistent Use of Error Codes

At line 1997, ensure that the correct gRPC status codes are used in sspan.SetAttributes(trace.FromGRPCStatus(st.Code(), st.Message())...). Consistency in status codes helps with accurate error tracking.

Ensure that st.Code() returns the appropriate status code for the error.


2801-2804: Ensure WaitGroup Synchronization

At lines 2801-2804, confirm that the WaitGroup is correctly synchronized to prevent panics due to concurrent access.

Review the usage of wg.Add(1) and wg.Done() to ensure they are correctly balanced.


2166-2175: ⚠️ Potential issue

Potential Race Condition in Concurrent Map Access

At lines 2166-2175, there is concurrent access to the result map without synchronization, which could lead to race conditions.

Protect access to result with a mutex or use a concurrent map.

+var resultMu sync.Mutex

...

resultMu.Lock()
result.Store(target, &errorState{err, code})
resultMu.Unlock()

Likely invalid or redundant comment.


393-398: ⚠️ Potential issue

Check for Possible Nil Pointer Dereference

At lines 393-398, there's a check for st, ok := status.FromError(err). While the comment mentions it's unlikely, ensure that st.Proto() won't cause a nil pointer dereference even in edge cases.

Consider adding an explicit nil check before calling st.Proto():

if !ok || st == nil || st.Message() == "" {

Likely invalid or redundant comment.


1560-1566: ⚠️ Potential issue

Missing Error Handling for s.gateway.Do

At lines 1560-1566, after calling s.gateway.Do, consider handling any potential errors returned by this function to prevent unexpected issues.

Add error handling for s.gateway.Do to capture and log any errors.

_, errGateway := s.gateway.Do(ctx, s.vAddr, func(ctx context.Context, _ string, vc service.MirrorClient, copts ...grpc.CallOption) (any, error) {
	loc, err = vc.Update(ctx, req, copts...)
	return loc, err
})
+if errGateway != nil {
+	log.Warnf("Error from s.gateway.Do: %v", errGateway)
+	// Handle error as appropriate
+}

Likely invalid or redundant comment.

pkg/gateway/mirror/handler/grpc/handler.go Outdated Show resolved Hide resolved
pkg/gateway/mirror/handler/grpc/handler.go Outdated Show resolved Hide resolved
pkg/gateway/mirror/handler/grpc/handler.go Outdated Show resolved Hide resolved
pkg/gateway/mirror/handler/grpc/handler.go Outdated Show resolved Hide resolved
Copy link

cloudflare-workers-and-pages bot commented Oct 1, 2024

Deploying vald with  Cloudflare Pages  Cloudflare Pages

Latest commit: 794d70c
Status: ✅  Deploy successful!
Preview URL: https://f191dd58.vald.pages.dev
Branch Preview URL: https://fix-mirror-error-handling.vald.pages.dev

View logs

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🧹 Outside diff range and nitpick comments (3)
pkg/gateway/mirror/service/mirror.go (3)

218-223: Ensure Proper Handling of gRPC Status Errors

In the condition checking !ok || st == nil || st.Message() == "", there's concern about potential nil pointer dereferences. The comment mentions the unlikelihood of this condition. Considering this, ensure that the error handling is robust and logs meaningful messages.

Optionally, you could add more context to the log message for clarity:

 log.Errorf("gRPC call returned not a gRPC status error: %v", err)
+log.Debugf("Original error: %v", err)

Line range hint 228-240: Handle Errors Returned by Disconnect Method

When disconnecting due to an unimplemented error, the error returned by m.Disconnect is logged but not handled. Consider handling this error to ensure that the disconnection process is reliable.

Modify the code to handle the error:

 if st.Code() == codes.Unimplemented {
     host, port, err := net.SplitHostPort(target)
     if err != nil {
         log.Warn(err)
     } else {
         if err := m.Disconnect(ctx, &payload.Mirror_Target{
             Host: host,
             Port: uint32(port),
         }); err != nil {
             log.Errorf("failed to disconnect %s, err: %v", target, err)
+            return err
         }
     }
 }

Line range hint 273-282: Mismatch Between Error Handling and Logging Severity

An internal error is wrapped and then logged with log.Warn(err). It may be more appropriate to use log.Error(err) to reflect the severity of the issue.

Apply this diff to adjust the logging level:

 err = status.WrapWithInternal(
     mirror.RegisterRPCName+" API connection not found", err,
 )
-log.Warn(err)
+log.Error(err)
 if span != nil {
     span.RecordError(err)
     span.SetAttributes(trace.StatusCodeInternal(err.Error())...)
     span.SetStatus(trace.StatusError, err.Error())
 }
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Files that changed from the base of the PR and between 51f4a0e and a41cfac.

📒 Files selected for processing (1)
  • pkg/gateway/mirror/service/mirror.go (4 hunks)
🔇 Additional comments (3)
pkg/gateway/mirror/service/mirror.go (3)

Line range hint 242-249: Use Appropriate Logging Level for Errors

The error is being logged with log.Errorf, which is suitable. Ensure that all errors of similar severity use consistent logging levels.


204-206: ⚠️ Potential issue

Incorrect Error Wrapping: Use WrapWithDeadlineExceeded

The context.DeadlineExceeded error should be wrapped with status.WrapWithDeadlineExceeded instead of status.WrapWithCanceled to accurately represent the error type.

Apply this diff to correct the error wrapping:

-err = status.WrapWithCanceled(
+err = status.WrapWithDeadlineExceeded(
     mirror.RegisterRPCName+" API deadline exceeded", err,
 )

Likely invalid or redundant comment.


209-211: Consistent Error Wrapping: Verify the Use of WrapWithInternal

The error is being wrapped with status.WrapWithInternal, which is appropriate for internal errors. Ensure that this aligns with the intended error classification for a "connection not found" scenario.

Run the following script to confirm consistent usage of error wrapping:

✅ Verification successful

Consistent Use of WrapWithInternal Confirmed

The usage of status.WrapWithInternal for "API connection not found" errors is consistent across the codebase.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Search for usages of WrapWithInternal in similar contexts.

rg --type go -A 2 $'status.WrapWithInternal(' | rg 'connection not found'

Length of output: 173


Script:

#!/bin/bash
# Description: Search for usages of WrapWithInternal in similar contexts with corrected regex.

rg --type go 'status\.WrapWithInternal\(' -A 2 | rg 'connection not found'

Length of output: 6291

pkg/gateway/mirror/service/mirror.go Outdated Show resolved Hide resolved
pkg/gateway/mirror/service/mirror.go Show resolved Hide resolved
pkg/gateway/mirror/service/mirror.go Show resolved Hide resolved
coderabbitai[bot]
coderabbitai bot previously approved these changes Oct 1, 2024
Signed-off-by: hlts2 <[email protected]>
@hlts2
Copy link
Collaborator Author

hlts2 commented Oct 2, 2024

@coderabbitai review

Copy link
Contributor

coderabbitai bot commented Oct 2, 2024

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Copy link
Contributor

github-actions bot commented Oct 2, 2024

@vdaas-ci
Copy link
Collaborator

vdaas-ci commented Oct 2, 2024

Profile Report

typevald-agent-ngtvald-lb-gatewayvald-discoverervald-manager-index
cpu
heap
other images

coderabbitai[bot]
coderabbitai bot previously approved these changes Oct 2, 2024
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Outside diff range and nitpick comments (2)
pkg/gateway/mirror/handler/grpc/handler.go (2)

Line range hint 145-153: Ensure Consistent Use of Error Codes and Details

At lines 145-153, when handling errors from s.mirror.MirrorTargets(ctx), the error is wrapped with status.WrapWithInternal and includes an errdetails.BadRequest. Similar to the previous comment, BadRequest details are usually paired with InvalidArgument status codes.

To maintain consistency and proper error handling, consider using status.WrapWithInvalidArgument or adjusting the error details.

Apply this diff to correct the error code:

- err = status.WrapWithInternal(mirror.RegisterRPCName+" API failed to get connected mirror gateway targets", err,
+ err = status.WrapWithInvalidArgument(mirror.RegisterRPCName+" API failed to get connected mirror gateway targets", err,
    &errdetails.BadRequest{
        FieldViolations: []*errdetails.BadRequestFieldViolation{
            {
                Field:       "mirror gateway targets",
                Description: err.Error(),
            },
        },
    },
    &errdetails.ResourceInfo{
        ResourceType: errdetails.ValdGRPCResourceTypePrefix + "/vald.v1." + mirror.RegisterRPCName,
        ResourceName: fmt.Sprintf("%s: %s(%s)", apiName, s.name, s.ip),
    },
)

1430-1438: Correct Spelling in Error Message

At line 1434, the error message should use the status code codes.Internal instead of codes.Unknown for internal errors:

st = status.New(codes.Unknown, "failed to parse "+vald.InsertRPCName+" gRPC error response")

Update the status code to accurately reflect the nature of the error.

Apply this diff to fix the status code:

- st = status.New(codes.Unknown, "failed to parse "+vald.InsertRPCName+" gRPC error response")
+ st = status.New(codes.Internal, "failed to parse "+vald.InsertRPCName+" gRPC error response")
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Files that changed from the base of the PR and between 31552df and 6617946.

📒 Files selected for processing (1)
  • pkg/gateway/mirror/handler/grpc/handler.go (27 hunks)

pkg/gateway/mirror/handler/grpc/handler.go Show resolved Hide resolved
coderabbitai[bot]
coderabbitai bot previously approved these changes Oct 8, 2024
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Outside diff range and nitpick comments (2)
pkg/gateway/mirror/handler/grpc/handler.go (2)

Line range hint 145-153: Use Appropriate Error Code with BadRequest Details

At lines 145-153, the error is wrapped with status.WrapWithInternal while including an errdetails.BadRequest. The BadRequest error detail is typically associated with InvalidArgument errors, not Internal errors. This mismatch can lead to confusion in error handling and inconsistency in error reporting.

Apply this diff to align the status code with the error details:

-    		err = status.WrapWithInternal(
+    		err = status.WrapWithInvalidArgument(
    			mirror.RegisterRPCName+" API failed to get connected mirror gateway targets", err,
    			&errdetails.BadRequest{
    				FieldViolations: []*errdetails.BadRequestFieldViolation{
    					{
    						Field:       "mirror gateway targets",
    						Description: err.Error(),
    					},
    				},
    			},
    			&errdetails.ResourceInfo{
    				ResourceType: errdetails.ValdGRPCResourceTypePrefix + "/vald.v1." + mirror.RegisterRPCName,
    				ResourceName: fmt.Sprintf("%s: %s(%s)", apiName, s.name, s.ip),
    			},
    		)

120-121: Fix Spelling Mistake in Error Messages

The error message contains a typo: "canceld" should be "canceled". This typo appears in multiple error messages throughout the code at lines 120-121, 1427-1430, 1557-1560, 1986-1989, 2358-2361, and 2857-2860.

Apply the following diff to correct the typo:

-	err = status.WrapWithCanceled(
-		<APIName>+" API canceld", err, reqInfo, resInfo,
+	err = status.WrapWithCanceled(
+		<APIName>+" API canceled", err, reqInfo, resInfo,

Please correct this typo in all occurrences within the codebase.

Also applies to: 1427-1430, 1557-1560, 1986-1989, 2358-2361, 2857-2860

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Files that changed from the base of the PR and between 6617946 and f2e676c.

📒 Files selected for processing (1)
  • pkg/gateway/mirror/handler/grpc/handler.go (37 hunks)
🧰 Additional context used

pkg/gateway/mirror/handler/grpc/handler.go Outdated Show resolved Hide resolved
hlts2 added 2 commits October 8, 2024 14:15
Signed-off-by: hlts2 <[email protected]>
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Outside diff range and nitpick comments (2)
pkg/gateway/mirror/handler/grpc/handler.go (2)

Line range hint 145-154: Use Appropriate Error Code with BadRequest Details

You're wrapping the error with status.WrapWithInternal while attaching an errdetails.BadRequest. The BadRequest error detail is typically associated with InvalidArgument errors, not Internal errors. This could lead to confusion in error handling and inconsistency in error reporting.

Consider changing the status code to InvalidArgument to align with the BadRequest error detail, or adjust the error details to match the Internal status code.

Apply this diff to align the status code with the error details:

- err = status.WrapWithInternal(
+ err = status.WrapWithInvalidArgument(
    mirror.RegisterRPCName+" API failed to get connected mirror gateway targets", err,
    &errdetails.BadRequest{
        FieldViolations: []*errdetails.BadRequestFieldViolation{
            {
                Field:       "mirror gateway targets",
                Description: err.Error(),
            },
        },
    },
    &errdetails.ResourceInfo{
        ResourceType: errdetails.ValdGRPCResourceTypePrefix + "/vald.v1." + mirror.RegisterRPCName,
        ResourceName: fmt.Sprintf("%s: %s(%s)", apiName, s.name, s.ip),
    },
)

3247-3247: Ensure Consistency in Error Codes

In this error handling block, you're using codes.Internal when creating a new status, whereas similar blocks use codes.Unknown. For consistency and clarity, consider using the same error code across similar error handling sections.

Apply this diff to standardize the error code:

- st = status.New(codes.Internal, "failed to parse "+vald.GetObjectRPCName+" gRPC error response")
+ st = status.New(codes.Unknown, "failed to parse "+vald.GetObjectRPCName+" gRPC error response")
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Files that changed from the base of the PR and between f2e676c and 6c1084d.

📒 Files selected for processing (1)
  • pkg/gateway/mirror/handler/grpc/handler.go (37 hunks)
🧰 Additional context used
🔇 Additional comments (1)
pkg/gateway/mirror/handler/grpc/handler.go (1)

120-121: ⚠️ Potential issue

Fix typo in error message: "canceld" should be "canceled"

The error message misspells "canceled" as "canceld". Please correct the spelling to improve clarity and professionalism. This typo occurs in multiple places throughout the code.

Apply this diff to correct the typo:

- err = status.WrapWithCanceled(
-     mirror.RegisterRPCName+" API canceld", err, reqInfo, resInfo,
+ err = status.WrapWithCanceled(
+     mirror.RegisterRPCName+" API canceled", err, reqInfo, resInfo,

Likely invalid or redundant comment.

@github-actions github-actions bot added size/XL and removed size/L labels Oct 8, 2024
@kpango kpango merged commit a62f834 into main Oct 8, 2024
43 of 44 checks passed
@kpango kpango deleted the fix/mirror/error-handling branch October 8, 2024 06:11
hlts2 added a commit that referenced this pull request Oct 8, 2024
* fix: use FromError function when stream rpc error occurs

Signed-off-by: hlts2 <[email protected]>

* fix: delete ParseError of Register RPC error handling

Signed-off-by: hlts2 <[email protected]>

* fix: crud rpc error handling

Signed-off-by: hlts2 <[email protected]>

* fix: add code comment and refactor multi crud error handling

Signed-off-by: hlts2 <[email protected]>

* fix: deleted unnecessary error resource info

Signed-off-by: hlts2 <[email protected]>

* fix: typo

Signed-off-by: hlts2 <[email protected]>

* fix: status code when the parse is failed

Signed-off-by: hlts2 <[email protected]>

* fix: ignore parse success variable

Signed-off-by: hlts2 <[email protected]>

* fix: use FromError function for stream error

Signed-off-by: hlts2 <[email protected]>

* fix: error status handling

Signed-off-by: hlts2 <[email protected]>

* fix: typo

Signed-off-by: hlts2 <[email protected]>

---------

Signed-off-by: hlts2 <[email protected]>
Co-authored-by: Kosuke Morimoto <[email protected]>
kpango added a commit that referenced this pull request Oct 8, 2024
* fix: use FromError function when stream rpc error occurs



* fix: delete ParseError of Register RPC error handling



* fix: crud rpc error handling



* fix: add code comment and refactor multi crud error handling



* fix: deleted unnecessary error resource info



* fix: typo



* fix: status code when the parse is failed



* fix: ignore parse success variable



* fix: use FromError function for stream error



* fix: error status handling



* fix: typo



---------

Signed-off-by: hlts2 <[email protected]>
Co-authored-by: Kosuke Morimoto <[email protected]>
Co-authored-by: Yusuke Kato <[email protected]>
@kpango kpango mentioned this pull request Oct 11, 2024
takuyaymd pushed a commit to takuyaymd/vald that referenced this pull request Dec 2, 2024
* fix: use FromError function when stream rpc error occurs

Signed-off-by: hlts2 <[email protected]>

* fix: delete ParseError of Register RPC error handling

Signed-off-by: hlts2 <[email protected]>

* fix: crud rpc error handling

Signed-off-by: hlts2 <[email protected]>

* fix: add code comment and refactor multi crud error handling

Signed-off-by: hlts2 <[email protected]>

* fix: deleted unnecessary error resource info

Signed-off-by: hlts2 <[email protected]>

* fix: typo

Signed-off-by: hlts2 <[email protected]>

* fix: status code when the parse is failed

Signed-off-by: hlts2 <[email protected]>

* fix: ignore parse success variable

Signed-off-by: hlts2 <[email protected]>

* fix: use FromError function for stream error

Signed-off-by: hlts2 <[email protected]>

* fix: error status handling

Signed-off-by: hlts2 <[email protected]>

* fix: typo

Signed-off-by: hlts2 <[email protected]>

---------

Signed-off-by: hlts2 <[email protected]>
Co-authored-by: Kosuke Morimoto <[email protected]>
takuyaymd pushed a commit to takuyaymd/vald that referenced this pull request Dec 2, 2024
* fix: use FromError function when stream rpc error occurs

Signed-off-by: hlts2 <[email protected]>

* fix: delete ParseError of Register RPC error handling

Signed-off-by: hlts2 <[email protected]>

* fix: crud rpc error handling

Signed-off-by: hlts2 <[email protected]>

* fix: add code comment and refactor multi crud error handling

Signed-off-by: hlts2 <[email protected]>

* fix: deleted unnecessary error resource info

Signed-off-by: hlts2 <[email protected]>

* fix: typo

Signed-off-by: hlts2 <[email protected]>

* fix: status code when the parse is failed

Signed-off-by: hlts2 <[email protected]>

* fix: ignore parse success variable

Signed-off-by: hlts2 <[email protected]>

* fix: use FromError function for stream error

Signed-off-by: hlts2 <[email protected]>

* fix: error status handling

Signed-off-by: hlts2 <[email protected]>

* fix: typo

Signed-off-by: hlts2 <[email protected]>

---------

Signed-off-by: hlts2 <[email protected]>
Co-authored-by: Kosuke Morimoto <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants