pnoltes opened a new pull request, #765:
URL: https://github.com/apache/celix/pull/765
# Refactor Manifest Format to JSON
This PR refactors the MANIFEST format to JSON. Consequently, the custom
manifest parsing is removed, and the properties JSON format is now used.
## Additional Changes
This PR has grown considerably larger than initially intended due to the
following additional changes:
- **Deprecation Clean-Up**: Some of the framework deprecated APIs have been
moved to the framework `src` directory, and deprecated code that was no longer
used has been removed. This cleanup primarily focused on bundle and module api.
- **Source File Updates**: Many source files were updated, mostly to adjust
include statements. In some cases, usage of deprecated bundle api has been
replaced.
### Manifest Attribute Definitions
- **Private Defines**: Mandatory and recognized optional manifest attribute
names are no longer defined in `celix_constants.h`. Instead, they are private
defines within the bundle manifest source file.
- **New Functions**: Functions were added to explicitly retrieve the values
of mandatory or recognized optional manifest attributes.
- **Manifest Attribute Names**: The used manifest attribute names has
changed to be more aligned with the naming scheme of config properties.
### CMake Function Names
The CMake function `celix_bundle_headers` remains unchanged, ensuring no
breaking changes. i.e.:
```cmake
celix_bundle_headers(my_bundle "Attribute1: Value1" "Attribute2: Value2")
```
still works.
This is the same approach was done for the container config properties
(e.g., `celix_container_runtime_properties` and
`celix_container_embedded_properties` are backwards compatible). However,
because `celix_bundle_headers` is not as heavily used, it might be beneficial
to introduce a new CMake function that accepts separated arguments for
attribute names and values, such as:
```cmake
celix_bundle_manifest(my_bundle "Attribute1" "Value1")
```
### Bundle Packaging
- Currently, a bundle zip can be created with `jar` if the `jar` executable
is available. This was beneficial for ensuring the MANIFEST.MF file was the
first file in the zip.
- With the JSON format, this benefit is no longer relevant.
- We can keep the support for using `jar` to package a bundle, but we could
also drop jar support.
### Future Work
After this PR is merged, my plan is to continue with #509 by:
1. Moving all deprecated API headers (except those used in remote services)
to the framework `src` directory.
2. Renaming, refactoring, or removing the deprecated functions.
In a subsequent pull request, the remote services implementation will be
refactored to remove the usage of the remaining deprecated APIs.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]