Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Merge enums#495

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
XVincentX wants to merge6 commits intovNext
base:vNext
Choose a base branch
Loading
frommerge-enum
Open

Merge enums#495

XVincentX wants to merge6 commits intovNextfrommerge-enum

Conversation

@XVincentX
Copy link
Member

Closes#494

@XVincentXXVincentX marked this pull request as ready for reviewAugust 28, 2023 19:36
@OlgaPodoOlgaPodo added Graph GuidelinesThis should be reviewed by Microsoft Grap team. Microsoft GraphThis should be reviewed by Microsoft Grap team. labelsAug 30, 2023

##Problem

The API Design requires that a specific property of a data structure has a finite and limited set of values, and such limitation needs to be clearly communicated to the user and give the developer the same structure
Copy link
Collaborator

Choose a reason for hiding this comment

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

##Solution

In OData, Enums represent a subset of the nominal type they rely on, and are especially useful in cases where certain properties have predefined, limited options.

Copy link
Collaborator

@OlgaPodoOlgaPodoSep 11, 2023
edited
Loading

Choose a reason for hiding this comment

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

Enum solution must be based on the evolvable enum. Not evolvable enums are exceptions. Could you please merge all template sections together? it doesn't make sense to have the same section in one document twice.

####Cons
###Cons

- Adding a new value requires to go through a (generally fast) API Review
Copy link
Collaborator

Choose a reason for hiding this comment

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

Our internal process shouldn't impact API design considerations especially as they published for external users.

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

Well, it is a clear side effect which is annoying for a lot of workload owners. I can remove it if you want, but we're missing a particular part that affect us. Your call

Copy link
Collaborator

Choose a reason for hiding this comment

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

Please remove this. We might offer some process guidance in the future, but I don't think it's our area of expertise now or something we are working on.


###Pros

- Our SDK generators will translate the enum to the best representation of the target programming language, resulting in a better developer experience and free client side validation
Copy link
Collaborator

Choose a reason for hiding this comment

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

One of the pros for Enums is that clients can write a processing logic based on the enum values.

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

Isn't that true for any property? Clients write processing logic based on values - not too sure what is different here

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@OlgaPodoOlgaPodoOlgaPodo left review comments

@dkershaw10dkershaw10Awaiting requested review from dkershaw10

@corranrogue9corranrogue9Awaiting requested review from corranrogue9

Assignees

No one assigned

Labels

Graph GuidelinesThis should be reviewed by Microsoft Grap team.Microsoft GraphThis should be reviewed by Microsoft Grap team.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Fix content table in the main Graph guidelines. merger enum and evolvable enum patterns

3 participants

@XVincentX@OlgaPodo

[8]ページ先頭

©2009-2025 Movatter.jp