Examples
13 working examples demonstrating PythonEmbed features. Each example is a standalone subproject you can run directly.
Running Examples
Or run all examples at once (CI):
Example List
| Example | What It Demonstrates |
|---|---|
| Basic Eval | eval(), exec(), PythonValue, arg() |
| Batch Operations | batchEval(), batchExec() — single + pool |
| Callback Bridge | Python→Java callbacks via _bridge.call() |
| Configuration | PythonEmbed.Options builder, env vars, warmup |
| Error Handling | PythonExecutionException, traceback, cause codes |
| Health Monitor | ping(), health(), pool monitoring |
| Maven Example | Maven plugin setup, basic eval, numpy |
| Numpy Basic | NumPy arrays, operations, broadcasting |
| Object Handle | ref(), handle lifecycle, cross-call references |
| Pandas Dataframe | DataFrame creation, compute, pass to Java |
| Pool Async | PythonEmbedPool, async eval, concurrent execution |
| Proxy Object | proxy() — wrap Python objects as Java interfaces |
| Spring Boot Example | Spring Boot auto-configuration, REST endpoint |
| Streaming | Generator streaming via stream(), large datasets |