{"action":"created","comment":{"url":"https://api.github.com/repos/intel-hadoop/chimera/pulls/comments/49688156","id":49688156,"diff_hunk":"@@ -0,0 +1,266 @@\n+/**\n+ * Licensed to the Apache Software Foundation (ASF) under one\n+ * or more contributor license agreements.  See the NOTICE file\n+ * distributed with this work for additional information\n+ * regarding copyright ownership.  The ASF licenses this file\n+ * to you under the Apache License, Version 2.0 (the\n+ * \"License\"); you may not use this file except in compliance\n+ * with the License.  You may obtain a copy of the License at\n+ *\n+ *     http://www.apache.org/licenses/LICENSE-2.0\n+ *\n+ * Unless required by applicable law or agreed to in writing, software\n+ * distributed under the License is distributed on an \"AS IS\" BASIS,\n+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+ * See the License for the specific language governing permissions and\n+ * limitations under the License.\n+ */\n+package com.intel.chimera;\n+\n+import java.io.IOException;\n+import java.io.InputStream;\n+import java.nio.ByteBuffer;\n+import java.nio.channels.ReadableByteChannel;\n+import java.security.GeneralSecurityException;\n+import java.util.Properties;\n+import java.util.Queue;\n+import java.util.concurrent.ConcurrentLinkedQueue;\n+\n+import com.google.common.base.Preconditions;\n+import com.intel.chimera.crypto.Cipher;\n+import com.intel.chimera.input.ChannelInput;\n+import com.intel.chimera.input.Input;\n+import com.intel.chimera.input.StreamInput;\n+import com.intel.chimera.utils.Utils;\n+\n+public class PositionedCryptoInputStream extends CryptoInputStream {\n+\n+  /** DirectBuffer pool */\n+  private final Queue<ByteBuffer> bufferPool = \n+      new ConcurrentLinkedQueue<ByteBuffer>();\n+\n+  /** Cipher pool */\n+  private final Queue<CipherState> cipherPool = \n+      new ConcurrentLinkedQueue<CipherState>();\n+\n+  public PositionedCryptoInputStream(Properties props, InputStream in,\n+      byte[] key, byte[] iv, long streamOffset) throws IOException {\n+    this(in, Utils.getCipherInstance(props), Utils.getBufferSize(props), key, iv, streamOffset);\n+  }\n+\n+  public PositionedCryptoInputStream(Properties props, ReadableByteChannel in,\n+      byte[] key, byte[] iv, long streamOffset) throws IOException {\n+    this(in,  Utils.getCipherInstance(props), Utils.getBufferSize(props), key, iv, streamOffset);\n+  }\n+\n+  public PositionedCryptoInputStream(InputStream in, Cipher cipher,\n+      int bufferSize, byte[] key, byte[] iv, long streamOffset) throws IOException {\n+    this(new StreamInput(in, bufferSize), cipher, bufferSize, key, iv, streamOffset);\n+  }\n+\n+  public PositionedCryptoInputStream(ReadableByteChannel in, Cipher cipher,\n+      int bufferSize, byte[] key, byte[] iv, long streamOffset) throws IOException {\n+    this(new ChannelInput(in), cipher, bufferSize, key, iv, streamOffset);\n+  }\n+\n+  public PositionedCryptoInputStream(\n+      Input input,\n+      Cipher cipher,\n+      int bufferSize,\n+      byte[] key,\n+      byte[] iv,\n+      long streamOffset) throws IOException {\n+    super(input, cipher, bufferSize, key, iv, streamOffset);\n+  }\n+\n+  protected long getPos() throws IOException {\n+    checkStream();\n+    return streamOffset - outBuffer.remaining();\n+  }\n+\n+  /**\n+   * Decrypt length bytes in buffer starting at offset. Output is also put \n+   * into buffer starting at offset. It is thread-safe.\n+   */\n+  protected void decrypt(long position, byte[] buffer, int offset, int length) \n+      throws IOException {\n+    ByteBuffer inBuffer = getBuffer();\n+    ByteBuffer outBuffer = getBuffer();\n+    CipherState state = null;\n+    try {\n+      state = getCipherState();\n+      byte[] iv = getInitIV().clone();\n+      resetCipher(state, position, iv);\n+      byte padding = getPadding(position);\n+      inBuffer.position(padding); // Set proper position for input data.\n+\n+      int n = 0;\n+      while (n < length) {\n+        int toDecrypt = Math.min(length - n, inBuffer.remaining());\n+        inBuffer.put(buffer, offset + n, toDecrypt);\n+\n+        // Do decryption\n+        decrypt(state, inBuffer, outBuffer, padding);\n+\n+        outBuffer.get(buffer, offset + n, toDecrypt);\n+        n += toDecrypt;\n+        padding = postDecryption(state, inBuffer, position + n, iv);\n+      }\n+    } finally {\n+      returnBuffer(inBuffer);\n+      returnBuffer(outBuffer);\n+      returnCipherState(state);\n+    }\n+  }\n+\n+  /**\n+   * Do the decryption using inBuffer as input and outBuffer as output.\n+   * Upon return, inBuffer is cleared; the decrypted data starts at \n+   * outBuffer.position() and ends at outBuffer.limit();\n+   */\n+  private void decrypt(CipherState state, ByteBuffer inBuffer, \n+      ByteBuffer outBuffer, byte padding) throws IOException {\n+    Preconditions.checkState(inBuffer.position() >= padding);\n+    if(inBuffer.position() == padding) {\n+      // There is no real data in inBuffer.\n+      return;\n+    }\n+    inBuffer.flip();\n+    outBuffer.clear();\n+    decryptBuffer(state, inBuffer, outBuffer);\n+    inBuffer.clear();\n+    outBuffer.flip();\n+    if (padding > 0) {\n+      /*\n+       * The plain text and cipher text have a 1:1 mapping, they start at the \n+       * same position.\n+       */\n+      outBuffer.position(padding);\n+    }\n+  }\n+\n+  private void decryptBuffer(CipherState state, ByteBuffer inBuffer, ByteBuffer outBuffer)\n+      throws IOException {\n+    int inputSize = inBuffer.remaining();\n+    int n = state.getCipher().update(inBuffer, outBuffer);\n+    if (n < inputSize) {\n+      /**\n+       * Typically code will not get here. Cipher#update will consume all\n+       * input data and put result in outBuffer.\n+       * Cipher#doFinal will reset the cipher context.\n+       */\n+      state.getCipher().doFinal(inBuffer, outBuffer);\n+      state.reset(true);\n+    }\n+  }\n+\n+  /**\n+   * This method is executed immediately after decryption. Check whether\n+   * cipher should be updated and recalculate padding if needed.\n+   */\n+  private byte postDecryption(CipherState state, ByteBuffer inBuffer,\n+      long position, byte[] iv) throws IOException {\n+    byte padding = 0;\n+    if (state.isReset()) {\n+      /*\n+       * This code is generally not executed since the cipher usually\n+       * maintains cipher context (e.g. the counter) internally. However,\n+       * some implementations can't maintain context so a re-init is necessary\n+       * after each decryption call.\n+       */\n+      resetCipher(state, position, iv);\n+      padding = getPadding(position);\n+      inBuffer.position(padding);\n+    }\n+    return padding;\n+  }\n+\n+  /** Calculate the counter and iv, reset the cipher. */\n+  private void resetCipher(CipherState state, long position, byte[] iv)\n+      throws IOException {\n+    final long counter = getCounter(position);\n+    Utils.calculateIV(getInitIV(), counter, iv);\n+    state.getCipher().init(Cipher.DECRYPT_MODE, getKey(), iv);\n+    state.reset(false);\n+  }\n+\n+  /** Get Cipher from pool */\n+  private CipherState getCipherState() throws IOException {\n+    CipherState state = cipherPool.poll();\n+    if (state == null) {\n+      try {\n+        Cipher cipher = getCipher().newInstance();\n+        state = new CipherState(cipher);\n+      } catch(GeneralSecurityException e) {\n+        throw new IOException(e);\n+      }\n+    }\n+\n+    return state;\n+  }\n+\n+  /** Return Cipher to pool */\n+  private void returnCipherState(CipherState state) {\n+    if (state != null) {\n+      cipherPool.add(state);\n+    }\n+  }\n+\n+  /** Get direct buffer from pool */\n+  private ByteBuffer getBuffer() {\n+    ByteBuffer buffer = bufferPool.poll();\n+    if (buffer == null) {\n+      buffer = ByteBuffer.allocateDirect(getBufferSize());\n+    }\n+\n+    return buffer;\n+  }\n+\n+  /** Return direct buffer to pool */\n+  private void returnBuffer(ByteBuffer buf) {\n+    if (buf != null) {\n+      buf.clear();\n+      bufferPool.add(buf);\n+    }\n+  }\n+\n+  @Override\n+  public void close() throws IOException {\n+    if (!isOpen()) {\n+      return;\n+    }\n+\n+    cleanBufferPool();\n+    super.close();\n+  }\n+\n+  /** Clean direct buffer pool */\n+  private void cleanBufferPool() {","path":"src/main/java/com/intel/chimera/PositionedCryptoInputStream.java","position":238,"original_position":238,"commit_id":"f9c261b4914806a6286a38f4e540d696c424c6d5","original_commit_id":"f9c261b4914806a6286a38f4e540d696c424c6d5","user":{"login":"jerrychenhf","id":3349124,"avatar_url":"https://avatars.githubusercontent.com/u/3349124?v=3","gravatar_id":"","url":"https://api.github.com/users/jerrychenhf","html_url":"https://github.com/jerrychenhf","followers_url":"https://api.github.com/users/jerrychenhf/followers","following_url":"https://api.github.com/users/jerrychenhf/following{/other_user}","gists_url":"https://api.github.com/users/jerrychenhf/gists{/gist_id}","starred_url":"https://api.github.com/users/jerrychenhf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jerrychenhf/subscriptions","organizations_url":"https://api.github.com/users/jerrychenhf/orgs","repos_url":"https://api.github.com/users/jerrychenhf/repos","events_url":"https://api.github.com/users/jerrychenhf/events{/privacy}","received_events_url":"https://api.github.com/users/jerrychenhf/received_events","type":"User","site_admin":false},"body":"Can we also have a method cleanCipherPool to call the close method of the ciphers?","created_at":"2016-01-14T05:07:34Z","updated_at":"2016-01-14T05:07:34Z","html_url":"https://github.com/intel-hadoop/chimera/pull/40#discussion_r49688156","pull_request_url":"https://api.github.com/repos/intel-hadoop/chimera/pulls/40","_links":{"self":{"href":"https://api.github.com/repos/intel-hadoop/chimera/pulls/comments/49688156"},"html":{"href":"https://github.com/intel-hadoop/chimera/pull/40#discussion_r49688156"},"pull_request":{"href":"https://api.github.com/repos/intel-hadoop/chimera/pulls/40"}}},"pull_request":{"url":"https://api.github.com/repos/intel-hadoop/chimera/pulls/40","id":55981458,"html_url":"https://github.com/intel-hadoop/chimera/pull/40","diff_url":"https://github.com/intel-hadoop/chimera/pull/40.diff","patch_url":"https://github.com/intel-hadoop/chimera/pull/40.patch","issue_url":"https://api.github.com/repos/intel-hadoop/chimera/issues/40","number":40,"state":"open","locked":false,"title":"Add PositionedCryptoInputStream","user":{"login":"dianfu","id":5466492,"avatar_url":"https://avatars.githubusercontent.com/u/5466492?v=3","gravatar_id":"","url":"https://api.github.com/users/dianfu","html_url":"https://github.com/dianfu","followers_url":"https://api.github.com/users/dianfu/followers","following_url":"https://api.github.com/users/dianfu/following{/other_user}","gists_url":"https://api.github.com/users/dianfu/gists{/gist_id}","starred_url":"https://api.github.com/users/dianfu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dianfu/subscriptions","organizations_url":"https://api.github.com/users/dianfu/orgs","repos_url":"https://api.github.com/users/dianfu/repos","events_url":"https://api.github.com/users/dianfu/events{/privacy}","received_events_url":"https://api.github.com/users/dianfu/received_events","type":"User","site_admin":false},"body":"This PR add PositionedCryptoInputStream.","created_at":"2016-01-14T01:26:03Z","updated_at":"2016-01-14T05:07:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f3e56aec478c6a842d2b8d2c33d3ea08389a1cd6","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/intel-hadoop/chimera/pulls/40/commits","review_comments_url":"https://api.github.com/repos/intel-hadoop/chimera/pulls/40/comments","review_comment_url":"https://api.github.com/repos/intel-hadoop/chimera/pulls/comments{/number}","comments_url":"https://api.github.com/repos/intel-hadoop/chimera/issues/40/comments","statuses_url":"https://api.github.com/repos/intel-hadoop/chimera/statuses/f9c261b4914806a6286a38f4e540d696c424c6d5","head":{"label":"dianfu:positioned-stream","ref":"positioned-stream","sha":"f9c261b4914806a6286a38f4e540d696c424c6d5","user":{"login":"dianfu","id":5466492,"avatar_url":"https://avatars.githubusercontent.com/u/5466492?v=3","gravatar_id":"","url":"https://api.github.com/users/dianfu","html_url":"https://github.com/dianfu","followers_url":"https://api.github.com/users/dianfu/followers","following_url":"https://api.github.com/users/dianfu/following{/other_user}","gists_url":"https://api.github.com/users/dianfu/gists{/gist_id}","starred_url":"https://api.github.com/users/dianfu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dianfu/subscriptions","organizations_url":"https://api.github.com/users/dianfu/orgs","repos_url":"https://api.github.com/users/dianfu/repos","events_url":"https://api.github.com/users/dianfu/events{/privacy}","received_events_url":"https://api.github.com/users/dianfu/received_events","type":"User","site_admin":false},"repo":{"id":49476375,"name":"chimera","full_name":"dianfu/chimera","owner":{"login":"dianfu","id":5466492,"avatar_url":"https://avatars.githubusercontent.com/u/5466492?v=3","gravatar_id":"","url":"https://api.github.com/users/dianfu","html_url":"https://github.com/dianfu","followers_url":"https://api.github.com/users/dianfu/followers","following_url":"https://api.github.com/users/dianfu/following{/other_user}","gists_url":"https://api.github.com/users/dianfu/gists{/gist_id}","starred_url":"https://api.github.com/users/dianfu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dianfu/subscriptions","organizations_url":"https://api.github.com/users/dianfu/orgs","repos_url":"https://api.github.com/users/dianfu/repos","events_url":"https://api.github.com/users/dianfu/events{/privacy}","received_events_url":"https://api.github.com/users/dianfu/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/dianfu/chimera","description":"Cryptographic library optimized with AES-NI","fork":true,"url":"https://api.github.com/repos/dianfu/chimera","forks_url":"https://api.github.com/repos/dianfu/chimera/forks","keys_url":"https://api.github.com/repos/dianfu/chimera/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dianfu/chimera/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dianfu/chimera/teams","hooks_url":"https://api.github.com/repos/dianfu/chimera/hooks","issue_events_url":"https://api.github.com/repos/dianfu/chimera/issues/events{/number}","events_url":"https://api.github.com/repos/dianfu/chimera/events","assignees_url":"https://api.github.com/repos/dianfu/chimera/assignees{/user}","branches_url":"https://api.github.com/repos/dianfu/chimera/branches{/branch}","tags_url":"https://api.github.com/repos/dianfu/chimera/tags","blobs_url":"https://api.github.com/repos/dianfu/chimera/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dianfu/chimera/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dianfu/chimera/git/refs{/sha}","trees_url":"https://api.github.com/repos/dianfu/chimera/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dianfu/chimera/statuses/{sha}","languages_url":"https://api.github.com/repos/dianfu/chimera/languages","stargazers_url":"https://api.github.com/repos/dianfu/chimera/stargazers","contributors_url":"https://api.github.com/repos/dianfu/chimera/contributors","subscribers_url":"https://api.github.com/repos/dianfu/chimera/subscribers","subscription_url":"https://api.github.com/repos/dianfu/chimera/subscription","commits_url":"https://api.github.com/repos/dianfu/chimera/commits{/sha}","git_commits_url":"https://api.github.com/repos/dianfu/chimera/git/commits{/sha}","comments_url":"https://api.github.com/repos/dianfu/chimera/comments{/number}","issue_comment_url":"https://api.github.com/repos/dianfu/chimera/issues/comments{/number}","contents_url":"https://api.github.com/repos/dianfu/chimera/contents/{+path}","compare_url":"https://api.github.com/repos/dianfu/chimera/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dianfu/chimera/merges","archive_url":"https://api.github.com/repos/dianfu/chimera/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dianfu/chimera/downloads","issues_url":"https://api.github.com/repos/dianfu/chimera/issues{/number}","pulls_url":"https://api.github.com/repos/dianfu/chimera/pulls{/number}","milestones_url":"https://api.github.com/repos/dianfu/chimera/milestones{/number}","notifications_url":"https://api.github.com/repos/dianfu/chimera/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dianfu/chimera/labels{/name}","releases_url":"https://api.github.com/repos/dianfu/chimera/releases{/id}","created_at":"2016-01-12T05:06:38Z","updated_at":"2016-01-12T05:06:39Z","pushed_at":"2016-01-14T03:09:48Z","git_url":"git://github.com/dianfu/chimera.git","ssh_url":"git@github.com:dianfu/chimera.git","clone_url":"https://github.com/dianfu/chimera.git","svn_url":"https://github.com/dianfu/chimera","homepage":null,"size":247,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"intel-hadoop:master","ref":"master","sha":"e168f4f776fd27490894456e98e8532914296166","user":{"login":"intel-hadoop","id":1839373,"avatar_url":"https://avatars.githubusercontent.com/u/1839373?v=3","gravatar_id":"","url":"https://api.github.com/users/intel-hadoop","html_url":"https://github.com/intel-hadoop","followers_url":"https://api.github.com/users/intel-hadoop/followers","following_url":"https://api.github.com/users/intel-hadoop/following{/other_user}","gists_url":"https://api.github.com/users/intel-hadoop/gists{/gist_id}","starred_url":"https://api.github.com/users/intel-hadoop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/intel-hadoop/subscriptions","organizations_url":"https://api.github.com/users/intel-hadoop/orgs","repos_url":"https://api.github.com/users/intel-hadoop/repos","events_url":"https://api.github.com/users/intel-hadoop/events{/privacy}","received_events_url":"https://api.github.com/users/intel-hadoop/received_events","type":"Organization","site_admin":false},"repo":{"id":32968915,"name":"chimera","full_name":"intel-hadoop/chimera","owner":{"login":"intel-hadoop","id":1839373,"avatar_url":"https://avatars.githubusercontent.com/u/1839373?v=3","gravatar_id":"","url":"https://api.github.com/users/intel-hadoop","html_url":"https://github.com/intel-hadoop","followers_url":"https://api.github.com/users/intel-hadoop/followers","following_url":"https://api.github.com/users/intel-hadoop/following{/other_user}","gists_url":"https://api.github.com/users/intel-hadoop/gists{/gist_id}","starred_url":"https://api.github.com/users/intel-hadoop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/intel-hadoop/subscriptions","organizations_url":"https://api.github.com/users/intel-hadoop/orgs","repos_url":"https://api.github.com/users/intel-hadoop/repos","events_url":"https://api.github.com/users/intel-hadoop/events{/privacy}","received_events_url":"https://api.github.com/users/intel-hadoop/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/intel-hadoop/chimera","description":"Cryptographic library optimized with AES-NI","fork":false,"url":"https://api.github.com/repos/intel-hadoop/chimera","forks_url":"https://api.github.com/repos/intel-hadoop/chimera/forks","keys_url":"https://api.github.com/repos/intel-hadoop/chimera/keys{/key_id}","collaborators_url":"https://api.github.com/repos/intel-hadoop/chimera/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/intel-hadoop/chimera/teams","hooks_url":"https://api.github.com/repos/intel-hadoop/chimera/hooks","issue_events_url":"https://api.github.com/repos/intel-hadoop/chimera/issues/events{/number}","events_url":"https://api.github.com/repos/intel-hadoop/chimera/events","assignees_url":"https://api.github.com/repos/intel-hadoop/chimera/assignees{/user}","branches_url":"https://api.github.com/repos/intel-hadoop/chimera/branches{/branch}","tags_url":"https://api.github.com/repos/intel-hadoop/chimera/tags","blobs_url":"https://api.github.com/repos/intel-hadoop/chimera/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/intel-hadoop/chimera/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/intel-hadoop/chimera/git/refs{/sha}","trees_url":"https://api.github.com/repos/intel-hadoop/chimera/git/trees{/sha}","statuses_url":"https://api.github.com/repos/intel-hadoop/chimera/statuses/{sha}","languages_url":"https://api.github.com/repos/intel-hadoop/chimera/languages","stargazers_url":"https://api.github.com/repos/intel-hadoop/chimera/stargazers","contributors_url":"https://api.github.com/repos/intel-hadoop/chimera/contributors","subscribers_url":"https://api.github.com/repos/intel-hadoop/chimera/subscribers","subscription_url":"https://api.github.com/repos/intel-hadoop/chimera/subscription","commits_url":"https://api.github.com/repos/intel-hadoop/chimera/commits{/sha}","git_commits_url":"https://api.github.com/repos/intel-hadoop/chimera/git/commits{/sha}","comments_url":"https://api.github.com/repos/intel-hadoop/chimera/comments{/number}","issue_comment_url":"https://api.github.com/repos/intel-hadoop/chimera/issues/comments{/number}","contents_url":"https://api.github.com/repos/intel-hadoop/chimera/contents/{+path}","compare_url":"https://api.github.com/repos/intel-hadoop/chimera/compare/{base}...{head}","merges_url":"https://api.github.com/repos/intel-hadoop/chimera/merges","archive_url":"https://api.github.com/repos/intel-hadoop/chimera/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/intel-hadoop/chimera/downloads","issues_url":"https://api.github.com/repos/intel-hadoop/chimera/issues{/number}","pulls_url":"https://api.github.com/repos/intel-hadoop/chimera/pulls{/number}","milestones_url":"https://api.github.com/repos/intel-hadoop/chimera/milestones{/number}","notifications_url":"https://api.github.com/repos/intel-hadoop/chimera/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/intel-hadoop/chimera/labels{/name}","releases_url":"https://api.github.com/repos/intel-hadoop/chimera/releases{/id}","created_at":"2015-03-27T05:12:24Z","updated_at":"2016-01-12T01:14:12Z","pushed_at":"2016-01-14T03:17:58Z","git_url":"git://github.com/intel-hadoop/chimera.git","ssh_url":"git@github.com:intel-hadoop/chimera.git","clone_url":"https://github.com/intel-hadoop/chimera.git","svn_url":"https://github.com/intel-hadoop/chimera","homepage":null,"size":246,"stargazers_count":7,"watchers_count":7,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":6,"mirror_url":null,"open_issues_count":7,"forks":6,"open_issues":7,"watchers":7,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/intel-hadoop/chimera/pulls/40"},"html":{"href":"https://github.com/intel-hadoop/chimera/pull/40"},"issue":{"href":"https://api.github.com/repos/intel-hadoop/chimera/issues/40"},"comments":{"href":"https://api.github.com/repos/intel-hadoop/chimera/issues/40/comments"},"review_comments":{"href":"https://api.github.com/repos/intel-hadoop/chimera/pulls/40/comments"},"review_comment":{"href":"https://api.github.com/repos/intel-hadoop/chimera/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/intel-hadoop/chimera/pulls/40/commits"},"statuses":{"href":"https://api.github.com/repos/intel-hadoop/chimera/statuses/f9c261b4914806a6286a38f4e540d696c424c6d5"}}}}