Releases: LabKey/labkey-api-java
Releases · LabKey/labkey-api-java
v5.0.0
- Refactor the
Commandclass hierarchy:- Add
GetCommand, new abstract base class for all commands that use get - Make
CommandandPostCommandabstract - Add
SimpleGetCommand, new concrete class used (instead ofCommand) to invoke GET API actions without creating a subclass - Add
SimplePostCommand, new concrete class used (instead ofPostCommand) to invoke POST API actions without creating a subclass
- Add
- Refactor parameter handling for consistency:
createParameterMap()is now used by subclasses to create and populate a mutable map of URL parametersgetParameters()now returns an immutable copy of the current URL parameter map for external use, typically logging or testing- Commands no longer stash and reuse the parameter map;
createParameterMap()always creates a new map. setParameters()is now available only onSimpleGetCommandandSimplePostCommand. CustomGetCommandandPostCommand
subclasses that need to specify parameters are expected to overridecreateParameterMap().setJsonObject()is now available only onSimplePostCommand. CustomPostCommandsubclasses that need to post JSON are
expected to overridegetJsonObject().
- Stop passing command subclasses when constructing every
CommandResponse. The two response classes that need this now implement
it without burdening all other commands. - Introduce
HasRequiredVersioninterface and use it when instantiatingCommandResponsesubclasses that need required version - Remove all
Commandcopy constructors. Same rationale as the earlier removal ofcopymethods. - Switch
SelectRowsCommandandNAbRunsCommandto post their parameters as JSON - Fix NAbReplicate to handle
"NaN"values - Remove
CommandExceptionfromgetHttpRequest()throws list - Adjust the
Demo.javaandTest.javatests to match current sample data andCommandhierarchy changes
v4.3.1
- Fix regression introduced in 4.3.0:
SelectRowsCommandshould create a fresh parameter map for every invocation ofgetParameters()
v4.3.0
- Issue 47030: Switch
SelectRowsCommandandNAbRunsCommandto always use POST - Add support for
includeTotalCount,includeMetadata, andignoreFilterflags toBaseQueryCommandand reconcile duplicate parameter handling code vs. SelectRowsCommand - Add support for
includeTitleandincludeViewDataUrlflags toGetQueriesCommand
v4.2.0
- Refactor repository layout, removing unnecessary
labkey-client-apifolder - Upgrade to most recent Gradle, Gradle Plugins, and HttpClient versions
v4.0.0
- Migrate to a new JSON library: JSON-java. The previous library, json-simple is no longer maintained (last released in early 2012) and lacks support for basic features like generics. This is an incompatible API change for developers who write their own Command classes; they will need to update their Command classes if/when they upgrade to v4.0.0. Developers who simply use Command classes should be able to upgrade without changes.
- API changes:
- Remove
copymethod from Commands. It was inconsistently implemented and served little purpose. - Remove
CommandResponse.getSourceCommand. Functionality would vary wildly because of inconsistentCommand.copyimplementations. - Make the properties stashed by
ResponseObjectimmutable.
- Remove
- Issue 46321: Remove
libdirectory fromfatJarin favor of pulling dependencies via the published pom files when needed - Remove artifactory plugin since we use the maven
publishcommand now
v3.1.0
- Add support for creating Freezer Manager freezer hierarchies via StorageController APIs (earliest compatible LabKey Server version: 22.10.0)
- CreateCommand, UpdateCommand, DeleteCommand
- Restore proactive authentication behavior. A change in v3.0.0 caused some invocations of
@NoPermissionsRequired
actions (e.g.,GetContainersCommand) to use guest credentials instead of the configured user credentials. The library
now always authenticates using the configured credentials, matching pre-v3.0.0 behavior.
v3.0.0
- Migrate internal HTTP handling to use Apache HttpClient 5.1.x
- Switch
StopImpersonatingCommandto disable redirects (mimicking previous behavior) - Add
Connection.stopImpersonating()and deprecatestopImpersonate() - Remove deprecated methods:
- ApiVersionException() (use constructor that takes contentType)
- CommandException() (use constructor that takes contentType)
- Connection.getBaseUrl() (use Connection.getBaseURI())
- CredentialsProvider.configureRequest() (use variant that takes a URI)
- Filter.NON_BLANK (use Filter.NONBLANK)
- Filter.getCaption() (use Filter.getDisplayValue())
- Filter.getName() (use Filter.getUrlKey())
- Filter.isDataValueRequired() (use Filter.isValueRequired())
- Remove SAS macros and wrapper classes
- Add
CreateFolderCommand - Add
CreateProjectCommand(earliest compatible LabKey Server version: 22.3.0) - Update
LogoutCommandto use POST
v2.0.0
- Require Java 17 to build and run
- v2.0.0 is functionally identical to v1.5.2, other than being compiled for Java 17
- Code that can't yet support Java 17 can continue to use v1.5.2, which was compiled for Java 8
- All future enhancements will target the 2.x line; we expect no further development on 1.x
v1.5.2
- Add Connection.setUserAgent() and Connection.getUserAgent()
- Set Java library user agent to "LabKey Java API"
- Set SAS library user agent to "LabKey SAS API"
v1.5.1
- Fix NPE when saving assay protocol with transform scripts
- Add derivationDataScope to PropertyDescriptor