Skip to content
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

tmf: Use ITmfConfiguration configuration create and update methods #167

Merged
merged 1 commit into from
Oct 22, 2024

Conversation

bhufmann
Copy link
Contributor

  • Add new API and default implementation of create and update methods in ITmfConfigurationSource.
  • Change create method of ITmfDataProviderConfigurator. It has not been released and can be changed.

This is as alternative to Map<String, Object>.

[Added] ITmfConfiguration configuration create and update methods

Signed-off-by: Bernd Hufmann [email protected]

} catch (Exception e) {
throw new TmfConfigurationException("Can't convert input configuration to Map to create configuration", e); //$NON-NLS-1$
}
return create(map);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can just pass configuration.getParameters() directly?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True. That will make it simpler and not dependency to GSON is added.

} catch (Exception e) {
throw new TmfConfigurationException("Can't convert input configuration to Map to update configuration", e); //$NON-NLS-1$
}
return update(id, map);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can just pass configuration.getParameters() directly?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True. That will make it simpler and not dependency to GSON is added.

* Creates a new configuration instance.
* <p>
* The parameters to be provided are described by
* {@link ITmfConfigurationSourceType#getConfigParamDescriptors()}.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

by schema or list of ....

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

/**
* Updates a configuration instance.
* <p>
* The parameters to be provided are described by
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

by schema or list of ...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

- Add new API and default implementation of create and update methods in
ITmfConfigurationSource.
- Change create method of ITmfDataProviderConfigurator. It has not been
released and can be changed.

This is as alternative to Map<String, Object>.

[Added] ITmfConfiguration configuration create and update methods

Signed-off-by: Bernd Hufmann <[email protected]>
@bhufmann bhufmann merged commit f2c6cfd into eclipse-tracecompass:master Oct 22, 2024
4 checks passed
@bhufmann bhufmann mentioned this pull request Oct 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants