[zanata/zanata-server] 85fdef: Workaround TM result coalescing bug.
GitHub
noreply at github.com
Fri May 22 09:32:48 UTC 2015
Branch: refs/heads/new-tm-endpoints-rhbz1209669
Home: https://github.com/zanata/zanata-server
Commit: 85fdef5e256c3f46bebc60afd38cb032373dedc1
https://github.com/zanata/zanata-server/commit/85fdef5e256c3f46bebc60afd38cb032373dedc1
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/java/org/zanata/service/impl/TranslationMemoryServiceImpl.java
M zanata-war/src/main/java/org/zanata/webtrans/shared/model/TransMemoryResultItem.java
Log Message:
-----------
Workaround TM result coalescing bug.
Refactors the match processing code to make it clearer what type of
match is being added to a result item, and makes a few small changes
to minimize the incorrect behaviour:
- No longer adds imported TM item id to the list that is used to look
up text flows.
A more complete fix is to wrap the Long id in a type so that
all the ids are present and can be used sensibly. This just
makes the list appropriate for the code that uses it right
now, to delay spending the development time for the full fix.
- Upgrades match type when a match has a higher match type, where
ApprovedInternal > TranslatedInternal > Imported.
Imported is treated as lowest just because the editor suppresses
details display for Imported. Treating the others as higher will
allow users to see text flow details for the other types.
The full fix for this would be to inculde a summary of all the
match types in the DTO, so the editor can display whatever
makes sense.
Commit: 092da784411b6f7c061c2fc9f8e76669d32fbedc
https://github.com/zanata/zanata-server/commit/092da784411b6f7c061c2fc9f8e76669d32fbedc
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
A zanata-war/src/main/java/org/zanata/rest/editor/dto/suggestion/JsonDateSerializer.java
A zanata-war/src/main/java/org/zanata/rest/editor/dto/suggestion/Suggestion.java
A zanata-war/src/main/java/org/zanata/rest/editor/dto/suggestion/SuggestionDetail.java
A zanata-war/src/main/java/org/zanata/rest/editor/dto/suggestion/TextFlowSuggestionDetail.java
A zanata-war/src/main/java/org/zanata/rest/editor/dto/suggestion/TransMemoryUnitSuggestionDetail.java
Log Message:
-----------
Add DTOs for suggestions and suggestion detail.
These DTO classes are only configured to serialize to JSON, and I have
not considered deserialization since this is query data and not expected
to be uploaded to the server.
Commit: 97602636569fcb727be2b8f1702b1714bbc2ef58
https://github.com/zanata/zanata-server/commit/97602636569fcb727be2b8f1702b1714bbc2ef58
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/java/org/zanata/service/TranslationMemoryService.java
M zanata-war/src/main/java/org/zanata/service/impl/TranslationMemoryServiceImpl.java
Log Message:
-----------
Add method to get suggestions from TM service.
I have avoided changing the existing code paths for TM search for now
since it is a performance-critical component for translation copy. We
should combine the code paths in a separate operation as long as it
does not impact on performance.
Commit: 0db4fa07f9b6b3ad13adce41860a93f56cdc84a7
https://github.com/zanata/zanata-server/commit/0db4fa07f9b6b3ad13adce41860a93f56cdc84a7
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/java/org/zanata/rest/editor/MediaTypes.java
A zanata-war/src/main/java/org/zanata/rest/editor/service/SuggestionsService.java
A zanata-war/src/main/java/org/zanata/rest/editor/service/resource/SuggestionsResource.java
Log Message:
-----------
Add REST endpoint for suggestions for editor.
Commit: 3e92ccd6fd17550565c038b668e80014573db32a
https://github.com/zanata/zanata-server/commit/3e92ccd6fd17550565c038b668e80014573db32a
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/java/org/zanata/rest/editor/service/SuggestionsService.java
Log Message:
-----------
Keep format strings in the same scope as String.format()
Format strings were being passed to a function, which seems confusing
and so more error-prone. Changed to passing an already-formatted string
so that the format strings can be inlined in the call to String.format()
so that it is obvious that they are format strings and what the
placeholders represent.
Commit: 554f3e72e5b545bb72fc7d93890b96a515925100
https://github.com/zanata/zanata-server/commit/554f3e72e5b545bb72fc7d93890b96a515925100
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/java/org/zanata/rest/editor/service/SuggestionsService.java
Log Message:
-----------
Make search type lookup case-insensitive.
The try block could be removed because iterating enum values will not
give nulls, and equalsIgnoreCase will behave sensibly with an entered
null value.
Commit: 38156d76c976ccb604bc598d88e55c2b2aab2ac8
https://github.com/zanata/zanata-server/commit/38156d76c976ccb604bc598d88e55c2b2aab2ac8
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/java/org/zanata/rest/editor/service/SuggestionsService.java
M zanata-war/src/main/java/org/zanata/service/impl/LocaleServiceImpl.java
Log Message:
-----------
Prevent undeclared IllegalArgumentException when looking up locales.
Commit: d64cdda63fd4748d5d833a6189ffc591bf597413
https://github.com/zanata/zanata-server/commit/d64cdda63fd4748d5d833a6189ffc591bf597413
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/java/org/zanata/service/LocaleService.java
M zanata-war/src/main/java/org/zanata/service/impl/LocaleServiceImpl.java
Log Message:
-----------
Add @Nullable annotation to locale lookup.
Commit: e27c6fe52de3d67155ab7b8e6414397c5bdfe4c2
https://github.com/zanata/zanata-server/commit/e27c6fe52de3d67155ab7b8e6414397c5bdfe4c2
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/java/org/zanata/rest/editor/service/SuggestionsService.java
Log Message:
-----------
Use Option instead of Either in SuggestionService
Commit: 36b58240a99e0dc1be94bb1886956ded98c29ad2
https://github.com/zanata/zanata-server/commit/36b58240a99e0dc1be94bb1886956ded98c29ad2
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/java/org/zanata/rest/editor/MediaTypes.java
M zanata-war/src/main/java/org/zanata/rest/editor/service/resource/SuggestionsResource.java
Log Message:
-----------
Remove unused media type string for suggestions.
Changed to use the JSON media type for suggestions.
Commit: c830ddc24406952c40a2afc6afdf9471020c0c12
https://github.com/zanata/zanata-server/commit/c830ddc24406952c40a2afc6afdf9471020c0c12
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/java/org/zanata/rest/editor/service/resource/SuggestionsResource.java
Log Message:
-----------
Change source and translation locales for suggestions endpoint to query params.
Since locales can contain non-url-friendly characters, they are better included
as part of the query string.
Commit: eba50ecb4a5b6fff27bcd18f882cefa83fbc61ea
https://github.com/zanata/zanata-server/commit/eba50ecb4a5b6fff27bcd18f882cefa83fbc61ea
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/java/org/zanata/service/impl/LocaleServiceImpl.java
Log Message:
-----------
Refactor LocaleServiceImpl.getByLocaleId(String) for brevity.
Commit: a116d2c4e7462537c56d2cd9794ebfe1283cab47
https://github.com/zanata/zanata-server/commit/a116d2c4e7462537c56d2cd9794ebfe1283cab47
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M docs/release-notes.md
Log Message:
-----------
Add release note for suggestions endpoint.
Commit: 3c5bf2a30cfd43711863443143b8d7c29dfe6134
https://github.com/zanata/zanata-server/commit/3c5bf2a30cfd43711863443143b8d7c29dfe6134
Author: David Mason <drdmason at gmail.com>
Date: 2015-05-22 (Fri, 22 May 2015)
Changed paths:
M zanata-war/src/main/webapp/app/config.json
M zanata-war/src/main/webapp/app/css/app.css
M zanata-war/src/main/webapp/app/index.html
M zanata-war/src/main/webapp/app/js/app.js
M zanata-war/src/main/webapp/app/js/libs.js
M zanata-war/src/main/webapp/app/js/templates.js
M zanata-war/src/main/webapp/app/maps/app.js.map
M zanata-war/src/main/webapp/app/maps/libs.js.map
Log Message:
-----------
Update zanata-spa to commit 88381f3b4a8d83636453439bf56f08c3f09169f6
Compare: https://github.com/zanata/zanata-server/compare/0d70a40cda26...3c5bf2a30cfd
More information about the zanata-commits
mailing list