title: In a Java Spring Boot based cloud function how does one access the HttpServletRequest or HttpServletResponse
body: <p>The examples for Spring Boot cloud functions for GCP are very simplistic at this point. Looking at the function-sample-gcp-http the main class looks like the following.</p>
  <pre class="lang-java prettyprint-override"><code>@SpringBootApplication
  public class CloudFunctionMain {
  
      public static void main(String[] args) {
          SpringApplication.run(CloudFunctionMain.class, args);
      }
  
      @Bean
      public Function&lt;String, String&gt; function() {
          return value -&gt; value.toUpperCase();
      }
  }
  </code></pre>
  <p>Let's assume we are going to be writing something more complex than this as a cloud function and request method and headers are needed and maybe other things from the request or response. How would one, in the above 'function' access the HttpServletRequest or HttpServletResponse? Is there any way to do so?</p>