-
Notifications
You must be signed in to change notification settings - Fork 62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Auto generated code for Inherited structure type IDL doesn't seem to work #12
Comments
I've tested your IDL and the generated example works for me. Indeed, changing |
Hi, Regards, |
Hi, Viresh and I are work to gether. In addition to what Viresh is reporting, we made one additional change. The change is to use the type name as base type name for registering the topic. We still used the derived type message structure for publishing the messages. We made thsi change to acheive communication between derived type publisher and base type subscriber to evaluate type extensibility. Initially, when we simply use the ild file generated code, it works. But the suscriber example generated from the base type ild file doesn't receive messages from the derivce pblisher. From examples and experiments done with RTI Connext code to acheive the same(Derived Pub->Base Sub), we made the change of type name to base type name for registering the topic. After this change, as soon as the publisher recognises a subscriber, it crashes with segmentation fault. To answer your other questions, the fastrtpsgen is latest version and the string is about 30 characters long. |
Hi, Seems there copypasta error in the code for generate :: getKeyMaxCdrSerializedSize for inherited type. Look at this:
|
This is a copy of the following comment:
eProsima/Fast-DDS#903 (comment)
Raising it as new as the other thread was closed already.
Hi ,
I was trying to check the sample code workign for inherited struct types in the IDL.
Though the subscriber seems to receive the data from other applications, the publisher crashes in CDR serialize(int32) with NoMemoryException.
I was wondering if it was related to the incomplete support for XCDR in serialization library.
Could you please confirm if the sample generated for the following IDL is due to this issue?
struct Msg {
@key long userID;
//@id 0
string message; //@id 1
};
//@extensibility EXTENSIBLE_EXTENSIBILITY
struct MsgExtended : Msg {
long dummy; //@id 2
};
//@extensibility EXTENSIBLE_EXTENSIBILITY
HelloWorld_IDL.txt
I made further changes in the test code (and some debug logs in Cdr.cpp too)to check if things would work but without any luck.
As the sample code itself crashes ,I am atttaching only the IDL .
Please let me know if any additional info is required.
The installation was from master. (i.e. compiled from source)
Thank you,
Viresh
Update:
Additional info:
Changes to Sample code made were:
a> change the topicKind to WITH_KEY from NO_KEY
b>Add sample data to the MsgExtended structure before publishing.
I think the keylessTopic might work but the intention was to achieve keyed topic . Ther applications in the system are using key and RTI admin console reported topic consistency error for mismatch between OSPL and FastRTPS application.
The text was updated successfully, but these errors were encountered: