DPSE Static discovery RTI ME 2.2.3

10 posts / 0 new
Last post
Offline
Last seen: 10 years 7 months ago
Joined: 08/28/2013
Posts: 66
DPSE Static discovery RTI ME 2.2.3

Hi,

I am dealing with dpse (dpde works fine) and based on helloworld example, i developped this part.

I got this error when asserting for "acceptable participant":
  empty/RemoteParticipant.c:625/NDDS_DomainParticipant_enable_remote_participant_name:name=dummyName

So what i would like, is to catch this error.
By looking in the code, i saw that a built-in listener exists (DPSE_ParticipantBuiltinDataReaderListener_initialize) and that this error is raised in on_data_available.

But i do not know how to set this listener.

*)Should i use a DDS_DomainParticipantListener or the built-in Listener ?


Regards,

Rodolf



Offline
Last seen: 10 years 7 months ago
Joined: 08/28/2013
Posts: 66

Hi folks,

Also, why do I have this kind of error:

[1059.299999989] ERROR:ModuleID=7,Errcode=86,X=0,E=1,STATUS=0
  <not found>/<not found>:-1/<not found>:<not found>

[1060.299999989] ERROR:ModuleID=7,Errcode=86,X=0,E=1,STATUS=0
  <not found>/<not found>:-1/<not found>:<not found>
........


This comes after a while of :
[1058.299999989] ERROR:ModuleID=7,Errcode=86,X=1,E=0,STATUS=f8000068
  empty/RemoteParticipant.c:625/NDDS_DomainParticipant_enable_remote_participant_name:name=dummyName.


Regards,

Rodolf

Offline
Last seen: 10 years 7 months ago
Joined: 08/28/2013
Posts: 66

delete contents

Offline
Last seen: 10 years 7 months ago
Joined: 08/28/2013
Posts: 66

delete contents

Offline
Last seen: 10 years 7 months ago
Joined: 08/28/2013
Posts: 66

delete contents

Offline
Last seen: 10 years 7 months ago
Joined: 08/28/2013
Posts: 66

Hi,

I dont understand the behaviour of the product.
When calling DDS_DomainParticipantFactory_delete_participant once everything has been deleted correctly (i guess), i got an error "out of ressource" when selecting the records in table remote_participant_table:

key = NDDS_DomainParticipant_get_key(self);
if (participant->remote_participant_table){
cursor = NULL;
dbrc = DB_Table_select_all_default(participant->remote_participant_table,&cursor);
}
Here dbrc is out of ressource and ressources seems to be linked to table cursor which is always 1 (initializer and RTI source code).

I don t manage to kill all DDS entities and clean my process.

Rgds

I have done this code:
*******************************************
Construction
***************
NDDS_DomainParticipant_assert_remote_participant(participant,&rem_parti_data,&is_new);
NDDS_DomainParticipant_assert_remote_publication(participant,this->dpseConf->partnerName,&rem_publication_data,NDDS_TYPEPLUGIN_USER_KEY);
*****************************************
Destruction
******************
NDDS_DomainParticipant_enable_remote_participant_name(participant,&rem_parti_data);   <------ enable needed otherwise next call fails because of timer ????NDDS_DomainParticipant_remove_remote_participant(participant,&rem_parti_data.key);   <---- this remove includes remove_remote_publication
...

DDS_DomainParticipantFactory_delete_participant(DDS_DomainParticipantFactory_get_instance(),this->participant);  <----- FAILS !!!







 

 

 

 

Offline
Last seen: 10 years 7 months ago
Joined: 08/28/2013
Posts: 66

So I have a better idea of what is happening but really, it seems configuration of RTI DDS is very touchy.

*My error "out_of_ressources" when process was selecting a cursor in a table was linked to a previous function call: DDS_DomainParticipant_get_discovered_participants().
MAY BE, with this call i was getting the only ressource. --> This code was not used so i remove it and now it seems better. BUT:

I have a test where i boot and launch a datareader and a built in publication and remote participant.
I launch the corresponding datawriter and everything is OK
I kill the datawriter, destroy all entities of my datareader (except partipant), recreate the datareader and the built in remote publication and participant.
I launch the corresponding datawriter and everything is OK

Now i keep my datawriter and destroy all entities of my datareader (except partipant), recreate the datareader and the built in remote publication and participant.
Then i got error:

ERROR:ModuleID=7,Errcode=84,X=1,E=0,STATUS=f8000084
  empty/RemoteParticipant.c:395/NDDS_DomainParticipant_refresh_remote_participant_liveliness:name=toto,ms=100000.

I have seen that calling NDDS_DomainParticipant_enable_remote_participant_name is doing something with timers so i added this call at init.

Now, i do my test again:

i boot and launch a datareader and a built in publication and remote participant.
Calling enable_remote function is making a match on local participant between its datareader (2.2.2.4) and the expected datawriter which is not yet here (3.3.3.3)
Shall i understand that calling "enable" means that i know that this remote will be here and so in advance i make a match ?
I launch the corresponding datawriter and i got following error:

Datareader side:
[273.583333310] ERROR:ModuleID=6,Errcode=60,X=1,E=0,STATUS=f0000000
  empty/RTPSInterface.c:3213/RTPSInterface_receive:oute

I kill the datawriter. ----> Datareader lost its match.
I relaunch the corresponding datawriter and everything is OK. ?????

 

Offline
Last seen: 10 years 7 months ago
Joined: 08/28/2013
Posts: 66

