Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Linux Foundation HFCP Exam - Topic 4 Question 18 Discussion

Posted by Alva on Sep 17, 2024 at 02:24 AM

What happens if the user submits a transaction with no matching function?

Suggested Answer: D

In Hyperledger Fabric, if a user submits a transaction with no matching function specified in the smart contract, the unknownTransaction function is invoked by default. This function serves as a catch-all method that can be used to handle cases where the transaction type is not recognized, providing a mechanism to manage or log these occurrences effectively .


Get Premium HFCP Questions as Interactive Web-Based Practice Test or PDF Real Exam Format Detailed Explanations Instant Access Get Your Practice Test
31 comments · newest first
LI
Lindsey 11 months ago
I agree with A, can't process what it doesn't recognize!
CA
Cassie 11 months ago
Wait, are you sure about that? I thought it would just error out.
ER
Erin 12 months ago
Definitely D, the unknownTransaction function should handle it!
HE
Helene 12 months ago
I think B makes more sense, it just gets ignored.
CO
Corinne 1 year ago
A is correct, the peer will reject it.
TH
Therese 1 year ago
I'm leaning towards the idea that the peer rejects the transaction, but I might be mixing it up with another topic we covered.
JA
Javier 1 year ago
I feel like I saw a question similar to this where an unknown function was called, but I can't recall the details.
CR
Crista 1 year ago
I remember something about transactions being ignored if they don't match, but that seems too simple.
CA
Carman 1 year ago
I think if there's no matching function, the transaction gets rejected, but I'm not entirely sure.
BO
Bok 1 year ago
I'm a little confused on this one. I know that if there's no matching function, the transaction can't be processed, but I'm not sure if that means it gets rejected or just ignored. I'll have to review the material again before deciding.
LA
Lavera 1 year ago
Okay, let me think this through step-by-step. If there's no matching function, the transaction can't be executed, so it seems like the most logical answer would be that it gets rejected. I'll go with option A.
TE
Teddy 1 year ago
Hmm, I'm not sure about this one. I'm thinking it might just get ignored, but I could be wrong. I'll have to think it through a bit more.
AM
Amber 1 year ago
I'm pretty sure the transaction will be rejected, so I'll go with option A.
ER
Erasmo 1 year ago
I'm a bit confused; I thought upgrade notifications were sometimes sent via email, but I guess that's more about alerts than actual logs.
GA
Gail 2 years ago
D is the way to go. Although, I'm curious if the 'unknownTransaction' function has easter eggs. Maybe it orders pizza automatically?
DY
Dyan 2 years ago
↳ replying to Gail
I wonder what other surprises the unknownTransaction function has.
KA
Kathrine 2 years ago
↳ replying to Gail
That would be cool if it ordered pizza automatically!
DO
Dortha 2 years ago
↳ replying to Gail
D is correct. The unknownTransaction function is called.
SU
Susana 2 years ago
I'm not sure, but I think it could also be D) The unknownTransaction function is called. It makes sense to handle unknown transactions that way.
KR
Kristofer 2 years ago
I agree with Deangelo, because if there's no matching function, the transaction should be rejected.
TH
Theron 2 years ago
I'm going with C. It's like the default case in a switch statement - gotta catch 'em all!
IS
Isaac 2 years ago
B is tempting, but I'd rather not have the transaction ignored. Imagine the chaos if that happened in production!
TE
Terina 2 years ago
↳ replying to Isaac
D) The unknownTransaction function is called.
DY
Dyan 2 years ago
↳ replying to Isaac
D) The unknownTransaction function is called.
LA
Lajuana 2 years ago
↳ replying to Isaac
B) Nothing, the transaction is ignored.
GA
Gary 2 years ago
↳ replying to Isaac
A) The peer will have rejected the transaction.
TA
Tayna 2 years ago
↳ replying to Isaac
A) The peer will have rejected the transaction.
PO
Polly 2 years ago
Option D seems the most logical, but my gut says A. I really hope the 'unknownTransaction' function isn't filled with glitter bombs!
WI
Willodean 2 years ago
↳ replying to Polly
I agree, it's better to go with option A to avoid any issues.
EL
Elouise 2 years ago
↳ replying to Polly
I think option A is correct. The peer will reject the transaction.
DE
Deangelo 2 years ago
I think the answer is A) The peer will have rejected the transaction.
0/2000 characters

Save Cancel