title: SAPUI5 > 1.30, how to set custom model headers before initial request
body: <p>Before the use of a manifest file I used to add custom headers to the config of my oData model. Now starting from SAPUI5 1.30 the Component.js is using a manifest file and as soon as the runtime enters the Component.js init() function the model is already loaded and a first request is already made to my service.
  I need a way to set my custom headers at runtime and before the first request to my service is made.</p>
  <p>Before:</p>
  <pre><code>    // The service URL for the oData model
      var oServiceConfig = this.getMetadata().getConfig().serviceConfig;
      var sServiceUrl = oServiceConfig.serviceUrl;
  
      // the metadata is read to get the location of the i18n language files later
      var mConfig = this.getMetadata().getConfig();
      this._routeMatchedHandler = new sap.m.routing.RouteMatchedHandler(this.getRouter(), this._bRouterCloseDialogs);
  
      // create oData model
      this._initODataModel(sServiceUrl);
  
  // _initODataModel function
  
      headers = {custom: 'hello world'};
      var oConfig = {
          metadataUrlParams: {},
          json: true,
          // loadMetadataAsync : true,
          defaultBindingMode: &quot;OneWay&quot;,
          defaultCountMode: &quot;Inline&quot;,
          useBatch: true,
          headers: headers
      };
  
      var oModel = new sap.ui.model.odata.ODataModel(sServiceUrl, oConfig);       
      this.setModel(oModel);
  </code></pre>