Talking to C++ process through N-API
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 20/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Necesita aclaración
- Estado de actividad
- Estancado
- Stack tecnológico
- node.js
Línea de trabajo
The issue names no repository files or tests. Start by reviewing the N-API entry point and the C++ DLL, shared-memory file mapping, and separate-process communication described in the issue. Done would require a clearly scoped example or documented support path for the requested Node.js-to-C++ process communication.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Hello;
I want to send and receive data from a game simulation in a seperate C++ process, from Node.js. I want Node.js to connect to the outside internet and Node.js will need to communicate with a game simulation run in a seperate process.
Memory sharing seems to be the fastest way to do interprocess communication. Its faster than pipes or sockets, so I want to use memory sharing to do the IPC. I was thinking that N-API could be used to do this.
The question is can I use N-API to connect to a C++ DLL and create a shared memory object (file map). The DLL will be loaded into the Node.js process and it will load a DLL that has already been loaded by the C++ executable. The the file mapping of the system pagefile will be loaded into both the Node.js process and the seperate C++ process. To send something from Node.js to the C++ process, I would just call and required funtions., which would call a function in the DLL that wrote to the share memory map file. After the shared memory has been written to the, it would unblock a handle that the server has access to. The C++ process could then read the shared memory. Has anyone tried this? I mean N-API allows on to call C++ ftns in a DLL, but to call ftns in a seperate process is what I want.
- Lenguaje dominante
- C++
- Estrellas
- 2.6k
- Forks
- 598
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de nodejs/node-addon-examples
-
Create Valgrind run of testsAbiertoenhancement
Dificultad 4/5 3-5 días Aptitud para principiantes 38/100
nodejs/node-addon-examples#585 · 1 reacción ·
-
Add .d.ts files in samples.Abierto
Dificultad 3/5 1-2 días Aptitud para principiantes 38/100
nodejs/node-addon-examples#530 · 1 comentario ·
-
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
nodejs/node-addon-examples#445 ·
-
Dificultad 3/5 1-2 días Aptitud para principiantes 32/100
nodejs/node-addon-examples#444 · 1 comentario ·
-
Dificultad 3/5 1-2 días Aptitud para principiantes 35/100
nodejs/node-addon-examples#381 ·
Todos los issues de nodejs/node-addon-examples
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
eclipse-score/lifecycle#929 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
colbymchenry/codegraph#3223 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
firefox-devtools/profiler#6436 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
The `ufw` decoder requires the kernel's monotonic timestamp, so UFW lines read from journald decode without any fieldPosiblemente ocupada Un pull request vinculado a esta issue está abierto o ya se fusionó. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 1 día