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

[WEJBHTTP-142] First round of refactorings in EJB part - focus on client side of the protocol #219

Merged
merged 49 commits into from
Sep 25, 2024

Conversation

ropalka
Copy link
Collaborator

@ropalka ropalka commented May 28, 2024

@ropalka ropalka requested a review from fl4via as a code owner May 28, 2024 12:15
@ropalka ropalka removed the request for review from fl4via May 28, 2024 12:15
@ropalka ropalka requested a review from fl4via June 12, 2024 13:59
Copy link
Collaborator

@rachmatowicz rachmatowicz left a comment

Choose a reason for hiding this comment

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

Some feedback

import org.wildfly.httpclient.common.Protocol;

import java.lang.reflect.Method;

Copy link
Collaborator

Choose a reason for hiding this comment

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

Description of class and its purpose? Sample usage example would be nice as well, as certain methods need to be invoked before others (e.g. setting the request type).

Copy link
Collaborator

@fl4via fl4via left a comment

Choose a reason for hiding this comment

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

There is a typo in the header of a commit, usealess

ropalka added 25 commits August 13, 2024 17:07
… distinctName & beanName method parameters. These values are available as instance fields.
…request method, second set HTTP request path and finally set HTTP request headers.
…ry to call UTF-8.name() method which may throw UnsupportedEncodingException.
…ring() conversion method. StringBuilder supports appending of booleans directly.
…ds parameter. We can distinguish proper HTTP request prefix path via HttpEJBInvocationBuilder method signatures.
…troducing appendPath(StringBuilder,String) utility method.
… getters. Making all its method arguments final.
…dPath() into appendPath() & appendEncodedPath() methods. Adjusting code accordingly.
…anPath() & buildModulePath() into buildBeanPath() method.
…, distinctName & beanName method parameters. These are available as instance fields.
…ath() and appendEncoedPath() utility methods.
…d, invocationId & cancelIfRunning method parameters. These are available as instance fields.
…eanPath() method to appendBeanPath() and changing its parameters order.
ropalka added 19 commits August 13, 2024 17:19
…eName, distinctName & beanName strings in HttpEJBInvocationBuilder.
…uilder's appendOperationPath() method call one method up in the caller's stack.
…JBInvocationBuilder class for configuring client requests.
@ropalka ropalka force-pushed the WEJBHTTP-142_round1 branch from 8ef967e to b70a8f8 Compare August 13, 2024 15:55
@ropalka
Copy link
Collaborator Author

ropalka commented Aug 13, 2024

Typo 'usealess' was fixed in PR refresh Flavia.

@ropalka
Copy link
Collaborator Author

ropalka commented Aug 13, 2024

@fl4via @rachmatowicz please review again.

@ropalka ropalka force-pushed the WEJBHTTP-142_round1 branch from b70a8f8 to c522932 Compare August 15, 2024 21:22
Copy link
Collaborator

@fl4via fl4via left a comment

Choose a reason for hiding this comment

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

I am approving the PR and merging it with one thing to consider as future improvement: the naming of OPEN request does not sound correct to me and it should be renamed.

@@ -283,7 +283,7 @@ protected SessionID createSession(final EJBReceiverSessionCreationContext receiv
CompletableFuture<SessionID> result = new CompletableFuture<>();

RequestBuilder builder = new RequestBuilder()
.setRequestType(RequestType.CREATE_SESSION)
.setRequestType(RequestType.OPEN)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Because there is no open operation in the EJB spec, I am not very fond of this renaming. CREATE_SESSION implies that we are creating the session, which is what we actually are doing here. OPEN is confusing. We use open to refer to transactions, resources, connections, but to me it does not relate to the create session operation.

@fl4via fl4via merged commit 438c324 into wildfly:main Sep 25, 2024
12 checks passed
@ropalka ropalka deleted the WEJBHTTP-142_round1 branch September 25, 2024 11:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants