- Initialize the library with :c:macro:`MSG_init`
- Create a platform (usually by parsing a file with :cpp:func:`MSG_create_environment`)
- Register the functions that your processes are supposed to run with
- :cpp:func:`MSG_function_register` (and maybe :cpp:func:`MSG_function_register_default`)
+ :cpp:func:`MSG_function_register` (and maybe :cpp:func:`MSG_function_register_default`)
- Launch your processes from a deployment file with :cpp:func:`MSG_launch_application`
- Run the simulation with :cpp:func:`MSG_main`
.. doxygenfunction:: MSG_task_set_name
.. doxygenfunction:: MSG_task_set_priority
-
+
Mailbox Management
==================
Semaphores
----------
-
+
.. doxygentypedef:: msg_sem_t
.. doxygenfunction:: MSG_sem_acquire
.. doxygenfunction:: MSG_sem_acquire_timeout
Java bindings
*************
-This section describes jMSG, the Java API to Simgrid. This API mimics
+This section describes jMSG, the Java API to Simgrid. This API mimics
:ref:`MSG <MSG_doc>`, which is a simple yet somehow realistic interface.
The full reference documentation is provided at the end of this page.
.. code-block:: console
$ cd examples/deprecated/java
- $ java -classpath ../../simgrid.jar:. .:../../simgrid.jar app.pingpong.Main ../platforms/platform.xml
+ $ java -classpath ../../simgrid.jar:. .:../../simgrid.jar app.pingpong.Main ../platforms/platform.xml
Any SimGrid simulation (java or not) is usually constituted of several
kind of actors or processes (classes extending @c Msg.Process) that
you should read carefully MSG samples and/or documentation.
- Something has crashed in the C part. Okay, here comes the tricky
thing. It happens mainly for 2 reasons:
-
+
- When something goes wrong in your simulation, sometimes the C part stops
because you used SimGrid incorrectly, and JNI bindings are not fond of that.
It means that you'll have something that looks ugly, but you should be able
Class org.simgrid.msg.As <java/org/simgrid/msg/As>
Class org.simgrid.msg.Comm <java/org/simgrid/msg/Comm>
+ Class org.simgrid.msg.File <java/org/simgrid/msg/File>
Class org.simgrid.msg.Host <java/org/simgrid/msg/Host>
Class org.simgrid.msg.HostFailureException <java/org/simgrid/msg/HostFailureException>
Class org.simgrid.msg.HostNotFoundException <java/org/simgrid/msg/HostNotFoundException>
Class org.simgrid.msg.ProcessKilledError <java/org/simgrid/msg/ProcessKilledError>
Class org.simgrid.msg.ProcessNotFoundException <java/org/simgrid/msg/ProcessNotFoundException>
Class org.simgrid.msg.Semaphore <java/org/simgrid/msg/Semaphore>
+ Class org.simgrid.msg.Storage <java/org/simgrid/msg/Storage>
+ Class org.simgrid.msg.StorageNotFoundException <java/org/simgrid/msg/StorageNotFoundException>
Class org.simgrid.msg.Task <java/org/simgrid/msg/Task>
Class org.simgrid.msg.TaskCancelledException <java/org/simgrid/msg/TaskCancelledException>
Class org.simgrid.msg.TimeoutException <java/org/simgrid/msg/TimeoutException>