Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sidecar-client-fabric
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
link33
sidecar-client-fabric
Commits
69dc9f85
Commit
69dc9f85
authored
Jun 18, 2020
by
Alexader
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
refactor(*): remove ibtp-id rollback in broker contract
parent
ba3f2a11
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
9 additions
and
13 deletions
+9
-13
Dockerfile
Dockerfile
+0
-7
Makefile
Makefile
+1
-1
client.go
client.go
+2
-5
broker.go
example/contracts/src/broker/broker.go
+3
-0
go.sum
go.sum
+3
-0
No files found.
Dockerfile
View file @
69dc9f85
...
...
@@ -52,11 +52,4 @@ ENV APPCHAIN_NAME=fabric
EXPOSE
44555 44544
# run pier inside container using:
# docker run -t --env APPCHAIN_NAME=ether \
# -v your/path/to/rule:/root/.pier/validating.wasm \
# -v your/path/to/pier.toml:/root/.pier/pier.toml \
# -v your/path/to/plugin_config:/root/.pier/ether \
# pier-fabric
ENTRYPOINT
["/root/docker_entrypoint.sh", "$APPCHAIN_NAME"]
Makefile
View file @
69dc9f85
...
...
@@ -24,7 +24,7 @@ docker:
mkdir
-p
build
cd
build
&&
rm
-rf
pier
&&
cp
-r
../../pier pier
cd
${
CURRENT_PATH
}
docker build
-t
pier-fabric .
docker build
-t
meshplus/
pier-fabric .
fabric1.4-linux
:
cd
scripts
&&
sh cross_compile.sh linux-amd64
${
CURRENT_PATH
}
...
...
client.go
View file @
69dc9f85
...
...
@@ -289,11 +289,8 @@ func (c *Client) SubmitIBTP(ibtp *pb.IBTP) (*model.PluginResponse, error) {
newArgs
=
append
(
newArgs
,
content
.
Args
[
0
])
newArgs
=
append
(
newArgs
,
result
...
)
case
"interchainCharge"
:
newArgs
=
append
(
newArgs
,
[]
byte
(
"false"
))
if
response
.
OK
{
newArgs
[
0
]
=
[]
byte
(
"true"
)
}
newArgs
=
append
(
newArgs
,
[]
byte
(
fmt
.
Sprintf
(
"%s-%d"
,
ibtp
.
To
,
ibtp
.
Index
)))
newArgs
=
append
(
newArgs
,
[]
byte
(
strconv
.
FormatBool
(
response
.
OK
)),
content
.
Args
[
0
])
newArgs
=
append
(
newArgs
,
content
.
Args
[
2
:
]
...
)
}
ret
.
Result
,
err
=
c
.
generateCallback
(
ibtp
,
newArgs
,
proof
)
...
...
example/contracts/src/broker/broker.go
View file @
69dc9f85
...
...
@@ -196,6 +196,9 @@ func (broker *Broker) InterchainInvoke(stub shim.ChaincodeStubInterface, args []
}
txValue
,
err
:=
json
.
Marshal
(
tx
)
if
err
!=
nil
{
return
shim
.
Error
(
err
.
Error
())
}
// persist out message
key
:=
broker
.
outMsgKey
(
tx
.
DstChainID
,
strconv
.
FormatUint
(
tx
.
Index
,
10
))
...
...
go.sum
View file @
69dc9f85
...
...
@@ -97,6 +97,7 @@ github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21 h1:YEetp8
github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1:+020luEh2TKB4/GOp8oxxtq0Daoen/Cii55CzbTV6DU=
github.com/eapache/queue v1.1.0 h1:YOEu7KNc61ntiQlcEeUIoDTJ2o8mQznoNvUhiigpIqc=
github.com/eapache/queue v1.1.0/go.mod h1:6eCeP0CKFpHLu8blIFXhExK/dRa7WDZfr6jVFPTqq+I=
github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98=
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
github.com/fastly/go-utils v0.0.0-20180712184237-d95a45783239 h1:Ghm4eQYC0nEPnSJdVkTrXpu9KtoVCSo1hg7mtI7G9KU=
...
...
@@ -282,6 +283,7 @@ github.com/huin/goupnp v1.0.0/go.mod h1:n9v9KO1tAxYH82qOn+UTIFQDmx5n1Zxd/ClZDMX7
github.com/huin/goutil v0.0.0-20170803182201-1ca381bf3150/go.mod h1:PpLOETDnJ0o3iZrZfqZzyLl6l7F3c6L1oWn7OICBi6o=
github.com/hyperledger/fabric v2.0.1+incompatible h1:7W+yG0gLKTC7NLcWPT3vfpnaseztPpH9wXGfAW7yvBs=
github.com/hyperledger/fabric v2.0.1+incompatible/go.mod h1:tGFAOCT696D3rG0Vofd2dyWYLySHlh0aQjf7Q1HAju0=
github.com/hyperledger/fabric v2.1.1+incompatible h1:cYYRv3vVg4kA6DmrixLxwn1nwBEUuYda8DsMwlaMKbY=
github.com/hyperledger/fabric-amcl v0.0.0-20200128223036-d1aa2665426a h1:HgdNn3UYz8PdcZrLEk0IsSU4LRHp7yY2rgjIKcSiJaA=
github.com/hyperledger/fabric-amcl v0.0.0-20200128223036-d1aa2665426a/go.mod h1:X+DIyUsaTmalOpmpQfIvFZjKHQedrURQ5t4YqquX7lE=
github.com/hyperledger/fabric-chaincode-go v0.0.0-20200511190512-bcfeb58dd83a h1:KoFw2HnRfW+EItMP0zvUUl1FGzDb/7O0ov7uXZffQok=
...
...
@@ -878,6 +880,7 @@ google.golang.org/genproto v0.0.0-20190927181202-20e1ac93f88c h1:hrpEMCZ2O7DR5gC
google.golang.org/genproto v0.0.0-20190927181202-20e1ac93f88c/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8=
google.golang.org/genproto v0.0.0-20200218151345-dad8c97a84f5 h1:jB9+PJSvu5tBfmJHy/OVapFdjDF3WvpkqRhxqrmzoEU=
google.golang.org/genproto v0.0.0-20200218151345-dad8c97a84f5/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
google.golang.org/grpc v1.28.1 h1:C1QC6KzgSiLyBabDi87BbjaGreoRgGUF5nOyvfrAZ1k=
google.golang.org/grpc v1.28.1/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60=
gopkg.in/airbrake/gobrake.v2 v2.0.9/go.mod h1:/h5ZAUhDkGaJfjzjKLSjv6zCL6O0LLBxU4K+aSYdM/U=
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment