Index: oak-core/src/test/java/org/apache/jackrabbit/oak/plugins/nodetype/write/NodeTypeRegistryTest.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- oak-core/src/test/java/org/apache/jackrabbit/oak/plugins/nodetype/write/NodeTypeRegistryTest.java	(revision 1752245)
+++ oak-core/src/test/java/org/apache/jackrabbit/oak/plugins/nodetype/write/NodeTypeRegistryTest.java	(revision )
@@ -16,25 +16,14 @@
  */
 package org.apache.jackrabbit.oak.plugins.nodetype.write;
 
-import static com.google.common.base.Preconditions.checkArgument;
-import static com.google.common.base.Preconditions.checkNotNull;
-import static com.google.common.collect.ImmutableList.of;
-import static org.apache.jackrabbit.JcrConstants.JCR_MIXINTYPES;
-import static org.apache.jackrabbit.JcrConstants.JCR_PRIMARYTYPE;
-import static org.apache.jackrabbit.JcrConstants.NT_FOLDER;
-import static org.apache.jackrabbit.JcrConstants.NT_UNSTRUCTURED;
-import static org.apache.jackrabbit.oak.api.Type.NAME;
-import static org.apache.jackrabbit.oak.plugins.nodetype.NodeTypeConstants.MIX_INDEXABLE;
-
 import java.io.Closeable;
 import java.io.IOException;
 import java.io.InputStream;
-
 import javax.annotation.Nonnull;
 import javax.jcr.NoSuchWorkspaceException;
 import javax.security.auth.login.LoginException;
 
-import org.apache.jackrabbit.JcrConstants;
+import com.google.common.base.Strings;
 import org.apache.jackrabbit.oak.Oak;
 import org.apache.jackrabbit.oak.api.CommitFailedException;
 import org.apache.jackrabbit.oak.api.ContentRepository;
@@ -42,15 +31,33 @@
 import org.apache.jackrabbit.oak.api.Root;
 import org.apache.jackrabbit.oak.api.Tree;
 import org.apache.jackrabbit.oak.api.Type;
-import org.apache.jackrabbit.oak.plugins.nodetype.NodeTypeConstants;
 import org.apache.jackrabbit.oak.plugins.nodetype.TypeEditorProvider;
 import org.apache.jackrabbit.oak.spi.security.OpenSecurityProvider;
+import org.apache.jackrabbit.oak.util.TreeUtil;
 import org.junit.After;
 import org.junit.Before;
 import org.junit.Test;
 
-import com.google.common.base.Strings;
-import com.google.common.collect.ImmutableList;
+import static com.google.common.base.Preconditions.checkArgument;
+import static com.google.common.base.Preconditions.checkNotNull;
+import static com.google.common.collect.ImmutableList.of;
+import static org.apache.jackrabbit.JcrConstants.JCR_CONTENT;
+import static org.apache.jackrabbit.JcrConstants.JCR_DATA;
+import static org.apache.jackrabbit.JcrConstants.JCR_LASTMODIFIED;
+import static org.apache.jackrabbit.JcrConstants.JCR_MIXINTYPES;
+import static org.apache.jackrabbit.JcrConstants.JCR_PRIMARYTYPE;
+import static org.apache.jackrabbit.JcrConstants.JCR_UUID;
+import static org.apache.jackrabbit.JcrConstants.NT_FILE;
+import static org.apache.jackrabbit.JcrConstants.NT_FOLDER;
+import static org.apache.jackrabbit.JcrConstants.NT_RESOURCE;
+import static org.apache.jackrabbit.JcrConstants.NT_UNSTRUCTURED;
+import static org.apache.jackrabbit.oak.api.Type.NAME;
+import static org.apache.jackrabbit.oak.plugins.nodetype.NodeTypeConstants.JCR_LASTMODIFIEDBY;
+import static org.apache.jackrabbit.oak.plugins.nodetype.NodeTypeConstants.MIX_INDEXABLE;
+import static org.apache.jackrabbit.oak.plugins.nodetype.NodeTypeConstants.NODE_TYPES_PATH;
+import static org.apache.jackrabbit.oak.plugins.nodetype.NodeTypeConstants.NT_OAK_RESOURCE;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
 
 public class NodeTypeRegistryTest {
     private ContentRepository repository = null;
@@ -112,5 +119,34 @@
         test.setProperty(JCR_MIXINTYPES, of(MIX_INDEXABLE), Type.NAMES);
         test.addChild("oak:index").setProperty(JCR_PRIMARYTYPE, NT_UNSTRUCTURED, NAME);
         root.commit();
+    }
+
+    @Test
+    public void oakResource() throws Exception{
+        registerNodeType(root, "builtin_nodetypes.cnd");
+        Tree typeRoot = root.getTree(NODE_TYPES_PATH);
+        Tree test1 = TreeUtil.addChild(root.getTree("/"), "test1", NT_FILE, typeRoot, "admin");
+        Tree content1 = TreeUtil.addChild(test1, JCR_CONTENT, NT_OAK_RESOURCE, typeRoot, "admin");
+        content1.setProperty(JCR_DATA, "hello".getBytes());
+
+        Tree test2 = TreeUtil.addChild(root.getTree("/"), "test2", NT_FILE, typeRoot, "admin");
+        Tree content2 = TreeUtil.addChild(test2, JCR_CONTENT, NT_RESOURCE, typeRoot, "admin");
+        content2.setProperty(JCR_DATA, "hello".getBytes());
+        root.commit();
+
+        test1 = root.getTree("/").addChild("test1");
+
+        assertTrue(test1.getChild(JCR_CONTENT).hasProperty(JCR_LASTMODIFIEDBY));
+        assertTrue(test1.getChild(JCR_CONTENT).hasProperty(JCR_LASTMODIFIED));
+
+        //For oak:Resource the uuid property should not get generated
+        assertFalse(test1.getChild(JCR_CONTENT).hasProperty(JCR_UUID));
+
+        test2 = root.getTree("/").addChild("test2");
+
+        assertTrue(test2.getChild(JCR_CONTENT).hasProperty(JCR_LASTMODIFIEDBY));
+        assertTrue(test2.getChild(JCR_CONTENT).hasProperty(JCR_LASTMODIFIED));
+        assertTrue(test2.getChild(JCR_CONTENT).hasProperty(JCR_UUID));
+
     }
 }
Index: oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/nodetype/NodeTypeConstants.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/nodetype/NodeTypeConstants.java	(revision 1752245)
+++ oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/nodetype/NodeTypeConstants.java	(revision )
@@ -46,6 +46,10 @@
      * @since oak 1.0
      */
     String NT_OAK_UNSTRUCTURED = "oak:Unstructured";
+    /**
+     * @since oak 1.5.7
+     */
+    String NT_OAK_RESOURCE = "oak:Resource";
 
     String NT_REP_NODE_TYPE = "rep:NodeType";
     String NT_REP_NAMED_PROPERTY_DEFINITIONS = "rep:NamedPropertyDefinitions";
Index: oak-doc/src/site/markdown/dos_and_donts.md
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- oak-doc/src/site/markdown/dos_and_donts.md	(revision 1752245)
+++ oak-doc/src/site/markdown/dos_and_donts.md	(revision )
@@ -78,6 +78,16 @@
 8k for any inlined binary value. Further this would also lead to repository growth as
 by default when binaries are stored in BlobStore then they are deduplicated.
 
+### Creating files
+
+The default node type provided by JCR 1.0 to model file structure using
+`nt:file` is to add `jcr:content` child with type `nt:resource`, which makes
+that content referenceable.
+
+If the file has no need to be referenceable it is recommended to use the
+node type `oak:Resource` instead and add the mixin type `mix:referenceble`
+only upon demand (see [OAK-4567](https://issues.apache.org/jira/browse/OAK-4567))
+
 ### Don't use Thread.interrupt()
 
 `Thread.interrupt()` can severely impact or even stop the repository. The reason for 
Index: oak-core/src/main/resources/org/apache/jackrabbit/oak/plugins/nodetype/write/builtin_nodetypes.cnd
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- oak-core/src/main/resources/org/apache/jackrabbit/oak/plugins/nodetype/write/builtin_nodetypes.cnd	(revision 1752245)
+++ oak-core/src/main/resources/org/apache/jackrabbit/oak/plugins/nodetype/write/builtin_nodetypes.cnd	(revision )
@@ -53,7 +53,7 @@
  * jcr:content. The jcr:content node is used to hold the actual content of the
  * file. This child node is mandatory, but not auto-created. Its node type will be
  * application-dependent and therefore it must be added by the user. A common
- * approach is to make the jcr:content a node of type nt:resource. The
+ * approach is to make the jcr:content a node of type nt:resource or oak:Resource. The
  * jcr:content child node is also designated as the primary child item of its parent.
  *
  * @since 1.0
@@ -94,6 +94,16 @@
  * @since 1.0
  */
 [nt:resource] > mix:mimeType, mix:lastModified, mix:referenceable
+  primaryitem jcr:data
+  - jcr:data (BINARY) mandatory
+
+/**
+ * This node type may be used to represent the content of a file. This should be
+ * preferred over nt:resource if non referenceable nt:file nodes are required
+ *
+ * @since 1.5.6
+ */
+[oak:Resource] > mix:mimeType, mix:lastModified
   primaryitem jcr:data
   - jcr:data (BINARY) mandatory
 
