public int post(final String path,
                  final String content) throws HttpException {
    try (CloseableHttpResponse hresp =
                 HttpUtil.doPost(http,
                                 resolve(path),
                                 getHeaders(),
                                 "application/json",
                                 content)) {
      return HttpUtil.getStatus(hresp);
    } catch (final HttpException he) {
      throw he;
    } catch (final Throwable t) {
      throw new HttpException(t.getMessage(), t);
    }
  }
public int post ( final String path , final String content ) throws HttpException { try ( CloseableHttpResponse hresp = HttpUtil . doPost ( http , resolve ( path ) , getHeaders ( ) , "application/json" , content ) ) { return HttpUtil . getStatus ( hresp ) ; } catch ( final HttpException he ) { throw he ; } catch ( final Throwable t ) { throw new HttpException ( t . getMessage ( ) , t ) ; } }
@param path of resource
@param content - assumed to be json
@return status
@throws HttpException on fatal error