title: Is it possible to start the OrientDb server without using reflection?
body: <p>I'm running OrientDb 2.2.6 in embedded mode. I have to grant security permissions to my code so the SecurityManager allows it to run. One permission I would particularly prefer not to grant is ("java.lang.reflect.ReflectPermission" "suppressAccessChecks"). Instead of granting permissions, I would rather start the server without requiring reflection. Is there a way to start the OrientDb server in embedded mode without reflection?</p>
  
  <p>Here is my configuration:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8" standalone="yes"?&gt;
  &lt;orient-server&gt;
  &lt;network&gt;
      &lt;protocols&gt;
          &lt;protocol implementation="com.orientechnologies.orient.server.network.protocol.binary.ONetworkProtocolBinary" name="binary"/&gt;
      &lt;/protocols&gt;
      &lt;listeners&gt;
          &lt;listener protocol="binary" socket="default" port-range="2424-2430" ip-address="0.0.0.0"/&gt;
      &lt;/listeners&gt;
  &lt;/network&gt;
  &lt;users&gt;
      &lt;user resources="*" password="root" name="root"/&gt;
      &lt;user resources="connect,server.listDatabases,server.dblist" password="guest" name="guest"/&gt;
  &lt;/users&gt;
  &lt;properties&gt;
      &lt;entry value="1" name="db.pool.min"/&gt;
      &lt;entry value="50" name="db.pool.max"/&gt;
      &lt;entry value="true" name="profiler.enabled"/&gt;
  &lt;/properties&gt;
  &lt;/orient-server&gt;
  </code></pre>
  
  <p>The code I'm using was taken from OrientDb documentation. Its only three lines:</p>
  
  <pre><code>server = OServerMain.create();
  // orientServerConfigFile is a file object for the configuration given above
  server.startup(orientServerConfigFile.getInputStream());
  server.activate();
  </code></pre>
  
  <p>The relevant stack trace is below:</p>
  
  <pre><code>2016-09-12 15:41:55:557 FINE  Access denied
      Permission that failed: ("java.lang.reflect.ReflectPermission" "suppressAccessChecks")
      ProtectionDomain that failed: file:/*/modules/orientSystemDb-se.jar
      Stack trace causing the failure:
              java.lang.SecurityManager.checkPermission(SecurityManager.java:549)
              java.lang.reflect.AccessibleObject.setAccessible(AccessibleObject.java:128)
              com.orientechnologies.common.util.OMemory.getPhysicalMemorySize(OMemory.java:65)
              com.orientechnologies.orient.core.engine.OMemoryAndLocalPaginatedEnginesInitializer.configureDefaultDiskCacheSize(OMemoryAndLocalPaginatedEnginesInitiali
              com.orientechnologies.orient.core.engine.OMemoryAndLocalPaginatedEnginesInitializer.configureDefaults(OMemoryAndLocalPaginatedEnginesInitializer.java:63)
              com.orientechnologies.orient.core.engine.OMemoryAndLocalPaginatedEnginesInitializer.initialize(OMemoryAndLocalPaginatedEnginesInitializer.java:52)
              com.orientechnologies.orient.core.engine.local.OEngineLocalPaginated.startup(OEngineLocalPaginated.java:56)
              com.orientechnologies.orient.core.Orient.startEngine(Orient.java:872)
              com.orientechnologies.orient.core.Orient.loadStorage(Orient.java:480)
              com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.&lt;init&gt;(ODatabaseDocumentTx.java:167)
              com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.&lt;init&gt;(ODatabaseDocumentTx.java:148)
              com.orientechnologies.orient.server.OSystemDatabase.init(OSystemDatabase.java:151)
              com.orientechnologies.orient.server.OSystemDatabase.&lt;init&gt;(OSystemDatabase.java:44)
              com.orientechnologies.orient.server.OServer.initSystemDatabase(OServer.java:1227)
              com.orientechnologies.orient.server.OServer.activate(OServer.java:342)
  </code></pre>