title: stub.GetCallerCertificate(), stub.GetCallerMetadata(), stub.GetPayload() is returning blank
body: <pre><code>package main
  
  import (
      "fmt"
      "github.com/hyperledger/fabric/core/chaincode/shim"
      pb "github.com/hyperledger/fabric/protos/peer"
  )
  
  var matchLogger = shim.NewLogger("Helper")
  
  type PlaceHolder struct {
      ValA  string `json:"ValA"`
      ValB  string `json:"ValB"`
      Match bool   `json:"Match"`
  }
  
  type Agreement struct {
      TradeNumber         PlaceHolder `json:"TradeNumber"`
      BuyerName           PlaceHolder `json:"BuyerName"`
      SellerName          PlaceHolder `json:"SellerName"`
      BuyerID             PlaceHolder `json:"BuyerID"`
      SellerID            PlaceHolder `json:"SellerID"`
  }
  
  type ContractContaineer struct {
      FirmID       string   `json:"FirmID"`
      ContractList []string `json:"contractList"`
  }
  
  
  func (t *Agreement) Init(stub shim.ChaincodeStubInterface) pb.Response {
  
      xx, err1 := stub.GetCallerCertificate()
      if err1 != nil {
          matchLogger.Info(err1)  
      }
      matchLogger.Info("Cert ----")
      matchLogger.Info(string(xx))
      matchLogger.Info("----")
  
      xy, err3 := stub.GetCallerMetadata()
      if err3 != nil {
          matchLogger.Info(err3)  
      }
      matchLogger.Info("Meta ----")
      matchLogger.Info(string(xy))
      matchLogger.Info("----")
  
      yy, err4 := stub.GetPayload()
      if err4 != nil {
          matchLogger.Info(err4)  
      }
      matchLogger.Info("PLD ----")
      matchLogger.Info(string(yy))
      matchLogger.Info("----")
  
  
      return shim.Success(nil)
  }
  
  
  func (t *Agreement) Query(stub shim.ChaincodeStubInterface) pb.Response {
          return shim.Success(nil)
  }
  
  
  // Transaction makes payment of X units from A to B
  func (t *Agreement) Invoke(stub shim.ChaincodeStubInterface) pb.Response {
  
      xx, err1 := stub.GetCallerCertificate()
      if err1 != nil {
          matchLogger.Info(err1)  
      }
      matchLogger.Info("Cert ----")
      matchLogger.Info(string(xx))
      matchLogger.Info("----")
  
      xy, err3 := stub.GetCallerMetadata()
      if err3 != nil {
          matchLogger.Info(err3)  
      }
      matchLogger.Info("Meta ----")
      matchLogger.Info(string(xy))
      matchLogger.Info("----")
  
      yy, err4 := stub.GetPayload()
      if err4 != nil {
          matchLogger.Info(err4)  
      }
      matchLogger.Info("PLD ----")
      matchLogger.Info(string(yy))
      matchLogger.Info("----")
  
      return shim.Success(nil)
  }
  
  
  func main() {
  
      lld, _ := shim.LogLevel("INFO")
      matchLogger.Info(lld)
      matchLogger.SetLevel(lld)
      matchLogger.Info(matchLogger.IsEnabledFor(lld))
      err := shim.Start(new(Agreement))
      if err != nil {
          fmt.Printf("Error starting Simple chaincode: %s", err)
      }
  }
  </code></pre>
  
  <p>This is my complete GO file. Kindly suggest what i did wrong. The logger output is coming as blank for xx, xy, yy. errors are nil too. I have implemented all 3 methods i.e. init, invoke and query. Code is getting compiled just fine</p>