Commit Graph
19 Commits
Author SHA1 Message Date
Jacques Le Roux 265cc7f83e Improved: Remove deprecation warning by removing direct call to Class::newInstance
Class.newInstance() has a flaw, in which any Throwable from the constructor is
thrown unchecked. It was deprecated in Java 9, but not marked for removal.
It shows as a deprecation warning when compiling OfBiz with Java 11.

Thanks: Heinz Kabutz for reporting and initially committing 0e6732b. This
completes in plugins and all will we backported
2022-04-01 10:41:55 +02:00
Michael Brohl a38685f23d Improved: Update Redoc to v2.0.0-rc.59 (OFBIZ-12520) 2022-02-22 23:44:55 +01:00
Michael Brohl cea04fea0f Improved: Update to Swagger UI 4.2.1 (OFBIZ-12519) 2022-02-22 23:43:45 +01:00
Jacques Le Roux 537a4591e2 Improved: Fix some bugs Spotbugs reports (OFBIZ-12386)
We don't fear collisions for "servletContext". It's only initialised by
contextInitialized() and then only read before being destroyed by
contextDestroyed()

Also initialises servletContextto null
2021-12-23 17:13:54 +01:00
Michael Brohl f33ff27059 Fixed: Typo in debug log message. 2021-12-15 16:53:09 +01:00
Jacques Le Roux b5cad1d5e1 Improved: Fix some bugs Spotbugs reports (OFBIZ-12386)
In PricatParseExcelHtmlThread::storePricatFile try to fixes a possible null
dereferencement but does not work (weird).
The error is NP_NULL_ON_SOME_PATH_FROM_RETURN_VALUE

In OpenApiUtil::getSchemaForEntity fixes a possible null dereferencement
2021-12-09 11:59:29 +01:00
Jacques Le Roux 1f0cca7fa4 Improved: Fix some bugs Spotbugs reports (OFBIZ-12386)
Renames BirtEngineServlet class to OfbizBirtEngineServlet, because it shadowed
the simple name of it superclass.
It can be exceptionally confusing, create lots of situations in which you have
to look at import statements to resolve references and creates many
opportunities to accidentally define methods that do not override methods
in their superclasses.

Also remove trailing spaces in OpenApiUtil class
2021-12-05 12:59:59 +01:00
Michael Brohl 421e0e7994 Fixed: REST-API Plugin: Remove errors and warnings in generated openapi
documentation (OFBIZ-12426)

This fixes the following errors and warnings which are displayed by the
Swagger Editor (editor.swagger.io) when reading the generated openapi
documentation:

Errors fixed
* "Header parameters named "Authorization" are ignored. Use the
`securitySchemes` and `security` sections instead to define
authorization."
* "Structural error at paths./....parameters.0 should have either a
`schema` or `content` property"
the generated parameters from the service definition now have schema
entries generated
* the same applies to the WWW-Authenticate header in the responses

Warnings fixed

* "Header parameters named "Accept" are ignored. The values for the
"Accept" header are defined by `responses.<code>.content.<media-type>`."
2021-12-01 17:58:20 +01:00
Jacques Le Roux 9d4c9fcaff Improved: Update build.gradle to the latest dependencies (OFBIZ-12311)
The tests fails locally but it makes no sense, trying w/ BUilbot...
2021-09-06 10:05:40 +02:00
Jacques Le Roux 190e816364 Fixed: Add http to https redirect rule for ofbiz.apache.org (OFBIZ-10590)
This prevented to run the stable demo, hence the next, weirdly the trunk had
not this problem. Anyway better safe than sorry... Maybe related to Gradle
version or rather libs loaded?

The reason why the stable (and old) demos were not running is because the
EntitySaxReaderTests did not pass
2021-07-20 07:47:25 +02:00
Girish Vasmatkar 510239a5f2 Improved: Added CORS filter for the rest-api (OFBIZ-12220).
Thanks Alexander Gepting for the contribution.
2021-04-06 11:16:52 +05:30
Girish Vasmatkar 45e246bce0 Improved: Added CORS filter for the rest-api (OFBIZ-12220).
Thanks Alexander Gepting for the contribution.
2021-04-06 10:37:03 +05:30
Michael Brohl 57d24425df Improved: Updates swagger ui version to 3.45.1, moves and updates README
(OFBIZ-12207)
2021-03-28 23:55:51 +02:00
Michael Brohl 5eb003e1a6 Improved: Updates Redoc version and makes it locally available
(OFBIZ-12207)

The reference was chanegd from cdn-hosted version to a locally saved
version to avoid integrity check mechanism and making it possible to
track the used version in the README.
2021-03-28 23:55:51 +02:00
Michael Brohl 66055a731a Improved: Fixes sonarcloud error by using the resource integrity feature
for embedding external redoc javascript file (OFBIZ-12197)
2021-03-27 10:45:17 +01:00
Michael Brohl 84d705373f Improved: Fixes html bugs spotted by sonarcloud (OFBIZ-12197) 2021-03-27 10:45:17 +01:00
Michael Brohl b5c6a17024 Improved: Corrects asciidoc levels and follows one-sentence-per-line
rule (OFBIZ-12197)
2021-03-27 10:45:17 +01:00
Michael Brohl 1a6e4f8294 Improved: Removes "ofbiz" prefix from files and folders, code cleanup
(OFBIZ-12197)
2021-03-27 10:45:17 +01:00
Michael Brohl 107b26b66c Improved: Remove ofbiz prefix from files and folders (OFBIZ-12197)
Renames ofbiz-rest-impl to rest-api.
2021-03-27 10:45:17 +01:00