/* DO NOT EDIT: File is auto-generated */
package <%= to_package(repository.gwt_rpc.qualified_keycloak_rpc_request_builder_name) %>;

@javax.annotation.Generated( "Domgen" )
@java.lang.SuppressWarnings( { "UnusedDeclaration", "JavaDoc" } )
public class <%= repository.gwt_rpc.keycloak_rpc_request_builder_name %>
  extends com.google.gwt.user.client.rpc.RpcRequestBuilder
{
  @Override
  protected void doFinish( final com.google.gwt.http.client.RequestBuilder rb )
  {
    super.doFinish( rb );
<% if repository.gwt_rpc.secure_services? -%>
    rb.setHeader( "Authorization", "Bearer " + <%= repository.gwt_rpc.qualified_rpc_services_module_name %>.<% if repository.imit? -%>getSessionContext().<% end -%>getAuthenticationToken() );
<% end -%>
  }
}

/* DO NOT EDIT: File is auto-generated */
package <%= to_package(repository.gwt_rpc.qualified_keycloak_rpc_request_builder_name) %>;

@javax.annotation.Generated( "Domgen" )
@java.lang.SuppressWarnings( { "UnusedDeclaration", "JavaDoc" } )
public class <%= repository.gwt_rpc.keycloak_rpc_request_builder_name %>
  extends com.google.gwt.user.client.rpc.RpcRequestBuilder
{
  @Override
  protected void doFinish( final com.google.gwt.http.client.RequestBuilder rb )
  {
    super.doFinish( rb );
<% if repository.gwt_rpc.secure_services? -%>
    rb.setHeader( "Authorization", "Bearer " + <%= repository.gwt_rpc.qualified_rpc_services_module_name %>.<% if repository.imit? -%>getSessionContext().<% end -%>getAuthenticationToken() );
<% end -%>
    rb.setHeader( MODULE_BASE_HEADER, <%= repository.gwt_rpc.qualified_rpc_services_module_name %>.<% if repository.imit? -%>getSessionContext().<% end -%>getBaseURL() );
  }
}

Make sure module base is configured when using non-imitation secured gwt_rpc
Make sure module base is configured when using non-imitation secured gwt_rpc
