1. 16 Jul, 2018 1 commit
    • Jason Yellick's avatar
      FAB-10292 Update protobuf to v1.1.0 · 03104e71
      Jason Yellick authored
      Protobuf was slated to be updated already, but there is a long list of
      incompatibilities with the current source tree.
      Thi CR updates protobuf to v1.1.0, and addresses those
      incompatibilities.  Most of the changes are quite rote and fall into one
      of three buckets.
      1. Code which uses non-keyed field initialization.  (ie, initializing a
      struct like MyStruct{value1, value2, value3}).  The newer generated
      protos produces structs which have additional non-field members.
      Structs should always be initialized with named fields, regardless of
      whether they are protos or not.
      2. Code which assumes that reflect.DeepEqual between two protos with the
      same fields will return true.  This has never been the case, especially
      when considering protos with slice or map fields, but with proto v1.1.0
      with the addition of caching and other members to the proto structs, it
      is even less true.  The correct call is proto.Equal.
      3. Code which assumes that proto fails on bad inputs -- the proto spec
      has always stated that failure _may_ occur, not that it must.  Certain
      code would attempt to determine proto message type based on failure to
      unmarshal, which was unsafe in v1.0.0, but is even more likely to cause
      problems in v1.1.0.
      4. On average, half of gossip identity digests aren't valid UTF8 strings,
         and proto v1.1.0 now enforces UTF8 validity checks for string fields.
         Therefore, the field was converted to bytes.
      Change-Id: I74cc037903137705dbe3f4e27e34d1307596db3b
      Signed-off-by: default avatarJason Yellick <jyellick@us.ibm.com>
      Signed-off-by: default avataryacovm <yacovm@il.ibm.com>
  2. 22 May, 2018 1 commit
  3. 01 May, 2018 1 commit
  4. 16 Apr, 2018 1 commit
    • Matthew Sykes's avatar
      [FAB-9494] test package functions to load config · 1d8344d7
      Matthew Sykes authored
      - Add variadic argument for extra search paths to configtxgen/localconfig
        Load and LoadTopLevel functions. This is primarily intended to be used
        in tests.
      - Create configtxgentest package that loads configurations and profiles
        from the development sampleconfig directory.
      - Add method to configtest to setup and reset FABRIC_CFG_PATH.
      - Update tests to use configtxgentest and/or configtest as appropriate.
      Change-Id: I6a66491bfbc0048f5b38babf6a55fb918a439fe6
      Signed-off-by: default avatarMatthew Sykes <sykesmat@us.ibm.com>
  5. 18 Jan, 2018 1 commit
    • Robert Zaremba's avatar
      [FAB-7802] Automatic format fix using gofmt · e14f2080
      Robert Zaremba authored
      gofmt -w -s
      Many developers have integrated `gofmt`  auto-formatting. S
      Some code changes can automatically cause other changes caused through
      `gofmt` integration, not related to the intent of the task.
      For clarity in future pull-requests, the gofmt issues should be solved
      once and for all.
      This change doesn't break the code, because it uses official `gofmt` to do
      the auto code formatting.
      Change-Id: Ife1c2e112dc4f188fb6a90916587af453a133099
      Signed-off-by: default avatarRobert Zaremba <robert.zaremba@scale-it.pl>
  6. 02 Nov, 2017 1 commit
    • Jason Yellick's avatar
      [FAB-6223] Define resource tree config protos · c3bfd6dd
      Jason Yellick authored
      The resource tree needs to represent both API ACLs as well as
      This CR renames the Resource message to APIResource and adds a
      collection of Chaincode messages for defining the chaincode group.
      For the new Chaincode group, there is now a structure of:
      [Group] Resources
          [Group] Chaincodes
              [Group] mycc
                  [Value] ChaincodeIdentifier
                      bytes hash = 1;
                      string version = 2;
                  [Value] ChaincodeValidation
                      string name = 1;     // Set to vscc
                      bytes argument  = 2; // A marshaled:
                          message VSCCArgs
                              string endorsement_policy_ref = 1;
                  [Value] ChaincodeEndorsement
                      string name = 1; // Set to escc
      Change-Id: Ic2d02fb11a55779031eedce898902bc67185a4aa
      Signed-off-by: default avatarJason Yellick <jyellick@us.ibm.com>
  7. 13 Oct, 2017 1 commit
  8. 05 Aug, 2017 1 commit
  9. 26 May, 2017 1 commit
    • Jason Yellick's avatar
      [FAB-4105] Fab proto translation methods · b9dd4640
      Jason Yellick authored
      With the work done for FAB-4100 through FAB-4104, it is now possible to
      add a few small descriptive methods to proto methods, and the proto
      translator framework can then transalte the binary proto (including
      fields which would ordinarilly be expressed as binary, or nested binary)
      into pure binary-less JSON.
      This CR adds the methods necessary to annotate the fabric protos related
      to configuration.  This now allows the proto translation framework to
      print fully human readable versions of both config update messages, as
      well as of configuration blocks (and any subset thereof).
      This CR appears to introduce substantial amounts of code with very
      little tests.  However, the two tests in blackbox_test use every method
      introduced.  Additionally, because these methods are only used for proto
      printing, they can have no affect on the stability of the fabric
      This is a key component for FAB-1678.
      Change-Id: If166a55097dccef5208c1dc2ccd3bf039b7637d0
      Signed-off-by: default avatarJason Yellick <jyellick@us.ibm.com>