Questions tagged [message-passing]

Message passing is a data transfer mechanism that is used in various forms in a number of programming languages

The basic form of data transfer in programming languages is the assignment statement. It is carried out by a (computing) agent that moves data from one part of the memory to another. The substantial difference between assignment and message passing is that message passing incorporates two active agents, a sender and a receiver. The sender has exclusive control over the source locations of the data to be transferred, while the receiver has exclusive control over the destination of the data.

Message passing can be classified by a number of criteria, the most important of which is

  • Mode of operation:

    • Synchronous (also called rendezvous or handshaking): Sender and receiver perform their transfer operations simultaneously. They may have to wait before transfer becomes possible.
    • Asynchronous: Sender is allowed to transfer data to a temporary location where it can be accessed by the receiver. Sender does not have to wait if temporary storage is available.
  • Addressing:

    • Direct: Sender and receiver refer to each other directly, by using unique IDs.
    • Indirect: There is an auxiliary object (channel) that connects the sender and the receiver, who only refer to the channel during message passing.
409 questions
0
votes
1 answer

IPC using msgsnd and msgrcv

For learning, I wrote 2 IPC programs, a server and a client that use message sending. For some reason, the server does not seem to be receiving the data it has been send. Could you give me some hints on how I could go about debugging such a…
user277465
0
votes
2 answers

Using intent's putExtra to send data using same Key Value

i want to open an Activity using Intents By following this code: Intent i=new Intent("com.example.learn.CONNECTION"); @Override protected void onCreate(Bundle savedInstanceState) { . . . server=(Button)…
0
votes
3 answers

Can I make a regex match all characters up to ; except \;?

I am going to construct a message-passing system whose messages have the following structure: message type;message content (matches message type;) However, the user can set the message type, and (for the sake of loosely coupled systems) I want to…
Ky -
  • 30,724
  • 51
  • 192
  • 308
0
votes
0 answers

Chrome Extension: Message Passing

I stuck on message passing in my Google Chrome extension. I have this popup.js: chrome.runtime.onMessage.addListener( function(request, sender, sendResponse) { if (request.do == 'popup_refreshMessage') …
nanuqcz
  • 1,376
  • 3
  • 16
  • 19
0
votes
1 answer

Deserializing a Message multiple times with Google Protocol Buffers

I am working with a system that is extremely modular. Messages can be determined by the by the 3-tuple of src, dest, type. I'm looking into reimplementing our messages with Protocol Buffers. I've read through Protocol buffer polymorphism, what's…
Lestat
  • 49
  • 1
  • 7
0
votes
1 answer

Rendezvous in inter process communication?

I have two processes communicating through a send() and a receive(). If both are blocking, I know this is what is known as extended rendezvous, if the sender is non-blocking then it's called limited rendezvous. But what happens when both send() and…
user1417683
  • 239
  • 3
  • 10
0
votes
1 answer

Message-passing to background.html from popup.js and content-scripts

I'm trying to get the popup/popopen menu to show the user different content based off the current page-URL but can't get a connection. I've read that only background.html has access to current-tabs' URLs in the Chrome framework, so I'm trying to…
0
votes
2 answers

Java Object Oriented function calling between classes

I ma new in OOD and working on Academic project. I am facing a problem while programming it. The scenario is that I have a main class in which I have made an object of "login" class and call its function. Now in that "login" class function I create…
user1656168
0
votes
2 answers

Erlang console hangs with this codesnippet

This is probably easy for someone with experience in Erlang but I have none. Im trying to make a fibonacci tree of processes. It shall then accept a message where i can calculate the sum of all nodes under the one im passing it to. create_fibtree(N)…
nilsi
  • 10,351
  • 10
  • 67
  • 79
0
votes
1 answer

implicitly logging messages received by an actor in scala

I am new to this fancy language scala and I am trying to create a library for logging scala actors. My library has a class Logger which extends the Actor class. So any Scala application which uses actor model can extend from this class instead or…
Deepti Jain
  • 1,901
  • 4
  • 21
  • 29
0
votes
2 answers

Passing messages to children of contained container view controllers from a custom container view controller?

My apologies for the long title, but it really is the shortest accurate and descriptive version I could come up with. I'm implementing a custom container view controller with a custom segue type, working with iOS 5 and storyboards. I also provide a…
JK Laiho
  • 3,538
  • 6
  • 35
  • 42
0
votes
1 answer

Why can't I open get 8 processes at a time?

I'm a beginner to MPI. When I coded my first program, I came into a tough problem to me. MPI_Init(&argc, &argv) ; MPI_Comm_rank( MPI_COMM_WORLD, &rank) ; MPI_Comm_size( MPI_COMM_WORLD, &size) ; printf("Process: %d\n", rank); printf("Procs_num:…
Peiyun
  • 149
  • 1
  • 7
0
votes
1 answer

Distributed nature task and Akka

This is a simplified version of my problem: On the server we have n*m - matrix of type int[][], we split this matrix into the set of n row-vectors and put them in a queue. When the queue is ready (full of vectors), we loop over and send each…
Sophie Sperner
  • 4,428
  • 8
  • 35
  • 55
0
votes
2 answers

Message passing scheme

Can anyone briefly explain to me how message passing is implemented in scheme? I think I am little off on the whole concept of message passing.
Adeq Hero
  • 137
  • 1
  • 3
  • 11
0
votes
1 answer

Passing Exception Information from Global.asax to ErrorPage.aspx

I have a global error handler in Global.asax and am trying to display the exception information in a page called ErrorPage.aspx. I've read Microsoft's page about passing information between asp.net pages…
Emily
  • 444
  • 1
  • 3
  • 12