Comments (5)
Hi @kensinzl, once you close
an instance of ServiceBusSenderClient
, you won't be able to use it further (i.e., you can't call send
on the closed instance). What I meant earlier was, you can have a Sender instance in application’s global scope, but it should be closed when the application gets shutdown.
from azure-sdk-for-java.
@anuchandy @Azure/azsdk-sb-java could you please follow up with @kensinzl on these questions?
from azure-sdk-for-java.
The ServiceBusSenderClient object is reusable, on which application can call send() API multiple times.
It is recommended to close the client as part of the application shutdown.
Storage Queue and service bus uses different protocols and has different use cases.
There is no id available when sending to service bus, but only while receiving.
from azure-sdk-for-java.
Hi @kensinzl. Thank you for opening this issue and giving us the opportunity to assist. We believe that this has been addressed. If you feel that further discussion is needed, please add a comment with the text "/unresolve" to remove the "issue-addressed" label and continue the conversation.
from azure-sdk-for-java.
Thank you so much for your explanation.
just double confirm
- I used the ServiceBusSenderClient instance as an injection
- create a simple function which uses the above ServiceBusSenderClient instance to send the message,
eg: sudo code
@Inject ServiceBusSenderClient instance;
public void sendMessageToAzure(String meg) {
instance.sendMessage(meg);
instance.close();
}
- so do you mean whenever hit the
sendMessageToAzure
I need to close the instance, but the ServiceBusSenderClient instance is reusable, I have no necessary to re-open it after close?
from azure-sdk-for-java.
Related Issues (20)
- [BUG] EventHubs processor: if max time is not set, but there are less events than batch size, they are never processed. HOT 1
- [BUG] EventHub's retry method always adds 4 seconds to a configured delay HOT 1
- Deprecated LATEST version is specified for a dependency of azure-servicebus-jms HOT 4
- [BUG] Postgresql passwordless-enabled: true still expects password HOT 5
- Revamp/Improve Javadocs for Communication Client libraries
- Revamp/Improve Javadocs for Cosmos Client libraries
- Revamp/Improve Javadocs for Storage libraries
- Revamp/Improve Javadocs for Attestation Libraries
- Revamp/Improve Javadocs for Digital Twins Libraries
- Revamp/Improve Javadocs for Device Update Libraries
- Revamp/Improve Javadocs for Maps Libraries
- Revamp/Improve Javadocs for Mixed Reality Libraries
- Revamp/Improve Javadocs for Personalizer Libraries
- Revamp/Improve Javadocs for Load Testing Libraries
- Revamp/Improve Javadocs for Health Insights Libraries
- Revamp/Improve Javadocs for Developer DevCenter Libraries
- BlobStorageException.getErrroCode returns null HOT 3
- [FEATURE REQ] mgmt-core, support Italy North region
- mgmt, deprecate deploymentmanager as service has been decommissioned
- [BUG] Spring Cloud Azure 5.9.0 update requires JDK 21 HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from azure-sdk-for-java.