Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 1476731 Details for
Bug 1618908
qpid client leaks memory when it connects to an unreachable broker ip address.
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
reproducer to show memory leak
qpid-client-memleak.cpp (text/x-csrc), 2.65 KB, created by
Mike Cressman
on 2018-08-18 02:28:58 UTC
(
hide
)
Description:
reproducer to show memory leak
Filename:
MIME Type:
Creator:
Mike Cressman
Created:
2018-08-18 02:28:58 UTC
Size:
2.65 KB
patch
obsolete
>/* > * > * Licensed to the Apache Software Foundation (ASF) under one > * or more contributor license agreements. See the NOTICE file > * distributed with this work for additional information > * regarding copyright ownership. The ASF licenses this file > * to you under the Apache License, Version 2.0 (the > * "License"); you may not use this file except in compliance > * with the License. You may obtain a copy of the License at > * > * http://www.apache.org/licenses/LICENSE-2.0 > * > * Unless required by applicable law or agreed to in writing, > * software distributed under the License is distributed on an > * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY > * KIND, either express or implied. See the License for the > * specific language governing permissions and limitations > * under the License. > * > */ >#include <unistd.h> >#include <iostream> >#include <cstdlib> >#include <sstream> > >#include <qpid/messaging/Address.h> >#include <qpid/messaging/Connection.h> >#include <qpid/messaging/Message.h> >#include <qpid/messaging/Receiver.h> >#include <qpid/messaging/Sender.h> >#include <qpid/messaging/Session.h> > > >using namespace qpid::messaging; >using namespace qpid::types; > >using std::stringstream; >using std::string; > >int main(int argc, char** argv) { > //const char* url = argc>1 ? argv[1] : "amqp:tcp:10.1.10.102:10001"; > const char* url = argc>1 ? argv[1] : "amqp:tcp:165.2.3.4:3456"; > const char *reconnectList="168.1.2.3:1234,169.2.3.4:2345,164.1.2.3:3456"; > std::string connectionOptions = argc > 2 ? argv[2] : ""; > > const qpid::types::Variant v_reconnectUrls(reconnectList); > const qpid::types::Variant v_heartbeat(3); > const qpid::types::Variant v_reconnectOption(true); > const qpid::types::Variant v_tcp_nodely(true); > const qpid::types::Variant v_reconnectTimeout(60); > const qpid::types::Variant v_reconnectIntervalMin(1); > const qpid::types::Variant v_reconnectIntervalMax(1); > > while(1){ > Connection connection(url, connectionOptions); > > connection.setOption("heartbeat", v_heartbeat); > connection.setOption("reconnect", v_reconnectOption); > connection.setOption("tcp-nodelay", v_tcp_nodely); > connection.setOption("reconnect_timeout", v_reconnectTimeout); > connection.setOption("reconnect_interval_min", v_reconnectIntervalMin); > connection.setOption("reconnect_interval_max", v_reconnectIntervalMax); > connection.setOption("reconnect_urls", v_reconnectUrls); > > try { > connection.open(); > sleep(1); > std::cout << "." << std::endl; > connection.close(); > std::cout << "*" << std::endl; > sleep(2); > } > catch(const std::exception& error) { > std::cout << error.what() << std::endl; > connection.close(); > } > } > return 1; >} > >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 1618908
: 1476731