@Test public void update処理が正常に終了する() { EsIndex index = esClient.idxUser(UNIT_PREFIX, UNIT_USER_NAME); assertNotNull(index); ODataLinkAccessor linkAccessor = new ODataLinkAccessor(index, TYPE_NAME, ROUTING_ID); LinkDocHandler docHandler = createTestLinkDocHandler(); DcIndexResponse createResponse = linkAccessor.create(docHandler); assertNotNull(createResponse); assertFalse(createResponse.getId().equals("")); String updateString = "updatedEnt1Key"; docHandler.setEnt1Key(updateString); DcIndexResponse updateResponse = linkAccessor.update(createResponse.getId(), docHandler); assertNotNull(updateResponse); assertEquals(createResponse.getId(), updateResponse.getId()); if (linkAccessor.getAds() != null) { JdbcAds ads = null; try { ads = new JdbcAds(); List<JSONObject> list = ads.getLinkList(INDEX_NAME, 0, 1); assertEquals(1, list.size()); assertEquals(updateString, ((JSONObject) list.get(0).get("source")).get("k1")); } catch (Exception e) { fail(e.getMessage()); } } linkAccessor.delete(docHandler); }
public DcIndexResponse update(String id, LinkDocHandler docHandler) { return this.update(id, docHandler, -1); }
ODataLinkAccessor extends DataSourceAccessor { public DcIndexResponse update(String id, LinkDocHandler docHandler) { return this.update(id, docHandler, -1); } }
ODataLinkAccessor extends DataSourceAccessor { public DcIndexResponse update(String id, LinkDocHandler docHandler) { return this.update(id, docHandler, -1); } ODataLinkAccessor(EsIndex index, String name, String routingId); }
ODataLinkAccessor extends DataSourceAccessor { public DcIndexResponse update(String id, LinkDocHandler docHandler) { return this.update(id, docHandler, -1); } ODataLinkAccessor(EsIndex index, String name, String routingId); DcIndexResponse create(final LinkDocHandler docHandler); DcIndexResponse create(String id, LinkDocHandler docHandler); DcIndexResponse update(String id, LinkDocHandler docHandler); DcIndexResponse update(String id, LinkDocHandler docHandler, long version); DcDeleteResponse delete(final LinkDocHandler docHandler); DcDeleteResponse delete(final LinkDocHandler docHandler, long version); }
ODataLinkAccessor extends DataSourceAccessor { public DcIndexResponse update(String id, LinkDocHandler docHandler) { return this.update(id, docHandler, -1); } ODataLinkAccessor(EsIndex index, String name, String routingId); DcIndexResponse create(final LinkDocHandler docHandler); DcIndexResponse create(String id, LinkDocHandler docHandler); DcIndexResponse update(String id, LinkDocHandler docHandler); DcIndexResponse update(String id, LinkDocHandler docHandler, long version); DcDeleteResponse delete(final LinkDocHandler docHandler); DcDeleteResponse delete(final LinkDocHandler docHandler, long version);  }