# Change the size of the JVM heap

Here’s how to change the size of the heap in your DataSource application’s Java Virtual Machine (JVM) from the default settings. You might need to do this for performance reasons.

Change the heap size using the [jvm-options](datasource-java-jvm-configuration.md#jvm-options) configuration item:

```
jvm-options    -Xms$<min-heap-size>m -Xmx$<max-heap-size>m
```

`-Xms<min-heap-size>m` specifies the initial size of the heap, in megabytes.

`-Xmx<max-heap-size>m` specifies the maximum size of the heap, in megabytes

**💡 TIP**\
We recommend that you set the `<min-heap-size>` and `<max-heap-size>` to the same value.

For more about the `Java -Xms` and `-Xmx` command line options, see the [Java documentation about the java command](https://docs.oracle.com/javase/7/docs/technotes/tools/windows/java.html).

**Where do I put the configuration?**

| What I’m developing/customising: | configuration GOES IN : |
| --- | --- |
| Adapter: Developing an existing Java-based Adapter blade. | Blade’s _DataSource/etc/java.conf_ |
| Adapter: Customising an existing Java-based Adapter blade. | Deployment Framework’s _global_config/overrides/&lt;blade-name>/DataSource/java.conf_ |
| Liberator: [Developing a Java-based Liberator Permissioning Service blade](../deployment-framework/cdf-create-a-java-based-liberator-permissioning-service-blade.md). | Blade’s _Liberator/etc/java.conf_ |
| Liberator: Customising a Java-based Liberator Permissioning Service blade. | Deployment Framework’s _global_config/overrides/&lt;blade-name>/Liberator/etc/java.conf_ |
| Liberator: Applying heap configuration to all Java modules in Liberator (including JMX), except when specifically overridden by particular blades. | Deployment Framework’s _global_config/overrides/servers/Liberator/etc/java.conf_ |
| Transformer: [Developing a Java-based Transformer Service blade](../deployment-framework/cdf-create-a-java-based-transformer-service-blade.md). | Blade’s _Transformer/etc/java.conf_ |
| Transformer: Customising an existing Java-based Transformer Service blade. | Deployment Framework’s _global_config/overrides/&lt;blade-name>/Transformer/etc/java.conf_ |
| Transformer: Applying heap configuration to all Java modules in Transformer (including JMX), except when specifically overridden by particular blades. | Deployment Framework’s _global_config/overrides/servers/Transformer/etc/java.conf_ |

---

**See also:**

* [Configure a DataSource application’s JVM](datasource-configure-a-datasource-applications-jvm.md)