For ERROR:ModuleID=7,Errcode=84,X=1,E=0,STATUS=f8000084
  empty/RemoteParticipant.c:395/NDDS_DomainParticipant_refresh_remote_participant_liveliness:name=toto,ms=100000.

in fact update of timer failed.

What should i do for this update to be successful or how to clean this entry before error raised in DPSE_ParticipantBuiltinDataReaderListener_on_data_available.

Offline
Last seen: 6 years 7 months ago
Joined: 01/17/2013
Posts: 22

Hi Rodolf,

Starting from your comment #1, "empty/RemoteParticipant.c:625/NDDS_DomainParticipant_enable_remote_participant_name:name=dummyName" indicates a participant received a discovery message from a remote participant, but the name of the remote participant, communicated in the discovery message, does not match any locally asserted remote participant names.  The HelloWorld_dpse example shows how a remote participant is asserted with a remote_participant_name parameter: 

retcode = DPSE_RemoteParticipant_assert(application->participant,
                                            remote_participant_name);
    if (retcode != DDS_RETCODE_OK) {
        printf("failed to assert remote participant\n");
        goto done;
    }
 

Can you verify that the participant names match in your application?

A note on the DPSE_ParticipantBuiltinDataReaderListener: it is the listener used by a participant's internal/builtin reader for receiving participant discovery messages, where it receives samples via its on_data_available that you've looked at.  It should not need to be changed or extended by a user.  

For comment #2, "[1059.299999989] ERROR:ModuleID=7,Errcode=86,X=0,E=1,STATUS=0 ... <not found>/<not found>:-1/<not found>:<not found>" is the same error as above, but without the filename, function name, line number, etc displayed.  I will get back to you on why those are not found to be displayed.

For comment #6, do I understand correctly that your application is calling directly the functions NDDS_DomainParticipant_assert_remote_participant(), NDDS_DomainParticipant_enable_remote_participant_name(), and NDDS_DomainParticipant_remove_remote_participant()? That should not be necessary.  As done in the HelloWorld_dpse example, the function to assert a remote participant for DPSE is DPSE_RemoteParticipant_assert() and the function to assert a remote publication is DPSE_RemotePublication_assert().

For comment #7, DDS_DomainParticipant_get_discovered_participants() is present in the header file but it is not a supported function (it is not publicly documented) and from code-inspection I see a problem where a database cursor is not finished, so you are correct that its call was responsible for your "out of resources" log message.

NDDS_DomainParticipant_enable_remote_participant_name() is an internal API and should not be called by the user.  That you're getting the error msg " ERROR:ModuleID=7,Errcode=84,X=1,E=0,STATUS=f8000084, empty/RemoteParticipant.c:395/NDDS_DomainParticipant_refresh_remote_participant_liveliness:name=toto,ms=100000." may be because of what I asked about for comment #1 where the participant names do not match in your application.  Let me know if this still happens after you check and update your application.

Regards,

Edward

 

 

 

 

 

Offline
Last seen: 10 years 7 months ago
Joined: 08/28/2013
Posts: 66

Hi Edward,

Thanks for reply.
In fact you are right. Helloworld_dpse is working fine.

I made a mistake by willing:

1/ reconstruct my entities except the participant in dpse.
2/ calling at cleaning step NDDS_DomainParticipant_remove_remote_participant.

It is working well (datawriter always publishing + creation/destruction/creation of corresponding datareader)

Thanks a lot, i was going in the wrong direction.

Regards,

Rodolf

#comment 1: i am sure that name of remote participant is correct. (also wireshark shows that GUID and name are correct on both side)
#comment 6: yes i was using internal functions for my DPSE. In fact, at a certain time of development i have lighted out that i needed to construct myself the participantbuitin data (not the case through function DPSE_assert_remote which creates its built in data based on next available ID which i could not know later on if needed).

I made a test where i specify rtps_id host_id and instance_id to see if it is working also well.
And here, at reconstruction i got the error:

ERROR:ModuleID=7,Errcode=83,X=1,E=0,STATUS=f800006c
  empty/RemoteParticipant.c:369/NDDS_DomainParticipant_refresh_remote_participant_liveliness:name=

 

ERROR:ModuleID=10,Errcode=43,X=1,E=0,STATUS=f0000000
  empty/DPSEParticipantListener.c:268/DPSE_ParticipantBuiltinDataReaderListener_on_data_available:

So when i specify a GUID for the participants, it is not working.
In fact with DPSE_remote_assert the key in table is 0.0.0.x
When the partners connect, in on_data_available, it receives 3.3.3.x
So key is not found which leads to error.

remote_participant = NULL;
dbrc = DB_Table_select_match(participant->remote_participant_table,DB_TABLE_DEFAULT_INDEX,(DB_Record_T*)&remote_participant,(DB_Key_T) key);
if (dbrc != DB_RETCODE_OK)
             DDSC_Log_refresh_rem_participant(OSAPI_LOGKIND_ERROR,remote_participant->data.participant_name.name);

The pitty seems to be that for GUID unknown, RTI calls NDDS_DomainParticipant_lookup_name.
In the other case, it makes 
DB_Table_select_match(participant->remote_participant_table,DB_TABLE_DEFAULT_INDEX,(DB_Record_T*)&record,(DB_Key_T)&data->key);
+ NDDS_DomainParticipant_lookup_name(participant,data->participant_name.name);

I hope we can find a solution for this use case.
In comparison to helloworld_dpse example, add host id, instance id , to have a custom GUID and to find out about this issue.

Regards,

Rodolf