SCEA_Messaging

SCEA_Messaging

JMS provides a highly flexible and scalable solution for building loosely coupled applications in the enterprise environment.

 

Messages: A message is a unit of data that is sent from one process to another. The data in the message can range from simple text to a more complex data structure. The only restriction is that the object must be serializable.

 

Message-Oriented Middleware: MOM is middleware that is used for messaging.

 

Communication Modes: synchronous(ex: credit card authorization) / asynchronous(ex: e-mail)

Scenario

Solution

Need to implement a messaging system in which a response is not immediately required.

Asynchronous

Need  a high-volume transaction processing capability for sending messages.

Asynchronous

Want a messaging system that uses your system hardware in an efficient manner. 

Asynchronous

Use a credit card authorization/ user login authentication system to send a message in which the response to the message is required before the transaction can be completed.

Synchronous

 

Message Models: publish/subscribe(pub/sub), in which messages are published on a one or more-to-many basis. Point-to-point(PTP), in which messages are sent on a one-to-one basis.

Point-to-Point(PTP) model

 

A message is delivered to a destination, known as a queue. Messages in a queue are processed on a first-in, first-out(FIFO) basis.

                   

 

Publish/subscribe(pub/sub) model

 

JMS Interfaces

JMS Common Interfaces

Pub-sub Interfaces

PTP Interfaces

Destination

Topic

Queue

ConnectionFactory

TopicConnectionFactory

QueueConnectionFactory

Connection

TopicConnection

QueueConnection

Session

TopicSession

QueueSession

MessageProducer

TopicPublisher

QueueSender

MessageConsumer

TopicSubscriber

QueueReceiver, QueueBrowser

 

JMS component relationships

 

Questions:

1. Which of the following are characteristics of publish/subscribe message model?

A. Always use a URL to identify publishers.

B. Subject-based addressing.

C. Location-independent publishers.

D. Only synchronous communication between publishers and subscribers is possible.

B,C

 

2. Which of the following are valid methods for a TopicSubscriber?

A. receive()

B. receiveNoWait()

C. receiveWait()

D. receiveSync()

A,B

 

3. What are the types of messaging models supported in JMS?

A. Point-to-point

B. Send/receive

C. Transmit/receive

D. Publish/subscribe

A,D

 

4. What is a message digest?

A. A digital fingerprint value that is computed from a message, file, or byte stream

B. A shortened summary of a message

C. The subject line of a message

D. A processing function of the mail server

A

 

5.Which of the following scenarios are not suitable for publish/subscribe messaging model?

A. It is used to receive news stories.

B. It is used for receiving sales forecasts.

C. It is used for sending stock prices to traders on the trading floor.

D. It is used to authorize a user ID and password.

D

 

6.What deliver modes are available in JMS?

A. PERSISTENT

B. NON_PERSISTENT

C. PERMANENT

D. DURABLE

A,B

Note: When creating a MessageProducer, you can also specify the default delivery mode(setDeliveryMode). This can be either NON_PERSISTENT, which has a lower overhead because the message is not logged, or PERSISTENT, which requires the message to be logged, typically to a database.

 

7. Which of the following are valid message acknowledgment types?

A. AUTO_ACKNOWLEDGE

B. CLIENT_ACKNOWLEDGE

C. DUPS_OK_ACKNOWLEDGE

D. NO_ACKNOWLEDGE

A,B,C

 

8. Which of the following are not valid message body formats?

A. MapMessage

B. ObjectMessage

C. TextMessage

D. StringMessage

D

Message Body Format: ByteMessage, MapMessage, ObjectMessage, StreamMessage, TextMessage

 

9. Which of the following are not valid JMS objects?

A. MessageProducer

B. MessageConsumer

C. MessageViewer

D. MessageSelector

C

 

10. Which of the following would not be used in a client application performing point-to-point messaging?

A. Topic

B. InitialContext

C. Queue

D. Session

A

 

11. Which of the following are advantages of asynchronous messaging architectures?

A. Better use of bandwidth

B. Supports load balancing

C. Provides sender with instant response

D. Scalability

A,B,D

 

12. Which of the following statements are true for asynchronous messaging?

A. It decouples senders and receivers.

B. It can increase performance.

C. It is better suited to smaller message sizes.

D. It only works with blocking calls.

A,B,C

 

13. Which method must be called to receive messages asynchronously?

A. The receive method

B. The processMessage method

C. The readMessage method

D. The onMessage method

D

 

14. Which of the following are not features of asynchronous messaging?

A. As the volume of traffic increases, it is better able to handle the spike in demand.

B. A message must be acknowledged before the producer can send another.

C. It is less affected by failures at the hardware, software, and network levels.

D. When capacities are exceeded, information is not lost; instead, it is delayed.

B

 

15.Which method must be called to receive messages synchronously?

A. The receive method

B. The processMessage method

C. The readMessage method

D. The onMessage method

A

 

16. Which of the following cases are better suited to synchronous messaging?

A. Electronic mail

B. Credit card authorization

C. Electronic processing of tax returns

D. Validation of data entered

B,D

 

17.Which of the following are features of synchronous messaging?

A. Both parties must be active to participate.

B. Messages must be acknowledged before proceeding.

C. It decouples senders and receivers.

D. It does not work with blocking calls.

A,B

 

18. Which of the following are not features of synchronous messaging?

A. Both parties must be active to participate.

B. It is unaffected by increases in traffic volume.

C. Message must be acknowledged before proceeding to the next.

D. Message is queued until it is ready for processing.

B,D

 

19. Which of the following scenarios are not suitable for publish/subscribe messaging model?

A. Sending an instant message

B. Sending an order to another system

C. Sending news stories to interested parties

D. Sending a transaction to another system

A,B,D

 

20. What method must be implemented to receive messages in a message-driven bean (MDB)?

A. The receive method

B. The onMessage method

C. The readMessage method

D. The processMessage method

B

 

内容概要:本文详细介绍了如何利用Simulink进行自动代码生成,在STM32平台上实现带57次谐波抑制功能的霍尔场定向控制(FOC)。首先,文章讲解了所需的软件环境准备,包括MATLAB/Simulink及其硬件支持包的安装。接着,阐述了构建永磁同步电机(PMSM)霍尔FOC控制模型的具体步骤,涵盖电机模型、坐标变换模块(如Clark和Park变换)、PI调节器、SVPWM模块以及用于抑制特定谐波的陷波器的设计。随后,描述了硬件目标配置、代码生成过程中的注意事项,以及生成后的C代码结构。此外,还讨论了霍尔传感器的位置估算、谐波补偿器的实现细节、ADC配置技巧、PWM死区时间和换相逻辑的优化。最后,分享了一些实用的工程集成经验,并推荐了几篇有助于深入了解相关技术和优化控制效果的研究论文。 适合人群:从事电机控制系统开发的技术人员,尤其是那些希望掌握基于Simulink的自动代码生成技术,以提高开发效率和控制精度的专业人士。 使用场景及目标:适用于需要精确控制永磁同步电机的应用场合,特别是在面对高次谐波干扰导致的电流波形失真问题时。通过采用文中提供的解决方案,可以显著改善系统的稳定性和性能,降低噪声水平,提升用户体验。 其他说明:文中不仅提供了详细的理论解释和技术指导,还包括了许多实践经验教训,如霍尔传感器处理、谐波抑制策略的选择、代码生成配置等方面的实际案例。这对于初学者来说是非常宝贵的参考资料。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值