Skip to content

Commit

Permalink
Merge branch 'main' into taefi/add-license-to-signal-package
Browse files Browse the repository at this point in the history
  • Loading branch information
taefi authored Dec 5, 2024
2 parents 53a9c2d + 2f4bf98 commit b11b050
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 11 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2023 Vaadin Ltd.
* Copyright 2000-2024 Vaadin Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
Expand Down Expand Up @@ -76,7 +76,7 @@ AccessAnnotationChecker accessAnnotationChecker() {
* Registers a default {@link EndpointAccessChecker} bean instance.
*
* @param accessAnnotationChecker
* the access controlks checker to use
* the access controls checker to use
* @return the default Vaadin endpoint access checker bean
*/
@Bean
Expand Down Expand Up @@ -112,7 +112,8 @@ CsrfChecker csrfChecker(ServletContext servletContext) {
* qualifier to override the mapper.
*/
@Bean
ObjectMapper endpointObjectMapper(ApplicationContext applicationContext,
ObjectMapper hillaEndpointObjectMapper(
ApplicationContext applicationContext,
@Autowired(required = false) @Qualifier(EndpointController.ENDPOINT_MAPPER_FACTORY_BEAN_QUALIFIER) JacksonObjectMapperFactory endpointMapperFactory) {
if (this.endpointMapper == null) {
this.endpointMapper = endpointMapperFactory != null
Expand All @@ -139,7 +140,7 @@ private static ObjectMapper createDefaultEndpointMapper(
*
* @param applicationContext
* The Spring application context
* @param endpointObjectMapper
* @param hillaEndpointObjectMapper
* ObjectMapper instance that is used for Hilla endpoints'
* serializing and deserializing request and response bodies.
* @param explicitNullableTypeChecker
Expand All @@ -154,11 +155,12 @@ private static ObjectMapper createDefaultEndpointMapper(
*/
@Bean
EndpointInvoker endpointInvoker(ApplicationContext applicationContext,
ObjectMapper endpointObjectMapper,
ObjectMapper hillaEndpointObjectMapper,
ExplicitNullableTypeChecker explicitNullableTypeChecker,
ServletContext servletContext, EndpointRegistry endpointRegistry) {
return new EndpointInvoker(applicationContext, endpointObjectMapper,
explicitNullableTypeChecker, servletContext, endpointRegistry);
return new EndpointInvoker(applicationContext,
hillaEndpointObjectMapper, explicitNullableTypeChecker,
servletContext, endpointRegistry);
}

/**
Expand Down Expand Up @@ -275,9 +277,9 @@ private RequestMappingInfo prependEndpointPrefixUrl(
}

/**
* Can re-generate the TypeScipt code.
* Can re-generate the TypeScript code.
*
* @param context
* @param servletContext
* the servlet context
* @param endpointController
* the endpoint controller
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ public class SignalsConfiguration {
private final EndpointInvoker endpointInvoker;

public SignalsConfiguration(EndpointInvoker endpointInvoker,
ObjectMapper endpointObjectMapper) {
ObjectMapper hillaEndpointObjectMapper) {
this.endpointInvoker = endpointInvoker;
Signal.setMapper(endpointObjectMapper);
Signal.setMapper(hillaEndpointObjectMapper);
}

/**
Expand Down

0 comments on commit b11b050

Please sign in to comment.