-
Notifications
You must be signed in to change notification settings - Fork 37
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
Fill ipfix_message components #141
Comments
We have introduced You need to update the older plugins to use the new The reason the |
Yes, I believe the API version check is broken. All our plugins have the constant defined in the same way as plugins developed and maintained by CESNET, but the discrepancy was never revealed before. The code does indeed also crash when the Although it would be great to have functions like |
The point of the API version is that it is increased whenever the API changes and is no longer compatible. All plugins must be checked and the API version can be increased to match only after the plugin is adjusted to the new API. However, I agree that this is mainly a check that prevents loading old plugins to newer collector. Recompilation of these plugins increases the API automatically. You can adapt the API version mechanism so that the version number is not taken from api.h, but rather set manually. Then, when the number increases, you will not be able to run the plugin until it is properly checked. Would that work for you? Basically it would require to set As for the |
Extending the API version check from our plugins would certainly work and I'll update our code soon. Thanks for hinting in that direction. As for the message components, what about |
We had several intermediate plugins that were running perfectly fine, also when they were chained. Last week, we found out however that adding the ODIP plugin to the plugin chain made IPFIXcol crash. The problem was actually rather simple: in March 2015, some components were added to
struct ipfix_message
, such asmetadata
. Our plugins were developed before those components were introduced and completely ignored those components, also when duplicating and editing IPFIX messages. As such,metadata
, for example, was not available in IPFIX messages anymore, while the ODIP plugin expects them to be there: SEGFAULT.To solve or work-around this, I was wondering what would be a good approach. Some ideas:
intermediate_process.c
, right after callingintermediate_process_message
, and draw an error if the new components are missing.message_create_from_mem
. Funny enough, this function accepts some (older)ipfix_message
components (i.e.,input_info
andsource_status
) as arguments, while the new components (e.g.,metadata
) seem to have been forgotten. Regarding a functional split, we could think about a method that duplicates an IPFIX message without data (i.e., without (option) template sets and data sets) and one that includes data. The split could also be achieved using function arguments, of course.Any other ideas are welcome.
The text was updated successfully, but these errors were encountered: